Subversion-Projekte lars-tiefland.prado

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
<?php
2
 
3
class TimeEntryDao extends BaseDao
4
{
5
	public function addNewTimeEntry($entry)
6
	{
7
		$sqlmap = $this->getSqlMap();
8
		$sqlmap->insert('AddNewTimeEntry', $entry);
9
	}
10
 
11
	public function getTimeEntryByID($entryID)
12
	{
13
		$sqlmap = $this->getSqlMap();
14
		return $sqlmap->queryForObject('GetTimeEntryByID', $entryID);
15
	}
16
 
17
	public function deleteTimeEntry($entryID)
18
	{
19
		$sqlmap = $this->getSqlMap();
20
		$sqlmap->delete('DeleteTimeEntry', $entryID);
21
	}
22
 
23
	public function getTimeEntriesInProject($username, $projectID)
24
	{
25
		$sqlmap = $this->getSqlMap();
26
		$param['username'] = $username;
27
		$param['project'] = $projectID;
28
		return $sqlmap->queryForList('GetAllTimeEntriesByProjectIdAndUser', $param);
29
	}
30
 
31
	public function updateTimeEntry($entry)
32
	{
33
		$sqlmap = $this->getSqlMap();
34
		$sqlmap->update('UpdateTimeEntry', $entry);
35
	}
36
}
37
 
38
?>