From: <jon...@us...> - 2011-04-04 15:49:17
|
Revision: 33817 http://tikiwiki.svn.sourceforge.net/tikiwiki/?rev=33817&view=rev Author: jonnybradley Date: 2011-04-04 15:49:11 +0000 (Mon, 04 Apr 2011) Log Message: ----------- [FIX] trackers: Fallback for listfields provided with the fieldIds as the array keys. Modified Paths: -------------- branches/7.x/lib/trackers/trackerlib.php Modified: branches/7.x/lib/trackers/trackerlib.php =================================================================== --- branches/7.x/lib/trackers/trackerlib.php 2011-04-04 15:48:08 UTC (rev 33816) +++ branches/7.x/lib/trackers/trackerlib.php 2011-04-04 15:49:11 UTC (rev 33817) @@ -1234,10 +1234,14 @@ .')'.$join; $fieldIds = array(); - foreach ($listfields as $f) { - $fieldIds[] = $f['fieldId']; + foreach ($listfields as $k => $f) { + if (isset($f['fieldId'])) { + $fieldIds[] = $f['fieldId']; + } else { + $fieldIds[] = $k; // sometimes filterfields are provided with the fieldId only on the array keys + } } - + $mid .= ' AND ' . $this->in('ttif.fieldId', $fieldIds, $bindvars); $query = 'SELECT tti.*, ttif.`value`, ttf.`type`' This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |