]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/sql/Pg/upgrade/1046.data.webstaff_date_format_ou_settings.sql
LP#1835085: stamp DB update
[Evergreen.git] / Open-ILS / src / sql / Pg / upgrade / 1046.data.webstaff_date_format_ou_settings.sql
1 BEGIN;
2
3 SELECT evergreen.upgrade_deps_block_check('1046', :eg_version); -- phasefx/berick/gmcharlt
4
5 INSERT into config.org_unit_setting_type (
6      name
7     ,grp
8     ,label
9     ,description
10     ,datatype
11 ) VALUES ( ----------------------------------------
12      'webstaff.format.dates'
13     ,'gui'
14     ,oils_i18n_gettext(
15          'webstaff.format.dates'
16         ,'Format Dates with this pattern'
17         ,'coust'
18         ,'label'
19     )
20     ,oils_i18n_gettext(
21          'webstaff.format.dates'
22         ,'Format Dates with this pattern (examples: "yyyy-MM-dd" for "2010-04-26", "MMM d, yyyy" for "Apr 26, 2010").  This will be used in areas where a date without a timestamp is sufficient, like Date of Birth.'
23         ,'coust'
24         ,'description'
25     )
26     ,'string'
27 ), ( ----------------------------------------
28      'webstaff.format.date_and_time'
29     ,'gui'
30     ,oils_i18n_gettext(
31          'webstaff.format.date_and_time'
32         ,'Format Date+Time with this pattern'
33         ,'coust'
34         ,'label'
35     )
36     ,oils_i18n_gettext(
37          'webstaff.format.date_and_time'
38         ,'Format Date+Time with this pattern (examples: "yy-MM-dd h:m:s.SSS a" for "16-04-05 2:07:20.666 PM", "yyyy-dd-MMM HH:mm" for "2016-05-Apr 14:07").  This will be used in areas of the client where a date with a timestamp is needed, like Checkout, Due Date, or Record Created.'
39         ,'coust'
40         ,'description'
41     )
42     ,'string'
43 );
44
45 UPDATE
46     config.org_unit_setting_type
47 SET
48     label = 'Deprecated: ' || label -- FIXME: Is this okay?
49 WHERE
50     name IN ('format.date','format.time')
51 ;
52
53 COMMIT;