From: Jeff Davis Date: Wed, 3 May 2023 05:33:43 +0000 (-0700) Subject: LP#1979345: Stamping upgrade script X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=9e98ef97bfa5c1d0c4d01a00bfd2221adfa27f77;p=evergreen%2Fpines.git LP#1979345: Stamping upgrade script Signed-off-by: Jeff Davis --- diff --git a/Open-ILS/src/sql/Pg/upgrade/1372.data.permission.hold_pull_list.sql b/Open-ILS/src/sql/Pg/upgrade/1372.data.permission.hold_pull_list.sql new file mode 100644 index 0000000000..afcc8f55e7 --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/1372.data.permission.hold_pull_list.sql @@ -0,0 +1,21 @@ +BEGIN; + +SELECT evergreen.upgrade_deps_block_check('1372', :eg_version); + +INSERT INTO permission.perm_list (id, code, description) VALUES + ( 643, 'VIEW_HOLD_PULL_LIST', oils_i18n_gettext(643, + 'View hold pull list', 'ppl', 'description')); + +-- by default, assign VIEW_HOLD_PULL_LIST to everyone who has VIEW_HOLDS +INSERT INTO permission.grp_perm_map (perm, grp, depth, grantable) + SELECT 643, grp, depth, grantable + FROM permission.grp_perm_map + WHERE perm = 9; + +INSERT INTO permission.usr_perm_map (perm, usr, depth, grantable) + SELECT 643, usr, depth, grantable + FROM permission.usr_perm_map + WHERE perm = 9; + +COMMIT; + diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.permission.hold_pull_list.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.permission.hold_pull_list.sql deleted file mode 100644 index 078f661319..0000000000 --- a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.permission.hold_pull_list.sql +++ /dev/null @@ -1,21 +0,0 @@ -BEGIN; - -SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version); - -INSERT INTO permission.perm_list (id, code, description) VALUES - ( 643, 'VIEW_HOLD_PULL_LIST', oils_i18n_gettext(643, - 'View hold pull list', 'ppl', 'description')); - --- by default, assign VIEW_HOLD_PULL_LIST to everyone who has VIEW_HOLDS -INSERT INTO permission.grp_perm_map (perm, grp, depth, grantable) - SELECT 643, grp, depth, grantable - FROM permission.grp_perm_map - WHERE perm = 9; - -INSERT INTO permission.usr_perm_map (perm, usr, depth, grantable) - SELECT 643, usr, depth, grantable - FROM permission.usr_perm_map - WHERE perm = 9; - -COMMIT; -