diff --git a/db/versions/11073-crimsonBirch/00-firstScript.sql b/db/versions/11073-crimsonBirch/00-firstScript.sql new file mode 100644 index 000000000..2ad04468f --- /dev/null +++ b/db/versions/11073-crimsonBirch/00-firstScript.sql @@ -0,0 +1,9 @@ +-- Auto-generated SQL script. Actual values for binary/complex data types may differ - what you see is the default string representation of values. +INSERT INTO salix.ACL (model,property,accessType,permission,principalType,principalId) + VALUES ('TrainingCourse','*','*','ALLOW','ROLE','employee'); +INSERT INTO salix.ACL (model,property,accessType,permission,principalType,principalId) + VALUES ('TrainingCourseType','*','*','ALLOW','ROLE','employee'); +INSERT INTO salix.ACL (model,property,accessType,permission,principalType,principalId) + VALUES ('TrainingCenter','*','*','ALLOW','ROLE','employee'); +INSERT INTO salix.ACL (model,property,accessType,permission,principalType,principalId) + VALUES ('Worker','__get_trainingCourse','*','ALLOW','ROLE','employee'); diff --git a/modules/worker/back/model-config.json b/modules/worker/back/model-config.json index b7c355511..9bf2f014f 100644 --- a/modules/worker/back/model-config.json +++ b/modules/worker/back/model-config.json @@ -124,6 +124,15 @@ }, "Locker": { "dataSource": "vn" + }, + "TrainingCourse": { + "dataSource": "vn" + }, + "TrainingCourseType": { + "dataSource": "vn" + }, + "TrainingCenter": { + "dataSource": "vn" } } diff --git a/modules/worker/back/models/trainingCourseType.json b/modules/worker/back/models/trainingCourseType.json index 1dc708f2f..1a2a45bc7 100644 --- a/modules/worker/back/models/trainingCourseType.json +++ b/modules/worker/back/models/trainingCourseType.json @@ -1,5 +1,5 @@ { - "name": "trainingCourseType", + "name": "TrainingCourseType", "description": "List of trainings", "base": "VnModel", "options": { @@ -27,7 +27,7 @@ }, "trainingCourseType": { "type": "belongsTo", - "model": "trainingCourseType", + "model": "TrainingCourseType", "foreignKey": "trainingCourseTypeFk" }, "centerFk": {