[open-ils-commits] r17868 - in branches/rel_2_0/Open-ILS/src: perlmods/OpenILS/Application/Trigger sql/Pg sql/Pg/upgrade (phasefx)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Sep 21 12:21:04 EDT 2010
Author: phasefx
Date: 2010-09-21 12:21:00 -0400 (Tue, 21 Sep 2010)
New Revision: 17868
Added:
branches/rel_2_0/Open-ILS/src/sql/Pg/upgrade/0412.data.trigger.validator.HoldIsCancelled.sql
Modified:
branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Trigger/Validator.pm
branches/rel_2_0/Open-ILS/src/sql/Pg/002.schema.config.sql
branches/rel_2_0/Open-ILS/src/sql/Pg/1.6.1-2.0-upgrade-db.sql
branches/rel_2_0/Open-ILS/src/sql/Pg/950.data.seed-values.sql
Log:
merge r17867 from trunk for HoldIsCancelled action_trigger validator
Modified: branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Trigger/Validator.pm
===================================================================
--- branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Trigger/Validator.pm 2010-09-21 16:19:04 UTC (rev 17867)
+++ branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Trigger/Validator.pm 2010-09-21 16:21:00 UTC (rev 17868)
@@ -82,4 +82,13 @@
return 0;
}
+sub HoldIsCancelled {
+ my $self = shift;
+ my $env = shift;
+
+ my $hold = $env->{target};
+
+ return ($hold->cancel_time) ? 1 : 0;
+}
+
1;
Modified: branches/rel_2_0/Open-ILS/src/sql/Pg/002.schema.config.sql
===================================================================
--- branches/rel_2_0/Open-ILS/src/sql/Pg/002.schema.config.sql 2010-09-21 16:19:04 UTC (rev 17867)
+++ branches/rel_2_0/Open-ILS/src/sql/Pg/002.schema.config.sql 2010-09-21 16:21:00 UTC (rev 17868)
@@ -70,7 +70,7 @@
install_date TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW()
);
-INSERT INTO config.upgrade_log (version) VALUES ('0411'); -- gmc
+INSERT INTO config.upgrade_log (version) VALUES ('0412'); -- phasefx
CREATE TABLE config.bib_source (
id SERIAL PRIMARY KEY,
Modified: branches/rel_2_0/Open-ILS/src/sql/Pg/1.6.1-2.0-upgrade-db.sql
===================================================================
--- branches/rel_2_0/Open-ILS/src/sql/Pg/1.6.1-2.0-upgrade-db.sql 2010-09-21 16:19:04 UTC (rev 17867)
+++ branches/rel_2_0/Open-ILS/src/sql/Pg/1.6.1-2.0-upgrade-db.sql 2010-09-21 16:21:00 UTC (rev 17868)
@@ -4619,6 +4619,16 @@
(35, 'pickup_lib')
;
+INSERT INTO action_trigger.validator (module, description) VALUES (
+ 'HoldIsCancelled',
+ oils_i18n_gettext(
+ 'HoldIsCancelled',
+ 'Check whether a hold request is cancelled.',
+ 'atval',
+ 'description'
+ )
+);
+
-- Create the query schema, and the tables and views therein
DROP SCHEMA IF EXISTS sql CASCADE;
Modified: branches/rel_2_0/Open-ILS/src/sql/Pg/950.data.seed-values.sql
===================================================================
--- branches/rel_2_0/Open-ILS/src/sql/Pg/950.data.seed-values.sql 2010-09-21 16:19:04 UTC (rev 17867)
+++ branches/rel_2_0/Open-ILS/src/sql/Pg/950.data.seed-values.sql 2010-09-21 16:21:00 UTC (rev 17868)
@@ -7559,4 +7559,15 @@
'bool')
;
+-- 0412.data.trigger.validator.HoldIsCancelled.sql
+INSERT INTO action_trigger.validator (module, description) VALUES (
+ 'HoldIsCancelled',
+ oils_i18n_gettext(
+ 'HoldIsCancelled',
+ 'Check whether a hold request is cancelled.',
+ 'atval',
+ 'description'
+ )
+);
+
Copied: branches/rel_2_0/Open-ILS/src/sql/Pg/upgrade/0412.data.trigger.validator.HoldIsCancelled.sql (from rev 17867, trunk/Open-ILS/src/sql/Pg/upgrade/0412.data.trigger.validator.HoldIsCancelled.sql)
===================================================================
--- branches/rel_2_0/Open-ILS/src/sql/Pg/upgrade/0412.data.trigger.validator.HoldIsCancelled.sql (rev 0)
+++ branches/rel_2_0/Open-ILS/src/sql/Pg/upgrade/0412.data.trigger.validator.HoldIsCancelled.sql 2010-09-21 16:21:00 UTC (rev 17868)
@@ -0,0 +1,16 @@
+BEGIN;
+
+INSERT INTO config.upgrade_log (version) VALUES ('0412'); -- phasefx
+
+INSERT INTO action_trigger.validator (module, description) VALUES (
+ 'HoldIsCancelled',
+ oils_i18n_gettext(
+ 'HoldIsCancelled',
+ 'Check whether a hold request is cancelled.',
+ 'atval',
+ 'description'
+ )
+);
+
+COMMIT;
+
More information about the open-ils-commits
mailing list