Hermes_Driver:: defines an API for implementing storage backends
for Hermes.
See the enclosed file LICENSE for license information (BSD). If you
did not receive this file, see http://www.horde.org/licenses/bsdl.php.
Methods summary
public
|
|
public
array
|
#
getJobTypeByID( integer $jobTypeID )
Retrieve a specific job type record.
Retrieve a specific job type record.
Parameters
- $jobTypeID
- The ID of the job type.
Returns
array Hash of job type properties.
Throws
Horde_Exception_NotFound
|
public
array
|
#
getDeliverableByID( integer $deliverableID )
Retrieve a deliverable by ID.
Retrieve a deliverable by ID.
Parameters
- $deliverableID
- The ID of the deliverable to retrieve.
Returns
array Hash of deliverable's properties.
Throws
Horde_Exception_NotFound
|
abstract public
The
|
#
updateJobType( array $jobtype )
Add or update a job type record.
Add or update a job type record.
Parameters
- $jobtype
- <p>A hash of job type properties:
'id' => The ID of the job, if updating. If not
present, a new job type is created.
'name' => The job type's name.
'enabled' => Whether the job type is enabled for new
time entry.</p>
Returns
The job's ID.
|
abstract public
|
|
abstract public
array
|
#
listJobTypes( array $criteria = array() )
Retrieve list of job types.
Retrieve list of job types.
Parameters
- $criteria
- Hash of filter criteria:
<pre><code> 'enabled' => If present, only retrieve enabled
or disabled job types.
</code></pre>
Returns
array Hash of job type.
|
abstract public
integer
|
#
updateDeliverable( array $deliverable )
Add or update a deliverable.
Add or update a deliverable.
Parameters
- $deliverable
- <p>A hash of deliverable properties:
'id' => The ID of the deliverable, if
updating. If not present, a new
ID is allocated.
'name' => The deliverable's display name.
'client_id' => The assigned client ID.
'parent' => ID of the deliverables parent
deliverable (if a child).
'estimate' => Estimated number of hours for
completion of the deliverable.
'active' => Whether this deliverable is active.
'description' => Text description (notes) for this
deliverable.</p>
Returns
integer ID of new or saved deliverable.
|
abstract public
array
|
#
listDeliverables( array $criteria = array() )
Retrieve list of deliverables.
Retrieve list of deliverables.
Parameters
- $criteria
- <p>A hash of search criteria:
'id' => If present, only deliverable with
specified ID is searched for.
'client_id' => If present, list is filtered by
client ID.</p>
Returns
array Hash of job types.
|
abstract public
|
#
deleteDeliverable( integer $deliverableID )
Delete a deliverable.
Parameters
- $deliverableID
- The ID of the deliverable.
|
abstract public
|
#
markAs( mixed $field, mixed $hours )
|
abstract public
|
|
abstract public
|
|
abstract public
|
|
abstract public
integer
|
#
enterTime( string $employee, array $info )
Save a row of billing information.
Save a row of billing information.
Parameters
- $employee
- <p>The Horde ID of the person who worked the
hours.</p>
- $info
- <p>$entries The billing information to enter. Each array
row must contain the following entries:
'date' The day the hours were worked (ISO format)
'client' The id of the client the work was done for.
'type' The type of work done.
'hours' The number of hours worked
'rate' The hourly rate the work was done at.
'billable' (optional) Whether or not the work is
billable hours.
'description' A short description of the work.</p>
Returns
integer The new timeslice_id of the newly entered slice
Throws
|
abstract public
mixed
|
#
updateTime( array $entries )
Update a set of billing information.
Update a set of billing information.
Parameters
- $entries
- <p>The billing information to enter. Each array row
must contain the following entries:
'id' The id of this time entry.
'date' The day the hours were worked (ISO format)
'client' The id of the client the work was done for.
'type' The type of work done.
'hours' The number of hours worked
'rate' The hourly rate the work was done at.
'billable' Whether or not the work is billable hours.
'description' A short description of the work.</p>
<pre><code> If any rows contain a 'delete' entry, those rows
will be deleted instead of updated.
</code></pre>
Returns
mixed boolean
Throws
|