From: scottmk Date: Thu, 8 Apr 2010 23:57:34 +0000 (+0000) Subject: Adding amount_paid columns to acq.invoice_item, acq.invoice_entry. X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=6ad76042db0ce36081cda380a5215ddb51ecb67e;p=evergreen%2Fbjwebb.git Adding amount_paid columns to acq.invoice_item, acq.invoice_entry. M Open-ILS/src/sql/Pg/200.schema.acq.sql M Open-ILS/src/sql/Pg/002.schema.config.sql A Open-ILS/src/sql/Pg/upgrade/0231.schema.acq-inv-amt-paid.sql M Open-ILS/examples/fm_IDL.xml git-svn-id: svn://svn.open-ils.org/ILS/trunk@16186 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/examples/fm_IDL.xml b/Open-ILS/examples/fm_IDL.xml index 57914ad2f..4940ae36b 100644 --- a/Open-ILS/examples/fm_IDL.xml +++ b/Open-ILS/examples/fm_IDL.xml @@ -4679,6 +4679,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA + @@ -4716,6 +4717,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA + diff --git a/Open-ILS/src/sql/Pg/002.schema.config.sql b/Open-ILS/src/sql/Pg/002.schema.config.sql index c604289c3..cbb068cf6 100644 --- a/Open-ILS/src/sql/Pg/002.schema.config.sql +++ b/Open-ILS/src/sql/Pg/002.schema.config.sql @@ -60,7 +60,7 @@ CREATE TABLE config.upgrade_log ( install_date TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW() ); -INSERT INTO config.upgrade_log (version) VALUES ('0230'); -- Scott McKellar +INSERT INTO config.upgrade_log (version) VALUES ('0231'); -- Scott McKellar CREATE TABLE config.bib_source ( id SERIAL PRIMARY KEY, diff --git a/Open-ILS/src/sql/Pg/200.schema.acq.sql b/Open-ILS/src/sql/Pg/200.schema.acq.sql index 16f865be1..7df769d47 100644 --- a/Open-ILS/src/sql/Pg/200.schema.acq.sql +++ b/Open-ILS/src/sql/Pg/200.schema.acq.sql @@ -815,7 +815,8 @@ CREATE TABLE acq.invoice_entry ( note TEXT, billed_per_item BOOL, cost_billed NUMERIC(8,2), - actual_cost NUMERIC(8,2) + actual_cost NUMERIC(8,2), + amount_paid NUMERIC (8,2) ); CREATE TABLE acq.invoice_item_type ( @@ -836,7 +837,8 @@ CREATE TABLE acq.invoice_item ( -- for invoice-only debits: taxes/fees/non-bib i cost_billed NUMERIC(8,2), actual_cost NUMERIC(8,2), fund INT REFERENCES acq.fund (id) - DEFERRABLE INITIALLY DEFERRED + DEFERRABLE INITIALLY DEFERRED, + amount_paid NUMERIC (8,2) ); -- Patron requests diff --git a/Open-ILS/src/sql/Pg/upgrade/0231.schema.acq-inv-amt-paid.sql b/Open-ILS/src/sql/Pg/upgrade/0231.schema.acq-inv-amt-paid.sql new file mode 100644 index 000000000..15b2e9c99 --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/0231.schema.acq-inv-amt-paid.sql @@ -0,0 +1,11 @@ +BEGIN; + +INSERT INTO config.upgrade_log (version) VALUES ('0231'); -- Scott McKellar + +ALTER TABLE acq.invoice_item + ADD COLUMN amount_paid NUMERIC (8,2); + +ALTER TABLE acq.invoice_entry + ADD COLUMN amount_paid NUMERIC (8,2); + +COMMIT;