2023-04-19 11:59:26 +00:00
|
|
|
-- DmsType model
|
|
|
|
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`)
|
|
|
|
SELECT 'DmsType', d.code, 'WRITE', 'ALLOW', 'ROLE', r.name
|
|
|
|
FROM `vn`.`dmsType` d
|
|
|
|
JOIN `account`.`role` r ON r.id = d.writeRoleFk;
|
|
|
|
|
|
|
|
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`)
|
|
|
|
SELECT 'DmsType', d.code, 'READ', 'ALLOW', 'ROLE', r.name
|
|
|
|
FROM `vn`.`dmsType` d
|
|
|
|
JOIN `account`.`role` r ON r.id = d.readRoleFk;
|
|
|
|
|
|
|
|
-- ImageCollection model
|
|
|
|
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`)
|
|
|
|
SELECT 'ImageCollection', i.name, 'WRITE', 'ALLOW', 'ROLE', r.name
|
|
|
|
FROM `hedera`.`imageCollection` i
|
|
|
|
JOIN `account`.`role` r ON r.id = i.writeRoleFk;
|
|
|
|
|
|
|
|
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`)
|
|
|
|
SELECT 'ImageCollection', i.name, 'READ', 'ALLOW', 'ROLE', r.name
|
|
|
|
FROM `hedera`.`imageCollection` i
|
|
|
|
JOIN `account`.`role` r ON r.id = i.readRoleFk;
|
|
|
|
|
2023-04-19 13:23:32 +00:00
|
|
|
-- ClaimState
|
|
|
|
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`)
|
|
|
|
SELECT 'ClaimState', c.code, 'WRITE', 'ALLOW', 'ROLE', r.name
|
|
|
|
FROM `vn`.`claimState` c
|
|
|
|
JOIN `account`.`role` r ON r.id = c.roleFk;
|
|
|
|
|