[open-ils-commits] r15717 - in trunk/Open-ILS: examples src/sql/Pg src/sql/Pg/upgrade (scottmk)

svn at svn.open-ils.org svn at svn.open-ils.org
Fri Mar 5 14:15:30 EST 2010


Author: scottmk
Date: 2010-03-05 14:15:26 -0500 (Fri, 05 Mar 2010)
New Revision: 15717

Added:
   trunk/Open-ILS/src/sql/Pg/upgrade/0180.data.acq.cancel-reasons.sql
Modified:
   trunk/Open-ILS/examples/fm_IDL.xml
   trunk/Open-ILS/src/sql/Pg/002.schema.config.sql
   trunk/Open-ILS/src/sql/Pg/950.data.seed-values.sql
Log:
Add a new permission, ADMIN_ACQ_CANCEL_CAUSE

Add two rows of seed data for acq.cancel_reason

M    Open-ILS/src/sql/Pg/002.schema.config.sql
A    Open-ILS/src/sql/Pg/upgrade/0180.data.acq.cancel-reasons.sql
M    Open-ILS/src/sql/Pg/950.data.seed-values.sql
M    Open-ILS/examples/fm_IDL.xml


Modified: trunk/Open-ILS/examples/fm_IDL.xml
===================================================================
--- trunk/Open-ILS/examples/fm_IDL.xml	2010-03-05 17:08:18 UTC (rev 15716)
+++ trunk/Open-ILS/examples/fm_IDL.xml	2010-03-05 19:15:26 UTC (rev 15717)
@@ -5098,6 +5098,12 @@
 			<link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
 		</links>
 		<permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+			<actions>
+				<create permission="ADMIN_ACQ_CANCEL_CAUSE" context_field="org_unit"/>
+				<retrieve permission="STAFF_LOGIN" context_field="org_unit"/>
+				<update permission="ADMIN_ACQ_CANCEL_CAUSE" context_field="org_unit"/>
+				<delete permission="ADMIN_ACQ_CANCEL_CAUSE" context_field="org_unit"/>
+			</actions>
 		</permacrud>
 	</class>
 

Modified: trunk/Open-ILS/src/sql/Pg/002.schema.config.sql
===================================================================
--- trunk/Open-ILS/src/sql/Pg/002.schema.config.sql	2010-03-05 17:08:18 UTC (rev 15716)
+++ trunk/Open-ILS/src/sql/Pg/002.schema.config.sql	2010-03-05 19:15:26 UTC (rev 15717)
@@ -51,7 +51,7 @@
     install_date    TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW()
 );
 
-INSERT INTO config.upgrade_log (version) VALUES ('0179'); -- dbs
+INSERT INTO config.upgrade_log (version) VALUES ('0180'); -- Scott McKellar
 
 CREATE TABLE config.bib_source (
 	id		SERIAL	PRIMARY KEY,

Modified: trunk/Open-ILS/src/sql/Pg/950.data.seed-values.sql
===================================================================
--- trunk/Open-ILS/src/sql/Pg/950.data.seed-values.sql	2010-03-05 17:08:18 UTC (rev 15716)
+++ trunk/Open-ILS/src/sql/Pg/950.data.seed-values.sql	2010-03-05 19:15:26 UTC (rev 15717)
@@ -1254,7 +1254,8 @@
     (361, 'CAPTURE_RESERVATION', oils_i18n_gettext(361, 'Allows a user to capture booking reservations', 'ppl', 'description')),
     (362, 'MERGE_USERS', oils_i18n_gettext(362, 'Allows user records to be merged', 'ppl', 'description')),
     (363, 'ALLOW_ALT_TCN', oils_i18n_gettext(363, 'Allows staff to import a record using an alternate TCN to avoid conflicts', 'ppl', 'description')),
-    (364, 'ADMIN_TRIGGER_EVENT_DEF', oils_i18n_gettext(364, 'Allow a user to administer trigger event definitions', 'ppl', 'description'))
+    (364, 'ADMIN_TRIGGER_EVENT_DEF', oils_i18n_gettext(364, 'Allow a user to administer trigger event definitions', 'ppl', 'description')),
+	(365, 'ADMIN_ACQ_CANCEL_CAUSE', oils_i18n_gettext(365, 'Allow a user to create/update/delete reasons for order cancellations', 'ppl', 'description')
 ;
 
 SELECT SETVAL('permission.perm_list_id_seq'::TEXT, 1000);
@@ -3933,3 +3934,8 @@
 INSERT INTO acq.invoice_method (code,name) VALUES ('EDI',oils_i18n_gettext('EDI', 'EDI', 'acqim', 'name'));
 INSERT INTO acq.invoice_method (code,name) VALUES ('PPR',oils_i18n_gettext('PPR', 'Paper', 'acqit', 'name'));
 
+INSERT INTO acq.cancel_reason ( id, org_unit, label, description ) VALUES (
+    1, 1, 'invalid_isbn', oils_i18n_gettext( 1, 'ISBN is unrecognizable', 'acqcr', 'label' ));
+INSERT INTO acq.cancel_reason ( id, org_unit, label, description ) VALUES (
+    2, 1, 'postpone', oils_i18n_gettext( 2, 'Title has been postponed', 'acqcr', 'label' ));
+

Added: trunk/Open-ILS/src/sql/Pg/upgrade/0180.data.acq.cancel-reasons.sql
===================================================================
--- trunk/Open-ILS/src/sql/Pg/upgrade/0180.data.acq.cancel-reasons.sql	                        (rev 0)
+++ trunk/Open-ILS/src/sql/Pg/upgrade/0180.data.acq.cancel-reasons.sql	2010-03-05 19:15:26 UTC (rev 15717)
@@ -0,0 +1,15 @@
+BEGIN;
+
+INSERT INTO config.upgrade_log (version) VALUES ('0180'); -- Scott McKellar
+
+INSERT INTO acq.cancel_reason ( id, org_unit, label, description ) VALUES (
+	1, 1, 'invalid_isbn', oils_i18n_gettext( 1, 'ISBN is unrecognizable', 'acqcr', 'label' ));
+
+INSERT INTO acq.cancel_reason ( id, org_unit, label, description ) VALUES (
+	2, 1, 'postpone', oils_i18n_gettext( 2, 'Title has been postponed', 'acqcr', 'label' ));
+
+INSERT INTO permission.perm_list (id, code, description)
+    VALUES (365, 'ADMIN_ACQ_CANCEL_CAUSE', 
+	oils_i18n_gettext( 365, 'Allow a user to create/update/delete reasons for order cancellations', 'ppl', 'description' ));
+
+COMMIT;



More information about the open-ils-commits mailing list