Add endpoint to collect location action timepoints
As a frontend developer I want to have one endpoint to extract all the timepoints for that there is a location action (either begin or end) no matter if it is for a dynamic location or a static one.
Possible paylaod:
GET /controller/configurations/<int:configuration_id>/location-action-timepoints
[{
"timepoint": "2022-01-01T00:00:00Z",
"type": "configuration_static_location",
"attributes": {
"begin_description": "bla bla",
// ...
},
}, {
"timepoint": "2022-01-05T00:00:00Z",
"type": "configuration_dynamic_location",
"attributes": {
"begin_description": "bla bla",
// ...
},
}]
Please note: I think the types must be adjusted further to represent that there are begin dates & end dates.
Acceptance criteria:
-
endpoint is available under /controller/configurations/<int:configuration_id>/location-action-timepoints
-
it contains all begin dates of static location actions -
it contains all begin dates of dynamic location actions -
it just gets the configuration id via the url parameter -
result array is sorted by timestamp (oldest first) -
the payload should contain both begin & end dates (if available) -
Test coverage
Edited by Luca Johannes Nendel