LP#1744756: Stamping upgrade script for custom perm group display
authorKathy Lussier <klussier@masslnc.org>
Thu, 30 Aug 2018 16:37:45 +0000 (12:37 -0400)
committerKathy Lussier <klussier@masslnc.org>
Thu, 30 Aug 2018 16:37:45 +0000 (12:37 -0400)
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/sql/Pg/002.schema.config.sql
Open-ILS/src/sql/Pg/upgrade/1121.schema.perm-group-display.sql [new file with mode: 0644]
Open-ILS/src/sql/Pg/upgrade/XXXX.schema.perm-group-display.sql [deleted file]

index 7bf7874..d975d9a 100644 (file)
@@ -92,7 +92,7 @@ CREATE TRIGGER no_overlapping_deps
     BEFORE INSERT OR UPDATE ON config.db_patch_dependencies
     FOR EACH ROW EXECUTE PROCEDURE evergreen.array_overlap_check ('deprecates');
 
-INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1120', :eg_version); -- bshum/berick
+INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1121', :eg_version); -- khuckins/berick/kmlussier
 
 CREATE TABLE config.bib_source (
        id              SERIAL  PRIMARY KEY,
diff --git a/Open-ILS/src/sql/Pg/upgrade/1121.schema.perm-group-display.sql b/Open-ILS/src/sql/Pg/upgrade/1121.schema.perm-group-display.sql
new file mode 100644 (file)
index 0000000..4e3681e
--- /dev/null
@@ -0,0 +1,22 @@
+BEGIN;
+SELECT evergreen.upgrade_deps_block_check('1121', :eg_version);
+
+CREATE TABLE permission.grp_tree_display_entry (
+    id      SERIAL PRIMARY KEY,
+    position INTEGER NOT NULL,
+    org     INTEGER NOT NULL REFERENCES actor.org_unit (id)
+            DEFERRABLE INITIALLY DEFERRED,
+    grp     INTEGER NOT NULL REFERENCES permission.grp_tree (id)
+            DEFERRABLE INITIALLY DEFERRED,
+    CONSTRAINT pgtde_once_per_org UNIQUE (org, grp)
+);
+
+ALTER TABLE permission.grp_tree_display_entry
+    ADD COLUMN parent integer REFERENCES permission.grp_tree_display_entry (id)
+            DEFERRABLE INITIALLY DEFERRED;
+
+INSERT INTO permission.perm_list (id, code, description)
+VALUES (609, 'MANAGE_CUSTOM_PERM_GRP_TREE', oils_i18n_gettext( 609,
+    'Allows a user to manage custom permission group lists.', 'ppl', 'description' ));
+            
+COMMIT;
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.perm-group-display.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.perm-group-display.sql
deleted file mode 100644 (file)
index a983ecb..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-BEGIN;
-SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-
-CREATE TABLE permission.grp_tree_display_entry (
-    id      SERIAL PRIMARY KEY,
-    position INTEGER NOT NULL,
-    org     INTEGER NOT NULL REFERENCES actor.org_unit (id)
-            DEFERRABLE INITIALLY DEFERRED,
-    grp     INTEGER NOT NULL REFERENCES permission.grp_tree (id)
-            DEFERRABLE INITIALLY DEFERRED,
-    CONSTRAINT pgtde_once_per_org UNIQUE (org, grp)
-);
-
-ALTER TABLE permission.grp_tree_display_entry
-    ADD COLUMN parent integer REFERENCES permission.grp_tree_display_entry (id)
-            DEFERRABLE INITIALLY DEFERRED;
-
-INSERT INTO permission.perm_list (id, code, description)
-VALUES (609, 'MANAGE_CUSTOM_PERM_GRP_TREE', oils_i18n_gettext( 609,
-    'Allows a user to manage custom permission group lists.', 'ppl', 'description' ));
-            
-COMMIT;
\ No newline at end of file