LP1198475: Add database changes for Lost and Paid status.
authorJason Stephenson <jason@sigio.com>
Sun, 3 Nov 2013 14:07:02 +0000 (09:07 -0500)
committerKathy Lussier <klussier@masslnc.org>
Tue, 3 Jun 2014 16:58:32 +0000 (12:58 -0400)
Add the Lost and Paid status to config.copy_status.

Add org_unit_settigs to control if the copy status is used and if the
Lost and Paid stop fines is used.

Signed-off-by: Jason Stephenson <jason@sigio.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/sql/Pg/950.data.seed-values.sql
Open-ILS/src/sql/Pg/upgrade/XXXX.data.lost-and-paid-status.sql [new file with mode: 0644]

index be6fa5b..5e27068 100644 (file)
@@ -324,6 +324,9 @@ INSERT INTO config.copy_status (id,name,copy_active) VALUES (15,oils_i18n_gettex
 INSERT INTO config.copy_status
     (id, name, holdable, opac_visible, copy_active, restrict_copy_delete)
     VALUES (16, oils_i18n_gettext(16, 'Long Overdue', 'ccs', 'name'), 'f', 'f', 'f', 't');
+INSERT INTO config.copy_status
+(id, name, holdable, opac_visible, copy_active, restrict_copy_delete)
+VALUES (17, 'Lost and Paid', FALSE, FALSE, FALSE, TRUE);
 
 
 SELECT SETVAL('config.copy_status_id_seq'::TEXT, 100);
@@ -5004,6 +5007,24 @@ INSERT into config.org_unit_setting_type
         'coust',
         'description'),
     'integer', null)
+,('circ.use_lost_paid_stop_fines',
+ 'circ',
+ oils_i18n_gettext('circ.use_lost_paid_stop_fines',
+     'Use Lost and Paid stop fines reason in circulation',
+     'coust', 'label'),
+ oils_i18n_gettext('circ.use_lost_paid_stop_fines',
+     'Use Lost and Paid stop fines reason in circulation when lost or long overdue billing is paid',
+     'coust', 'description'),
+ 'bool')
+,('circ.use_lost_paid_copy_status',
+ 'circ',
+ oils_i18n_gettext('circ.use_lost_paid_copy_status',
+     'Use Lost and Paid copy status',
+     'coust', 'label'),
+ oils_i18n_gettext('circ.use_lost_paid_copy_status',
+     'Use Lost and Paid copy status when lost or long overdue billing is paid',
+     'coust', 'description'),
+ 'bool')
 ;
 
 UPDATE config.org_unit_setting_type
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lost-and-paid-status.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lost-and-paid-status.sql
new file mode 100644 (file)
index 0000000..966c69e
--- /dev/null
@@ -0,0 +1,26 @@
+INSERT INTO config.copy_status
+(id, name, holdable, opac_visible, copy_active, restrict_copy_delete)
+VALUES (17, 'Lost and Paid', FALSE, FALSE, FALSE, TRUE);
+
+INSERT INTO config.org_unit_setting_type
+(name, grp, label, description, datatype)
+VALUES
+('circ.use_lost_paid_stop_fines',
+ 'circ',
+ oils_i18n_gettext('circ.use_lost_paid_stop_fines',
+     'Use Lost and Paid stop fines reason in circulation',
+     'coust', 'label'),
+ oils_i18n_gettext('circ.use_lost_paid_stop_fines',
+     'Use Lost and Paid stop fines reason in circulation when lost or long overdue billing is paid',
+     'coust', 'description'),
+ 'bool'),
+('circ.use_lost_paid_copy_status',
+ 'circ',
+ oils_i18n_gettext('circ.use_lost_paid_copy_status',
+     'Use Lost and Paid copy status',
+     'coust', 'label'),
+ oils_i18n_gettext('circ.use_lost_paid_copy_status',
+     'Use Lost and Paid copy status when lost or long overdue billing is paid',
+     'coust', 'description'),
+ 'bool');
+