See ticket 4201.
M Open-ILS/src/sql/Pg/002.schema.config.sql
A Open-ILS/src/sql/Pg/upgrade/0157.data.fund-spending-limits.sql
M Open-ILS/src/sql/Pg/950.data.seed-values.sql
git-svn-id: svn://svn.open-ils.org/ILS/trunk@15483
dcc99617-32d9-48b4-a31d-
7c20da2025e4
install_date TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW()
);
-INSERT INTO config.upgrade_log (version) VALUES ('0156'); -- senator
+INSERT INTO config.upgrade_log (version) VALUES ('0157'); -- Scott McKellar
CREATE TABLE config.bib_source (
id SERIAL PRIMARY KEY,
'bool'
);
+-- Org unit settings for fund spending limits
+
+INSERT INTO config.org_unit_setting_type ( name, label, description, datatype )
+VALUES (
+ 'acq.fund.balance_limit.warn',
+ oils_i18n_gettext('acq.fund.balance_limit.warn', 'Fund Spending Limit for Warning', 'coust', 'label'),
+ oils_i18n_gettext('acq.fund.balance_limit.warn', 'When the amount remaining in the fund, including spent money and encumbrances, goes below this percentage, attempts to spend from the fund will result in a warning to the staff.', 'coust', 'descripton'),
+ 'integer'
+);
+
+INSERT INTO config.org_unit_setting_type ( name, label, description, datatype )
+VALUES (
+ 'acq.fund.balance_limit.block',
+ oils_i18n_gettext('acq.fnd.balance_limit.block', 'Fund Spending Limit for Block', 'coust', 'label'),
+ oils_i18n_gettext('acq.fund.balance_limit.block', 'When the amount remaining in the fund, including spent money and encumbrances, goes below this percentage, attempts to spend from the fund will be blocked.', 'coust', 'description'),
+ 'integer'
+);
--- /dev/null
+BEGIN;
+
+INSERT INTO config.upgrade_log (version) VALUES ('0157'); -- Scott McKellar
+
+INSERT INTO config.org_unit_setting_type ( name, label, description, datatype )
+VALUES (
+ 'acq.fund.balance_limit.warn',
+ oils_i18n_gettext('acq.fund.balance_limit.warn', 'Fund Spending Limit for Warning', 'coust', 'label'),
+ oils_i18n_gettext('acq.fund.balance_limit.warn', 'When the amount remaining in the fund, including spent money and encumbrances, goes below this percentage, attempts to spend from the fund will result in a warning to the staff.', 'coust', 'descripton'),
+ 'integer'
+);
+
+INSERT INTO config.org_unit_setting_type ( name, label, description, datatype )
+VALUES (
+ 'acq.fund.balance_limit.block',
+ oils_i18n_gettext('acq.fnd.balance_limit.block', 'Fund Spending Limit for Block', 'coust', 'label'),
+ oils_i18n_gettext('acq.fund.balance_limit.block', 'When the amount remaining in the fund, including spent money and encumbrances, goes below this percentage, attempts to spend from the fund will be blocked.', 'coust', 'description'),
+ 'integer'
+);
+
+COMMIT;