Roll call is a staff work log, so smaller team roles can use it when the module is on. Co-authored-by: Cursor <cursoragent@cursor.com>
9 lines
281 B
SQL
9 lines
281 B
SQL
-- Roll call is for every staff role, including editor and viewer.
|
|
|
|
INSERT INTO role_permissions (role_id, permission_id)
|
|
SELECT r.id, p.id
|
|
FROM roles r
|
|
JOIN permissions p ON p.slug LIKE 'roll_calls.%'
|
|
WHERE r.slug IN ('editor', 'viewer', 'business_staff')
|
|
ON CONFLICT DO NOTHING;
|