Skip to content

Timetracker_Frontend_Json

This class handles all Json requests for the Timetracker application

Implements:

Tinebase_Frontend_Json_Interface, Tinebase_Frontend_Interface

Extend:

Tinebase_Frontend_Json_Abstract

Methods

Name Description
__construct the constructor
addTimeAccountFavorite Add given timeaccount id as a users favorite
deleteTimeAccountFavorite Delete given timeaccount favorite
deleteTimeaccounts deletes existing records
deleteTimesheets deletes existing records
getTimeAccountFavoriteRegistry Return registry data for timeaccount favorites
getTimeaccount Return a single record
getTimesheet Return a single record
saveTimeaccount creates/updates a record
saveTimesheet creates/updates a record
searchTimeaccounts Search for records matching given arguments
searchTimesheets Search for records matching given arguments

Inherited methods

Name Description
__call magic method for json api
addFilterModelPlugin Add a plugin for a former filter
getModelsConfiguration returns model configurations for application starter
getRegistryData Returns registry data of the application.
getRelatableModels Returns all relatable models for this app
getTemplates get available templates by containerId
resolveContainersAndTags resolve containers and tags

Timetracker_Frontend_Json::__construct

Description

public __construct (void)

the constructor

Parameters

This function has no parameters.

Return Values

void


Timetracker_Frontend_Json::addTimeAccountFavorite

Description

public addTimeAccountFavorite ( $timeaccountId)

Add given timeaccount id as a users favorite

Parameters

  • () $timeaccountId

Return Values

\Timetracker_Model_Timeaccount


Timetracker_Frontend_Json::deleteTimeAccountFavorite

Description

public deleteTimeAccountFavorite ( $favId)

Delete given timeaccount favorite

Parameters

  • () $favId

Return Values

\Tinebase_Record_RecordSet

Throws Exceptions

\Tinebase_Exception


Timetracker_Frontend_Json::deleteTimeaccounts

Description

public deleteTimeaccounts (array $ids)

deletes existing records

Parameters

  • (array) $ids

Return Values

string


Timetracker_Frontend_Json::deleteTimesheets

Description

public deleteTimesheets (array $ids)

deletes existing records

Parameters

  • (array) $ids

Return Values

string


Timetracker_Frontend_Json::getTimeAccountFavoriteRegistry

Description

public getTimeAccountFavoriteRegistry (void)

Return registry data for timeaccount favorites

Parameters

This function has no parameters.

Return Values

array

Throws Exceptions

\Tinebase_Exception_InvalidArgument


Timetracker_Frontend_Json::getTimeaccount

Description

public getTimeaccount (string $id)

Return a single record

Parameters

  • (string) $id

Return Values

array

record data


Timetracker_Frontend_Json::getTimesheet

Description

public getTimesheet (string $id)

Return a single record

Parameters

  • (string) $id

Return Values

array

record data


Timetracker_Frontend_Json::saveTimeaccount

Description

public saveTimeaccount (array $recordData)

creates/updates a record

Parameters

  • (array) $recordData

Return Values

array

created/updated record


Timetracker_Frontend_Json::saveTimesheet

Description

public saveTimesheet (array $recordData, array $context)

creates/updates a record

Parameters

  • (array) $recordData
  • (array) $context

Return Values

array

created/updated record


Timetracker_Frontend_Json::searchTimeaccounts

Description

public searchTimeaccounts (array $filter, array $paging)

Search for records matching given arguments

Parameters

  • (array) $filter
  • (array) $paging

Return Values

array


Timetracker_Frontend_Json::searchTimesheets

Description

public searchTimesheets (array $filter, array $paging)

Search for records matching given arguments

Parameters

  • (array) $filter
  • (array) $paging

Return Values

array