* fix a bug for the view purview of bug in different projects(m=bug&f=browse).

This commit is contained in:
shiyangyangwork@yahoo.cn
2011-12-23 07:16:05 +00:00
parent a2fed9cec9
commit f3ec0e27f7
2 changed files with 23 additions and 2 deletions
+2 -1
View File
@@ -73,11 +73,12 @@ class bugModel extends model
* @access public
* @return array
*/
public function getModuleBugs($productID, $moduleIds = 0, $orderBy = 'id_desc', $pager = null)
public function getModuleBugs($productID, $moduleIds = 0, $projects, $orderBy = 'id_desc', $pager = null)
{
return $this->dao->select('*')->from(TABLE_BUG)
->where('product')->eq((int)$productID)
->beginIF(!empty($moduleIds))->andWhere('module')->in($moduleIds)->fi()
->andWhere('project')->in($projects)
->andWhere('deleted')->eq(0)
->orderBy($orderBy)->page($pager)->fetchAll();
}