Stamp the upgrade with a version number
authorMike Rylander <mrylander@gmail.com>
Fri, 24 Jun 2011 13:44:56 +0000 (09:44 -0400)
committerMike Rylander <mrylander@gmail.com>
Fri, 24 Jun 2011 13:45:55 +0000 (09:45 -0400)
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Open-ILS/src/sql/Pg/002.schema.config.sql
Open-ILS/src/sql/Pg/upgrade/0563.data.collections_exempt_perm.sql [new file with mode: 0644]
Open-ILS/src/sql/Pg/upgrade/XXXX.data.collections_exempt_perm.sql [deleted file]

index 0a11e2f..5ce512c 100644 (file)
@@ -86,7 +86,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 ('0562', :eg_version); -- berick
+INSERT INTO config.upgrade_log (version, applied_to) VALUES ('0563', :eg_version); -- berick via miker
 
 CREATE TABLE config.bib_source (
        id              SERIAL  PRIMARY KEY,
diff --git a/Open-ILS/src/sql/Pg/upgrade/0563.data.collections_exempt_perm.sql b/Open-ILS/src/sql/Pg/upgrade/0563.data.collections_exempt_perm.sql
new file mode 100644 (file)
index 0000000..a7e6856
--- /dev/null
@@ -0,0 +1,26 @@
+-- Evergreen DB patch XXXX.data.collections_exempt_perm.sql
+--
+-- Adds a new UPDATE_PATRON_COLLECTIONS_EXEMPT permission
+--
+BEGIN;
+
+
+-- check whether patch can be applied
+SELECT evergreen.upgrade_deps_block_check('0563', :eg_version);
+
+INSERT INTO permission.perm_list ( id, code, description ) 
+    VALUES ( 510, 'UPDATE_PATRON_COLLECTIONS_EXEMPT', oils_i18n_gettext(510,
+    'Allows a user to indicate that a patron is exempt from collections processing', 'ppl', 'description'));
+
+--- stock Circulation Administrator group
+
+INSERT INTO permission.grp_perm_map ( grp, perm, depth, grantable )
+    SELECT
+        4,
+        id,
+        0,
+        't'
+    FROM permission.perm_list
+    WHERE code in ('UPDATE_PATRON_COLLECTIONS_EXEMPT');
+
+COMMIT;
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.collections_exempt_perm.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.collections_exempt_perm.sql
deleted file mode 100644 (file)
index dc4c2fd..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
--- Evergreen DB patch XXXX.data.collections_exempt_perm.sql
---
--- Adds a new UPDATE_PATRON_COLLECTIONS_EXEMPT permission
---
-BEGIN;
-
-
--- check whether patch can be applied
-SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-
-INSERT INTO permission.perm_list ( id, code, description ) 
-    VALUES ( 510, 'UPDATE_PATRON_COLLECTIONS_EXEMPT', oils_i18n_gettext(510,
-    'Allows a user to indicate that a patron is exempt from collections processing', 'ppl', 'description'));
-
---- stock Circulation Administrator group
-
-INSERT INTO permission.grp_perm_map ( grp, perm, depth, grantable )
-    SELECT
-        4,
-        id,
-        0,
-        't'
-    FROM permission.perm_list
-    WHERE code in ('UPDATE_PATRON_COLLECTIONS_EXEMPT');
-
-COMMIT;