diff options
author | wei <> | 2006-07-26 01:44:57 +0000 |
---|---|---|
committer | wei <> | 2006-07-26 01:44:57 +0000 |
commit | 5c1132f6da292a689bc52bd7f20a83ff8d733fbd (patch) | |
tree | 3b61f33aff5aac63bc192564602c2ff482913cf5 /demos/time-tracker/protected/App_Code | |
parent | cbb7a11179b9c1c46e35f04d07d6386a44e400b2 (diff) |
Allow nested GroupBy result maps
Diffstat (limited to 'demos/time-tracker/protected/App_Code')
-rw-r--r-- | demos/time-tracker/protected/App_Code/UserReport.php | 6 | ||||
-rw-r--r-- | demos/time-tracker/protected/App_Code/UserReportsDao.php | 5 |
2 files changed, 6 insertions, 5 deletions
diff --git a/demos/time-tracker/protected/App_Code/UserReport.php b/demos/time-tracker/protected/App_Code/UserReport.php index e7529120..d37de934 100644 --- a/demos/time-tracker/protected/App_Code/UserReport.php +++ b/demos/time-tracker/protected/App_Code/UserReport.php @@ -2,9 +2,9 @@ class UserReport
{
- public $Username = '';
- public $CategoryID = 0;
- public $ActualDuration = 0.0;
+ public $CategoryName = '';
+ public $users = array();
+ public $ProjectName = '';
}
?>
\ No newline at end of file diff --git a/demos/time-tracker/protected/App_Code/UserReportsDao.php b/demos/time-tracker/protected/App_Code/UserReportsDao.php index 3cf943af..c6eab660 100644 --- a/demos/time-tracker/protected/App_Code/UserReportsDao.php +++ b/demos/time-tracker/protected/App_Code/UserReportsDao.php @@ -14,10 +14,11 @@ class UserReportsDao extends BaseDao return $sqlmap->queryForList('GetTimeReportByCategoryID', $categoryID);
}
- public function getTimeReportsByProjectID($projectID)
+ public function getTimeReportsByProjectIDs($projects)
{
+ $ids = implode(',', array_map('intval', $projects));
$sqlmap = $this->getConnection();
- return $sqlmap->queryForList('GetTimeReportByProjectID', $projectID);
+ return $sqlmap->queryForList('GetTimeReportByProjectIDs', $ids);
}
}
|