[ Index ] |
|
Code source de eGroupWare 1.2.106-2 |
[Code source] [Imprimer] [Statistiques]
(pas de description)
Poids: | 536 lignes (18 kb) |
Inclus ou requis: | 3 fois |
Référencé: | 0 fois |
Nécessite: | 1 fichier etemplate/inc/class.so_sql.inc.php |
botimesheet:: (14 méthodes):
botimesheet()
grant_list()
check_acl()
date_filter()
search()
read()
save()
delete()
db2data()
data2db()
sum()
link_title()
link_query()
search_link()
Classe: botimesheet - X-Ref
Business object of the TimeSheetbotimesheet() X-Ref |
grant_list($required=EGW_ACL_READ) X-Ref |
get list of specified grants as uid => Username pairs param: int $required=EGW_ACL_READ return: array with uid => Username pairs |
check_acl($required,$data=null) X-Ref |
checks if the user has enough rights for a certain operation Rights are given via owner grants or role based acl param: int $required EGW_ACL_READ, EGW_ACL_WRITE, EGW_ACL_ADD, EGW_ACL_DELETE, EGW_ACL_BUDGET, EGW_ACL_EDIT_BUDGET param: array/int $data=null project or project-id to use, default the project in $this->data return: boolean true if the rights are ok, false if not |
date_filter($name,&$start,&$end_param) X-Ref |
Pas de description |
search($criteria,$only_keys=True,$order_by='',$extra_cols='',$wildcard='',$empty=False,$op='AND',$start=false,$filter=null,$join='',$need_full_no_count=false,$only_summary=false) X-Ref |
search the timesheet reimplemented to limit result to users we have grants from param: array/string $criteria array of key and data cols, OR a SQL query (content for WHERE), fully quoted (!) param: boolean/string $only_keys=true True returns only keys, False returns all cols. comma seperated list of keys to return param: string $order_by='' fieldnames + {ASC|DESC} separated by colons ',', can also contain a GROUP BY (if it contains ORDER BY) param: string/array $extra_cols='' string or array of strings to be added to the SELECT, eg. "count(*) as num" param: string $wildcard='' appended befor and after each criteria param: boolean $empty=false False=empty criteria are ignored in query, True=empty have to be empty in row param: string $op='AND' defaults to 'AND', can be set to 'OR' too, then criteria's are OR'ed together param: mixed $start=false if != false, return only maxmatch rows begining with start, or array($start,$num) param: array $filter=null if set (!=null) col-data pairs, to be and-ed (!) into the query without wildcards param: string $join='' sql to do a join, added as is after the table-name, eg. ", table2 WHERE x=y" or param: boolean $need_full_no_count=false If true an unlimited query is run to determine the total number of rows, default false param: boolean $only_summary=false If true only return the sums as array with keys duration and price, default false return: array of matching rows (the row is an array of the cols) or False |
read($ts_id,$ignore_acl=false) X-Ref |
read a timesheet entry param: int $ts_id param: boolean $ignore_acl=false should the acl be checked return: array/boolean array with timesheet entry or false if no rights |
save($keys=null,$touch_modified=true,$ignore_acl=false) X-Ref |
saves a timesheet entry reimplemented to notify the link-class param: array $keys if given $keys are copied to data before saveing => allows a save as param: boolean $touch_modified=true should modification date+user be set, default yes param: boolean $ignore_acl=false should the acl be checked, returns true if no edit-rigts return: int 0 on success and errno != 0 else |
delete($keys=null,$ignore_acl=false) X-Ref |
deletes a timesheet entry identified by $keys or the loaded one, reimplemented to notify the link class (unlink) param: array $keys if given array with col => value pairs to characterise the rows to delete param: boolean $ignore_acl=false should the acl be checked, returns false if no delete-rigts return: int affected rows, should be 1 if ok, 0 if an error |
db2data($data=null) X-Ref |
changes the data from the db-format to your work-format reimplemented to adjust the timezone of the timestamps (adding $this->tz_offset_s to get user-time) Please note, we do NOT call the method of the parent so_sql !!! param: array $data if given works on that array and returns result, else works on internal data-array return: array with changed data |
data2db($data=null) X-Ref |
changes the data from your work-format to the db-format reimplemented to adjust the timezone of the timestamps (subtraction $this->tz_offset_s to get server-time) Please note, we do NOT call the method of the parent so_sql !!! param: array $data if given works on that array and returns result, else works on internal data-array return: array with changed data |
sum($ids) X-Ref |
Get the time- and pricesum for the given timesheet entries param: array $ids array of timesheet id's return: array with keys time and price |
link_title( $entry ) X-Ref |
get title for an timesheet entry identified by $entry Is called as hook to participate in the linking param: int/array $entry int ts_id or array with timesheet entry param: string the title |
link_query( $pattern ) X-Ref |
query timesheet for entries matching $pattern Is called as hook to participate in the linking param: string $pattern pattern to search return: array with ts_id - title pairs of the matching entries |
search_link($location) X-Ref |
Hook called by link-class to include timesheet in the appregistry of the linkage param: array/string $location location and other parameters (not used) return: array with method-names |
Généré le : Sun Feb 25 17:20:01 2007 | par Balluche grâce à PHPXref 0.7 |