]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/sql/Pg/upgrade/1260.data.lp1908440.photo_url_editing.sql
LP1615805 No inputs after submit in patron search (AngularJS)
[Evergreen.git] / Open-ILS / src / sql / Pg / upgrade / 1260.data.lp1908440.photo_url_editing.sql
1 BEGIN;
2
3 SELECT evergreen.upgrade_deps_block_check('1260', :eg_version);
4
5 INSERT into config.org_unit_setting_type
6     (name, grp, label, description, datatype)
7     VALUES (
8         'ui.patron.edit.au.photo_url.require',
9         'gui',
10         oils_i18n_gettext(
11             'ui.patron.edit.au.photo_url.require',
12             'Require Photo URL field on patron registration',
13             'coust',
14             'label'
15         ),
16         oils_i18n_gettext(
17             'ui.patron.edit.au.photo_url.require',
18             'The Photo URL field will be required on the patron registration screen.',
19             'coust',
20             'description'
21         ),
22         'bool'
23     );
24
25 INSERT into config.org_unit_setting_type
26     (name, grp, label, description, datatype)
27     VALUES (
28         'ui.patron.edit.au.photo_url.show',
29         'gui',
30         oils_i18n_gettext(
31             'ui.patron.edit.au.photo_url.show',
32             'Show Photo URL field on patron registration',
33             'coust',
34             'label'
35         ),
36         oils_i18n_gettext(
37             'ui.patron.edit.au.photo_url.show',
38             'The Photo URL field will be shown on the patron registration screen. Showing a field makes it appear with required fields even when not required. If the field is required this setting is ignored.',
39             'coust',
40             'description'
41         ),
42         'bool'
43     );
44
45 INSERT into config.org_unit_setting_type
46     (name, grp, label, description, datatype)
47     VALUES (
48         'ui.patron.edit.au.photo_url.suggest',
49         'gui',
50         oils_i18n_gettext(
51             'ui.patron.edit.au.photo_url.suggest',
52             'Suggest Photo URL field on patron registration',
53             'coust',
54             'label'
55         ),
56
57         oils_i18n_gettext(
58             'ui.patron.edit.au.photo_url.suggest',
59             'The Photo URL field will be suggested on the patron registration screen. Suggesting a field makes it appear when suggested fields are shown. If the field is shown or required this setting is ignored.',
60             'coust',
61             'description'
62         ),
63         'bool'
64     );
65
66 INSERT INTO permission.perm_list ( id, code, description ) VALUES
67 ( 632, 'UPDATE_USER_PHOTO_URL', oils_i18n_gettext( 632,
68    'Update the user photo url field in patron registration and editor', 'ppl', 'description' ))
69 ;
70
71 INSERT INTO permission.grp_perm_map (grp, perm, depth, grantable)
72         SELECT
73                 pgt.id, perm.id, aout.depth, FALSE
74         FROM
75                 permission.grp_tree pgt,
76                 permission.perm_list perm,
77                 actor.org_unit_type aout
78         WHERE
79                 pgt.name = 'Circulators' AND
80                 aout.name = 'System' AND
81                 perm.code = 'UPDATE_USER_PHOTO_URL'
82 ;
83
84 COMMIT;