Page 2 sur 2

Re: problem with duplicated Items in the list view

Posté : mar. 30 mars 2010 23:41
par steevo
Hi,

"for" in line 147 is normal.
But I just see that you must add after line 148:

Code : Tout sélectionner

$this->row =& $this->items[$i];
And for example just look :
http://demo.steevo.fr/index.php?option= ... &Itemid=53

the template is :

Code : Tout sélectionner

$link = 'index.php?option=com_collector&view=item&id='.$this->collection->id.'&Itemid='.$this->itemid.'&item='.$this->row->cid; ?>
	<center>
		<a href="<?php echo $link; ?>" >
			<?php
				$this->display_field_row(7, 5, $this->row);
			?>
		</a>
	</center>
To display item value, you call the function $this->display_field_row(field_id, field_type, $this->row);
field_id is the id of the field, last column in the list of collection fields.
field_type is:
1 for line
2 for text
3 for defined field
5 for image
6 for number
7 for date
8 for file

Sorry but this functionnality is not completed so it's not easy to use it...

Re: problem with duplicated Items in the list view

Posté : mer. 31 mars 2010 09:27
par strmora
Hi,

Ok, thanks i'll try it.
Attached find Spanish translation for whole component. I'm working in content elements for joomfish, not for collections tables, but for lists, fields, etc. If you are interested in let me know.

Best regards.

Re: problem with duplicated Items in the list view

Posté : ven. 2 avr. 2010 19:52
par steevo
Thank you for spanish translation.
I'm working on a database modification to be compatible with joomfish.
This will be integrated in the next release.

Re: problem with duplicated Items in the list view

Posté : lun. 24 mai 2010 05:56
par KarlU
This is what worked for me.
in file ....components/com_collector/views/collection/tmpl/default.php
This is about 33 lined from the bottom of the file. Simply comment out the "for" statement as I did below.

if ( $this->template->alias == 'default' )
{
echo $this->loadTemplate('default');
}
else
{
echo '<tr>';
>>>> // for ($i=0, $n=count($this->items);$i<$n;$i++)
{
echo '<td>';

echo $this->loadTemplate($this->template->alias);
echo '</td>';

if ( $i!=0 && ($i+1)%$this->template->column==0 && $i!=$n-1 )
{
echo '</tr><tr>';
}
}
echo '</tr>';