Timesheet User ApplicationΒΆ
The timesheet module defines some routes for user applications:
GET
/<database_name>/timesheet/employees
: return the list of the user employees as dictionary with the keys:id
andname
.
GET
/<database_name>/timesheet/employee/<int:employee>/works
: return the list of works available for the employee. The works are dictionary with keys:id
,name
,start
andend
. The dates are in the format%Y-%m-%d
.
GET
/<database_name>/timesheet/employee/<int:employee>/lines/<date>
: return the list of timesheet lines for the employee at the date (%Y-%m-%d
). The lines are dictionary with keys:id
,work
,work.name
,duration
,description
anduuid
. The duration is in seconds.
POST
/<database_name>/timesheet/line
: Create a line using the data as dictionary of value. The date must be in the format%Y-%m-%d
and theduration
in seconds. If auuid
value is provided, it will update the record if found instead of create a new one.
PUT
/<database_name>/timesheet/line/<int:line>
: Update the line using the data like for thePOST
.
DELETE
/<database_name>/timesheet/line/<int:line>
: Delete the line