]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/sql/Pg/upgrade/1078.data.add_possibly_missing_billing_types.sql
LP2042879 Shelving Location Groups Admin accessibility
[Evergreen.git] / Open-ILS / src / sql / Pg / upgrade / 1078.data.add_possibly_missing_billing_types.sql
1 BEGIN;
2
3 SELECT evergreen.upgrade_deps_block_check('1078', :eg_version); -- csharp/bshum/gmcharlt
4
5 -- The following billing types would not have been automatically added
6 -- in upgrade scripts between versions 1.2 and 1.4 (early 2009).  We
7 -- add them here.  It's okay if they fail, so this should probably be 
8 -- run outside a transaction if added to the version-upgrade scripts.
9
10 INSERT INTO config.billing_type (id, name, owner)
11     SELECT 7, 'Damaged Item', 1
12     WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Damaged Item');
13
14 INSERT INTO config.billing_type (id, name, owner)
15     SELECT 8, 'Damaged Item Processing Fee', 1
16     WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Damaged Item Processing Fee');
17
18 INSERT INTO config.billing_type (id, name, owner)
19     SELECT 9, 'Notification Fee', 1
20     WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Notification Fee');
21
22 COMMIT;