Labour objectives by employee
Returns, per employee and per month, the service order hours and mechanic task hours worked against the monthly labour-hours objective. Only employee/month pairs with a positive objective and clocked service order hours are returned. When no date range is supplied the current month is used. A range that covers only part of a month compares partial hours against the full monthly objective.
In: header
Query Parameters
Sortable field: employee_id, employee_name, year, month, osv_hours, task_hours, total_hours, objective_hours, difference_hours, achievement_percent.
Sort direction: ASC or DESC. Default order is employee_id, year, month ascending.
"ASC" | "DESC"Items per page. Default 50, maximum 250; a larger value is truncated to 250.
501 <= value <= 250dateOperators: gte, lte. Example: filter[clock_at][gte]=value
dateDeep object filter, one entry per operator. filter[clock_at][gte] and filter[clock_at][lte] bound the period (Y-m-d); the same bounds apply to the service order clock-in datetime and to the mechanic task hours. When no bound is supplied the current month is used. filter[employees][] restricts the employees. The root form clock_at=Y-m-d selects a single day.
Page number. Default 1; a value below 1 counts as 1.
11 <= valueResponse Body
curl -X GET "https://og-tenant1.test:8003/api/v2/workshop/reports/objectives-by-employee?order=string&sorder=ASC&sort=string&limit=50&clock_at=2019-08-24&filter%5Bclock_at%5D%5Boperator%5D=2019-08-24&filter=string&page=1"{
"data": [
{
"employee_id": 0,
"employee_name": "string",
"year": 0,
"month": 0,
"osv_hours": 0,
"task_hours": 0,
"total_hours": 0,
"objective_hours": 0,
"difference_hours": 0,
"achievement_percent": 0
}
],
"meta": {
"per_page": 50,
"current_page": 1,
"has_more": true
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}{
"data": {
"code": "VALIDATION_FAILED",
"message": "The given data was invalid.",
"errors": {
"email": [
"The email field is required."
]
}
},
"meta": {
"trace_id": "9f86d081884c7d659a2feaa0c55ad01568f3a1c2b4d5e"
}
}