diff --git a/db/versions/11394-brownAsparagus/00-firstScript.sql b/db/versions/11394-brownAsparagus/00-firstScript.sql index 6862627273..13b6cfa0dd 100644 --- a/db/versions/11394-brownAsparagus/00-firstScript.sql +++ b/db/versions/11394-brownAsparagus/00-firstScript.sql @@ -6,19 +6,24 @@ INSERT INTO salix.ACL (model, property, accessType, permission, principalType, p ('Vehicle', 'find', 'READ', 'ALLOW', 'ROLE', 'administrative'), ('Vehicle', 'find', 'READ', 'ALLOW', 'ROLE', 'deliveryAssistant'), ('Vehicle', 'findById', 'READ', 'ALLOW', 'ROLE', 'administrative'), + ('Vehicle', 'findById', 'READ', 'ALLOW', 'ROLE', 'deliveryAssistant'), + ('Vehicle', '__get__active', 'READ', 'ALLOW', 'ROLE', 'employee'), ('Vehicle', 'updateAttributes', 'WRITE', 'ALLOW', 'ROLE', 'administrative'), ('Vehicle', 'updateAttributes', 'WRITE', 'ALLOW', 'ROLE', 'deliveryAssistant'), + ('Vehicle', 'deleteById', 'WRITE', 'ALLOW', 'ROLE', 'administrative'), + ('Vehicle', 'deleteById', 'WRITE', 'ALLOW', 'ROLE', 'deliveryAssistant'), + ('Vehicle', 'create', 'WRITE', 'ALLOW', 'ROLE', 'administrative'), + ('Vehicle', 'create', 'WRITE', 'ALLOW', 'ROLE', 'deliveryAssistant'), ('BankPolicy', 'find', 'READ', 'ALLOW', 'ROLE', 'administrative'), ('BankPolicy', 'find', 'READ', 'ALLOW', 'ROLE', 'deliveryAssistant'), ('VehicleState', 'find', 'READ', 'ALLOW', 'ROLE', 'administrative'), ('VehicleState', 'find', 'READ', 'ALLOW', 'ROLE', 'deliveryAssistant'), ('Ppe', 'find', 'READ', 'ALLOW', 'ROLE', 'administrative' ), ('Ppe', 'find', 'READ', 'ALLOW', 'ROLE', 'deliveryAssistant' ), - ('Vehicle', 'deleteById', 'WRITE', 'ALLOW', 'ROLE', 'administrative'), - ('Vehicle', 'deleteById', 'WRITE', 'ALLOW', 'ROLE', 'deliveryAssistant'), ('VehicleType', 'find', 'READ', 'ALLOW', 'ROLE', 'employee'), - ('Vehicle', '__get__active', 'READ', 'ALLOW', 'ROLE', 'employee'); - + ('DeliveryPoint', 'find', 'READ', 'ALLOW', 'ROLE', 'deliveryAssistant'), + ('DeliveryPoint', 'find', 'READ', 'ALLOW', 'ROLE', 'administrative'); + CREATE TABLE IF NOT EXISTS vehicleType ( id INT(11) PRIMARY KEY AUTO_INCREMENT, name VARCHAR(45) NOT NULL diff --git a/modules/route/back/models/vehicle.json b/modules/route/back/models/vehicle.json index 95eac7251c..d64f3df794 100644 --- a/modules/route/back/models/vehicle.json +++ b/modules/route/back/models/vehicle.json @@ -48,6 +48,9 @@ "import": { "type": "number" }, + "importCooler": { + "type": "number" + }, "vin": { "type": "string" }, @@ -56,6 +59,9 @@ }, "vehicleTypeFk": { "type": "number" + }, + "deliveryPointFk": { + "type": "number" } }, "relations": {