[% PROCESS "opac/parts/header.tt2"; WRAPPER "opac/parts/myopac/prefs_base.tt2"; myopac_page = "prefs"; prefs_page = 'prefs_notify' %]

[% l('Notification Preferences') %]

[% IF ctx.affectedChgs %] [% # get hash of sms carriers keyed by id: temp = ctx.search_csc('active','t'); tcos = { '0' => 'None' }; FOR o IN temp; id = o.id; tcos.$id = o; END; %]

[% l('You have updated notification preferences. Those changes only affect future holds. Would you like to update existing holds to use the new information?') %]

[% SET blnk = l('Blank') %] [% FOR c IN ctx.affectedChgs %] [% END %]
[% IF c.2 == 'sms_info' %] [% ELSE %] [% END %] [% IF c.2 == 'sms_info' %] [% SET disp_name = l('SMS carrier/number') %] [% ELSIF c.2.match('_notify') %] [% SET f_name = c.2.replace("_", " "); Y = l('YES'); N = l('NO') %] [% ELSE %] [% SET f_name = c.2.replace("_", " ") %] [% END %]
[% l('Continue without updating') %]
[% ELSE %]
[% setting = 'opac.hold_notify' %] [% IF ctx.updated_user_settings %] [% END %] [% setting = 'opac.hold_notify' %] [%# WCAG insists that labels for checkboxes contain the input or directly follow the input, which would not look right with the rest of the table. As an alternative, we can repeat the label as a title attr. http://www.w3.org/TR/WCAG20-TECHS/H44.html %] [% email_label = l('Notify by Email by default when a hold is ready for pickup?') %] [%- IF allow_phone_notifications == 'true'; setting = 'opac.hold_notify'; -%] [% phone_label = l('Notify by Phone by default when a hold is ready for pickup?') %] [% setting = 'opac.default_phone' %] [%- END %] [%- IF ctx.get_org_setting(ctx.search_ou, 'sms.enable') == 1; setting = 'opac.hold_notify'; -%] [% sms_label = l('Notify by Text by default when a hold is ready for pickup?') %] [% setting = 'opac.default_sms_notify' %] [% END %] [% FOR optin IN ctx.opt_in_settings %] [% END %]
[% l('Account Successfully Updated') %]
[% l('Default Mobile Carrier') %] [% INCLUDE "opac/parts/sms_carrier_selector.tt2" sms_carrier_hide_label="true" %]
[% l('Hint: use the full 10 digits of your phone #, no spaces, no dashes'); %]
[% END %] [% END %]