From 4f02bac70b867a3171d9a66a44ffd42ed8636c60 Mon Sep 17 00:00:00 2001 From: wangchunsheng Date: Tue, 27 Oct 2009 07:31:03 +0000 Subject: [PATCH] + add getProjectBugs() method. --- trunk/module/bug/model.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/trunk/module/bug/model.php b/trunk/module/bug/model.php index bc4ab05ff4..e344a838e2 100644 --- a/trunk/module/bug/model.php +++ b/trunk/module/bug/model.php @@ -158,4 +158,10 @@ class bugModel extends model } return $bugs; } + + /* 获得某个项目的bug列表。*/ + public function getProjectBugs($projectID, $orderBy = 'id|desc', $pager = null) + { + return $this->dao->select('*')->from(TABLE_BUG)->where('project')->eq((int)$projectID)->orderBy($orderBy)->page($pager)->fetchAll(); + } }