From 40ec16b3467d8b3bf5a61ec7b94d108b01f44bf7 Mon Sep 17 00:00:00 2001 From: "cyril.tsui" Date: Tue, 2 Jul 2024 17:52:31 +0800 Subject: [PATCH] update master data authority --- .../20240702_01_cyril/01_update_authority.sql | 81 +++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 src/main/resources/db/changelog/changes/20240702_01_cyril/01_update_authority.sql diff --git a/src/main/resources/db/changelog/changes/20240702_01_cyril/01_update_authority.sql b/src/main/resources/db/changelog/changes/20240702_01_cyril/01_update_authority.sql new file mode 100644 index 0000000..393ffc0 --- /dev/null +++ b/src/main/resources/db/changelog/changes/20240702_01_cyril/01_update_authority.sql @@ -0,0 +1,81 @@ +-- liquibase formatted sql +-- changeset cyril:authority, user_authority + +UPDATE authority +SET name='Maintain User in Master Data' +WHERE id=1; +UPDATE authority +SET name='Maintain User Group in Master Data' +WHERE id=2; +UPDATE authority +SET name='View User in Master Data' +WHERE id=3; +UPDATE authority +SET name='View User Group in Master Data' +WHERE id=4; +DELETE FROM authority +WHERE id=5; +DELETE FROM authority +WHERE id=6; +INSERT INTO authority (authority,name) +VALUES ('VIEW_CLIENT','View Client in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_SUBSIDIARY','View Subsidiary in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_STAFF','View Staff in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_COMPANY','View Company in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_SKILL','View Skill in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_DEPARTMENT','View Department in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_POSITION','View Position in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_SALARY','View Salary in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_TEAM','View Team in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('VIEW_HOLIDAY','View Holiday in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_CLIENT','Maintain Client in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_SUBSIDIARY','Maintain Subsidiary in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_STAFF','Maintain Staff in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_COMPANY','Maintain Company in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_SKILL','Maintain Skill in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_DEPARTMENT','Maintain Department in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_POSITION','Maintain Position in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_SALARY','Maintain Salary in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_TEAM','Maintain Team in Master Data'); +INSERT INTO authority (authority,name) +VALUES ('MAINTAIN_HOLIDAY','Maintain Holiday in Master Data'); + +INSERT INTO `user_authority` VALUES +(1,21), +(1,22), +(1,23), +(1,24), +(1,25), +(1,26), +(1,27), +(1,28), +(1,29), +(1,30), +(1,31), +(1,32), +(1,33), +(1,34), +(1,35), +(1,36), +(1,37), +(1,38), +(1,39), +(1,40); \ No newline at end of file