Remove the use of GROUP_CONCAT in SQL request.
This commit is contained in:
parent
dd05a58c8c
commit
5635cdcac7
@ -174,9 +174,12 @@ class IDF_Views_Issue
|
|||||||
|
|
||||||
// Get the id list of issue in the user watch list (for all projects !)
|
// Get the id list of issue in the user watch list (for all projects !)
|
||||||
$db =& Pluf::db();
|
$db =& Pluf::db();
|
||||||
$issues_id = $db->select('SELECT GROUP_CONCAT(idf_issue_id) as id FROM '.Pluf::f('db_table_prefix', '').'idf_issue_pluf_user_assoc WHERE pluf_user_id='.$request->user->id.' GROUP BY pluf_user_id');
|
$sql_results = $db->select('SELECT idf_issue_id as id FROM '.Pluf::f('db_table_prefix', '').'idf_issue_pluf_user_assoc WHERE pluf_user_id='.$request->user->id);
|
||||||
if (empty ($issues_id)) $issues_id = "";
|
$issues_id = array();
|
||||||
else $issues_id = $issues_id[0]['id'];
|
foreach ($sql_results as $id) {
|
||||||
|
array_push($issues_id, $id['id']);
|
||||||
|
}
|
||||||
|
$issues_id = implode (',', $issues_id);
|
||||||
|
|
||||||
// Count open and close issues
|
// Count open and close issues
|
||||||
$sql = new Pluf_SQL('id IN ('.$issues_id.') AND status IN ('.implode(', ', $otags).')', array());
|
$sql = new Pluf_SQL('id IN ('.$issues_id.') AND status IN ('.implode(', ', $otags).')', array());
|
||||||
|
Loading…
Reference in New Issue
Block a user