From 086b7aed4b2e2fcf25db2f5b7ddfbdc7075ec09c Mon Sep 17 00:00:00 2001 From: jorgep Date: Tue, 24 Dec 2024 10:40:17 +0100 Subject: [PATCH] feat: refs #7119 add VehicleState model with data source configuration --- modules/route/back/model-config.json | 3 ++ modules/route/back/models/vehicle-state.json | 29 ++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 modules/route/back/models/vehicle-state.json diff --git a/modules/route/back/model-config.json b/modules/route/back/model-config.json index fb1c5d7fd..8b47c5347 100644 --- a/modules/route/back/model-config.json +++ b/modules/route/back/model-config.json @@ -35,6 +35,9 @@ "Vehicle": { "dataSource": "vn" }, + "VehicleState": { + "dataSource": "vn" + }, "RoutesMonitor": { "dataSource": "vn" } diff --git a/modules/route/back/models/vehicle-state.json b/modules/route/back/models/vehicle-state.json new file mode 100644 index 000000000..1f71333eb --- /dev/null +++ b/modules/route/back/models/vehicle-state.json @@ -0,0 +1,29 @@ +{ + "name": "VehicleState", + "base": "VnModel", + "options": { + "mysql": { + "table": "vehicleState" + } + }, + "properties": { + "id": { + "type": "number", + "id": true + }, + "state": { + "type": "string" + }, + "hasToNotify": { + "type": "number" + } + }, + "acls": [ + { + "accessType": "READ", + "principalType": "ROLE", + "principalId": "$everyone", + "permission": "ALLOW" + } + ] +} \ No newline at end of file