Support "blanket" (long-lived, multi-invoice) orders via a new "blanket"
boolean on invoice item types. Blanket charges can be invoiced multiple
times by creating a new fund_debit for each invoice item linked to a
blanket po_item.
This change also adds the amounts paid over time for blanket charges to
the Amount Paid summary information for purchase orders containing the
charges.
Adds a new Invoice Item Type of "Blanket Order".
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Conflicts:
Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Invoice.pm
--- /dev/null
+BEGIN;
+
+--SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
+
+ALTER TABLE acq.invoice_item_type
+ ADD COLUMN blanket BOOLEAN NOT NULL DEFAULT FALSE,
+ ADD CONSTRAINT aiit_not_blanket_and_prorate
+ CHECK (blanket IS FALSE OR prorate IS FALSE);
+
+COMMIT;
--- /dev/null
+BEGIN;
+
+--SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
+
+INSERT INTO acq.invoice_item_type (code, blanket, name) VALUES (
+ 'BLA', TRUE, oils_i18n_gettext('BLA', 'Blanket Order', 'aiit', 'name'));
+
+COMMIT;