Added /system/time API call (#1223)

* Inital structure for /system/time API call

* Parse arguments for offset

* Correctly parsing parameters

* Fixed implimentation, added to openapi.json

* Modified DOC

* Added Sqlite3 time to output

* Fixed error with negative offset

* Review

Co-authored-by: Bernd Bestel <bernd@berrnd.de>
This commit is contained in:
Marc Ole Bulling
2020-12-28 19:39:24 +01:00
committed by GitHub
parent 6fcc0636e8
commit 7e8f460dad
4 changed files with 135 additions and 0 deletions

View File

@@ -145,6 +145,7 @@ $app->group('/api', function (RouteCollectorProxy $group) {
// System
$group->get('/system/info', '\Grocy\Controllers\SystemApiController:GetSystemInfo');
$group->get('/system/time', '\Grocy\Controllers\SystemApiController:GetSystemTime');
$group->get('/system/db-changed-time', '\Grocy\Controllers\SystemApiController:GetDbChangedTime');
$group->get('/system/config', '\Grocy\Controllers\SystemApiController:GetConfig');
$group->post('/system/log-missing-localization', '\Grocy\Controllers\SystemApiController:LogMissingLocalization');