Skip to content

Commit

Permalink
Changes on timesheet API
Browse files Browse the repository at this point in the history
  • Loading branch information
NikoGrano committed Aug 4, 2021
1 parent 273c63c commit abda713
Show file tree
Hide file tree
Showing 13 changed files with 274 additions and 69 deletions.
4 changes: 2 additions & 2 deletions docs/Api/TimesheetApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ $activity = 'activity_example'; // string | DEPRECATED: Activity ID to filter ti
$activities = 'activities_example'; // string | Comma separated list of activity IDs to filter timesheets
$page = 'page_example'; // string | The page to display, renders a 404 if not found (default: 1)
$size = 'size_example'; // string | The amount of entries for each page (default: 50)
$tags = 'tags_example'; // string | The name of tags which are in the datasets
$tags = 'tags_example'; // string | Comma separated list of tag names
$orderBy = 'orderBy_example'; // string | The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin)
$order = 'order_example'; // string | The result order. Allowed values: ASC, DESC (default: DESC)
$begin = 'begin_example'; // \DateTime | Only records after this date will be included (format: HTML5)
Expand Down Expand Up @@ -153,7 +153,7 @@ Name | Type | Description | Notes
**activities** | **string**| Comma separated list of activity IDs to filter timesheets | [optional]
**page** | **string**| The page to display, renders a 404 if not found (default: 1) | [optional]
**size** | **string**| The amount of entries for each page (default: 50) | [optional]
**tags** | **string**| The name of tags which are in the datasets | [optional]
**tags** | **string**| Comma separated list of tag names | [optional]
**orderBy** | **string**| The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin) | [optional]
**order** | **string**| The result order. Allowed values: ASC, DESC (default: DESC) | [optional]
**begin** | **\DateTime**| Only records after this date will be included (format: HTML5) | [optional]
Expand Down
2 changes: 2 additions & 0 deletions docs/Model/TimesheetCollection.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ Name | Type | Description | Notes
**description** | **string** | | [optional]
**rate** | **float** | | [optional]
**internalRate** | **float** | | [optional]
**exported** | **bool** | |
**billable** | **bool** | |
**metaFields** | [**\Fiteco\KimaiClient\Model\TimesheetMeta[]**](TimesheetMeta.md) | All visible meta (custom) fields registered with this timesheet | [optional]

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
2 changes: 2 additions & 0 deletions docs/Model/TimesheetCollectionExpanded.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ Name | Type | Description | Notes
**description** | **string** | | [optional]
**rate** | **float** | | [optional]
**internalRate** | **float** | | [optional]
**exported** | **bool** | |
**billable** | **bool** | |
**metaFields** | [**\Fiteco\KimaiClient\Model\TimesheetMeta[]**](TimesheetMeta.md) | All visible meta (custom) fields registered with this timesheet | [optional]

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
4 changes: 2 additions & 2 deletions docs/Model/TimesheetEditForm.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**begin** | [**\DateTime**](\DateTime.md) | |
**end** | [**\DateTime**](\DateTime.md) | | [optional]
**duration** | **string** | | [optional]
**project** | **int** | Project ID |
**activity** | **int** | Activity ID |
**description** | **string** | | [optional]
**tags** | **string** | Comma separated list of tags | [optional]
**fixedRate** | **float** | Fixed rate | [optional]
**hourlyRate** | **float** | Hourly rate | [optional]
**user** | **int** | User ID | [optional]
**exported** | **bool** | | [optional]
**billable** | **bool** | | [optional]
**tags** | **string** | Comma separated list of tags | [optional]

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
1 change: 1 addition & 0 deletions docs/Model/TimesheetEntity.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Name | Type | Description | Notes
**fixedRate** | **float** | | [optional]
**hourlyRate** | **float** | | [optional]
**exported** | **bool** | |
**billable** | **bool** | |
**metaFields** | [**\Fiteco\KimaiClient\Model\TimesheetMeta[]**](TimesheetMeta.md) | All visible meta (custom) fields registered with this timesheet | [optional]

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
1 change: 1 addition & 0 deletions docs/Model/TimesheetEntityExpanded.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Name | Type | Description | Notes
**fixedRate** | **float** | | [optional]
**hourlyRate** | **float** | | [optional]
**exported** | **bool** | |
**billable** | **bool** | |
**metaFields** | [**\Fiteco\KimaiClient\Model\TimesheetMeta[]**](TimesheetMeta.md) | All visible meta (custom) fields registered with this timesheet | [optional]

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
1 change: 1 addition & 0 deletions docs/Model/Version.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**version** | **string** | | [optional]
**versionId** | **int** | Follows the same logic as PHP_VERSION_ID, see https://www.php.net/manual/de/function.phpversion.php | [optional]
**candidate** | **string** | | [optional]
**semver** | **string** | | [optional]
**name** | **string** | | [optional]
Expand Down
10 changes: 5 additions & 5 deletions src/Api/TimesheetApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ public function apiTimesheetsActiveGetRequest()
* @param string $activities Comma separated list of activity IDs to filter timesheets (optional)
* @param string $page The page to display, renders a 404 if not found (default: 1) (optional)
* @param string $size The amount of entries for each page (default: 50) (optional)
* @param string $tags The name of tags which are in the datasets (optional)
* @param string $tags Comma separated list of tag names (optional)
* @param string $orderBy The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin) (optional)
* @param string $order The result order. Allowed values: ASC, DESC (default: DESC) (optional)
* @param \DateTime $begin Only records after this date will be included (format: HTML5) (optional)
Expand Down Expand Up @@ -400,7 +400,7 @@ public function apiTimesheetsGet($user = null, $customer = null, $customers = nu
* @param string $activities Comma separated list of activity IDs to filter timesheets (optional)
* @param string $page The page to display, renders a 404 if not found (default: 1) (optional)
* @param string $size The amount of entries for each page (default: 50) (optional)
* @param string $tags The name of tags which are in the datasets (optional)
* @param string $tags Comma separated list of tag names (optional)
* @param string $orderBy The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin) (optional)
* @param string $order The result order. Allowed values: ASC, DESC (default: DESC) (optional)
* @param \DateTime $begin Only records after this date will be included (format: HTML5) (optional)
Expand Down Expand Up @@ -495,7 +495,7 @@ public function apiTimesheetsGetWithHttpInfo($user = null, $customer = null, $cu
* @param string $activities Comma separated list of activity IDs to filter timesheets (optional)
* @param string $page The page to display, renders a 404 if not found (default: 1) (optional)
* @param string $size The amount of entries for each page (default: 50) (optional)
* @param string $tags The name of tags which are in the datasets (optional)
* @param string $tags Comma separated list of tag names (optional)
* @param string $orderBy The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin) (optional)
* @param string $order The result order. Allowed values: ASC, DESC (default: DESC) (optional)
* @param \DateTime $begin Only records after this date will be included (format: HTML5) (optional)
Expand Down Expand Up @@ -534,7 +534,7 @@ function ($response) {
* @param string $activities Comma separated list of activity IDs to filter timesheets (optional)
* @param string $page The page to display, renders a 404 if not found (default: 1) (optional)
* @param string $size The amount of entries for each page (default: 50) (optional)
* @param string $tags The name of tags which are in the datasets (optional)
* @param string $tags Comma separated list of tag names (optional)
* @param string $orderBy The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin) (optional)
* @param string $order The result order. Allowed values: ASC, DESC (default: DESC) (optional)
* @param \DateTime $begin Only records after this date will be included (format: HTML5) (optional)
Expand Down Expand Up @@ -592,7 +592,7 @@ function ($exception) {
* @param string $activities Comma separated list of activity IDs to filter timesheets (optional)
* @param string $page The page to display, renders a 404 if not found (default: 1) (optional)
* @param string $size The amount of entries for each page (default: 50) (optional)
* @param string $tags The name of tags which are in the datasets (optional)
* @param string $tags Comma separated list of tag names (optional)
* @param string $orderBy The field by which results will be ordered. Allowed values: id, begin, end, rate (default: begin) (optional)
* @param string $order The result order. Allowed values: ASC, DESC (default: DESC) (optional)
* @param \DateTime $begin Only records after this date will be included (format: HTML5) (optional)
Expand Down
66 changes: 66 additions & 0 deletions src/Model/TimesheetCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ class TimesheetCollection implements ModelInterface, ArrayAccess, \JsonSerializa
'description' => 'string',
'rate' => 'float',
'internalRate' => 'float',
'exported' => 'bool',
'billable' => 'bool',
'metaFields' => '\Fiteco\KimaiClient\Model\TimesheetMeta[]',
];

Expand All @@ -93,6 +95,8 @@ class TimesheetCollection implements ModelInterface, ArrayAccess, \JsonSerializa
'description' => null,
'rate' => 'float',
'internalRate' => 'float',
'exported' => null,
'billable' => null,
'metaFields' => null,
];

Expand Down Expand Up @@ -134,6 +138,8 @@ public static function openAPIFormats()
'description' => 'description',
'rate' => 'rate',
'internalRate' => 'internalRate',
'exported' => 'exported',
'billable' => 'billable',
'metaFields' => 'metaFields',
];

Expand All @@ -154,6 +160,8 @@ public static function openAPIFormats()
'description' => 'setDescription',
'rate' => 'setRate',
'internalRate' => 'setInternalRate',
'exported' => 'setExported',
'billable' => 'setBillable',
'metaFields' => 'setMetaFields',
];

Expand All @@ -174,6 +182,8 @@ public static function openAPIFormats()
'description' => 'getDescription',
'rate' => 'getRate',
'internalRate' => 'getInternalRate',
'exported' => 'getExported',
'billable' => 'getBillable',
'metaFields' => 'getMetaFields',
];

Expand Down Expand Up @@ -244,6 +254,8 @@ public function __construct(array $data = null)
$this->container['description'] = $data['description'] ?? null;
$this->container['rate'] = $data['rate'] ?? null;
$this->container['internalRate'] = $data['internalRate'] ?? null;
$this->container['exported'] = $data['exported'] ?? null;
$this->container['billable'] = $data['billable'] ?? null;
$this->container['metaFields'] = $data['metaFields'] ?? null;
}

Expand All @@ -259,6 +271,12 @@ public function listInvalidProperties()
if (null === $this->container['begin']) {
$invalidProperties[] = "'begin' can't be null";
}
if (null === $this->container['exported']) {
$invalidProperties[] = "'exported' can't be null";
}
if (null === $this->container['billable']) {
$invalidProperties[] = "'billable' can't be null";
}

return $invalidProperties;
}
Expand Down Expand Up @@ -538,6 +556,54 @@ public function setInternalRate($internalRate)
return $this;
}

/**
* Gets exported.
*
* @return bool
*/
public function getExported()
{
return $this->container['exported'];
}

/**
* Sets exported.
*
* @param bool $exported exported
*
* @return self
*/
public function setExported($exported)
{
$this->container['exported'] = $exported;

return $this;
}

/**
* Gets billable.
*
* @return bool
*/
public function getBillable()
{
return $this->container['billable'];
}

/**
* Sets billable.
*
* @param bool $billable billable
*
* @return self
*/
public function setBillable($billable)
{
$this->container['billable'] = $billable;

return $this;
}

/**
* Gets metaFields.
*
Expand Down
66 changes: 66 additions & 0 deletions src/Model/TimesheetCollectionExpanded.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ class TimesheetCollectionExpanded implements ModelInterface, ArrayAccess, \JsonS
'description' => 'string',
'rate' => 'float',
'internalRate' => 'float',
'exported' => 'bool',
'billable' => 'bool',
'metaFields' => '\Fiteco\KimaiClient\Model\TimesheetMeta[]',
];

Expand All @@ -93,6 +95,8 @@ class TimesheetCollectionExpanded implements ModelInterface, ArrayAccess, \JsonS
'description' => null,
'rate' => 'float',
'internalRate' => 'float',
'exported' => null,
'billable' => null,
'metaFields' => null,
];

Expand Down Expand Up @@ -134,6 +138,8 @@ public static function openAPIFormats()
'description' => 'description',
'rate' => 'rate',
'internalRate' => 'internalRate',
'exported' => 'exported',
'billable' => 'billable',
'metaFields' => 'metaFields',
];

Expand All @@ -154,6 +160,8 @@ public static function openAPIFormats()
'description' => 'setDescription',
'rate' => 'setRate',
'internalRate' => 'setInternalRate',
'exported' => 'setExported',
'billable' => 'setBillable',
'metaFields' => 'setMetaFields',
];

Expand All @@ -174,6 +182,8 @@ public static function openAPIFormats()
'description' => 'getDescription',
'rate' => 'getRate',
'internalRate' => 'getInternalRate',
'exported' => 'getExported',
'billable' => 'getBillable',
'metaFields' => 'getMetaFields',
];

Expand Down Expand Up @@ -244,6 +254,8 @@ public function __construct(array $data = null)
$this->container['description'] = $data['description'] ?? null;
$this->container['rate'] = $data['rate'] ?? null;
$this->container['internalRate'] = $data['internalRate'] ?? null;
$this->container['exported'] = $data['exported'] ?? null;
$this->container['billable'] = $data['billable'] ?? null;
$this->container['metaFields'] = $data['metaFields'] ?? null;
}

Expand All @@ -265,6 +277,12 @@ public function listInvalidProperties()
if (null === $this->container['project']) {
$invalidProperties[] = "'project' can't be null";
}
if (null === $this->container['exported']) {
$invalidProperties[] = "'exported' can't be null";
}
if (null === $this->container['billable']) {
$invalidProperties[] = "'billable' can't be null";
}

return $invalidProperties;
}
Expand Down Expand Up @@ -544,6 +562,54 @@ public function setInternalRate($internalRate)
return $this;
}

/**
* Gets exported.
*
* @return bool
*/
public function getExported()
{
return $this->container['exported'];
}

/**
* Sets exported.
*
* @param bool $exported exported
*
* @return self
*/
public function setExported($exported)
{
$this->container['exported'] = $exported;

return $this;
}

/**
* Gets billable.
*
* @return bool
*/
public function getBillable()
{
return $this->container['billable'];
}

/**
* Sets billable.
*
* @param bool $billable billable
*
* @return self
*/
public function setBillable($billable)
{
$this->container['billable'] = $billable;

return $this;
}

/**
* Gets metaFields.
*
Expand Down
Loading

0 comments on commit abda713

Please sign in to comment.