#31 API POST Intervention

* adds support for proper POST of intervention
* makes /<id> optional (required for Post)
This commit is contained in:
2022-01-24 12:17:17 +01:00
parent a06eaa49fb
commit a03f9c8c78
12 changed files with 171 additions and 41 deletions

View File

@@ -12,7 +12,11 @@ from api.views.v1.views import EmaAPIViewV1, EcoAccountAPIViewV1, CompensationAP
app_name = "v1"
urlpatterns = [
path("intervention/<id>", InterventionAPIViewV1.as_view(), name="intervention"),
path("intervention/", InterventionAPIViewV1.as_view(), name="intervention"),
path("compensation/<id>", CompensationAPIViewV1.as_view(), name="compensation"),
path("compensation/", CompensationAPIViewV1.as_view(), name="compensation"),
path("ecoaccount/<id>", EcoAccountAPIViewV1.as_view(), name="ecoaccount"),
path("ecoaccount/", EcoAccountAPIViewV1.as_view(), name="ecoaccount"),
path("ema/<id>", EmaAPIViewV1.as_view(), name="ema"),
path("ema/", EmaAPIViewV1.as_view(), name="ema"),
]