From: Kyle Huckins Date: Wed, 12 Dec 2018 21:05:38 +0000 (+0000) Subject: lp1777677 Test Notification Permission & String change X-Git-Url: http://git.equinoxoli.org/?p=evergreen-equinox.git;a=commitdiff_plain;h=b7778f561b94997bee694689b84ba257442901b7 lp1777677 Test Notification Permission & String change - Update permission requirement to OPAC_LOGIN - Update strings to be more end-user friendly Signed-off-by: Kyle Huckins Signed-off-by: Terran McCanna Signed-off-by: Chris Sharp Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm index b703f79..35abb96d 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Actor.pm @@ -4363,7 +4363,7 @@ sub fire_test_notification { my $e = new_editor(authtoken => $auth); return $e->event unless $e->checkauth; return $e->event unless $$args{home_ou}; - return $e->die_event unless $e->allowed('UPDATE_USER', $$args{home_ou}); + return $e->die_event unless $e->allowed('OPAC_LOGIN', $$args{home_ou}); my $event_hook = $$args{event_def_type} or return $e->event; my $usr = $e->retrieve_actor_user($$args{target}); diff --git a/Open-ILS/src/sql/Pg/950.data.seed-values.sql b/Open-ILS/src/sql/Pg/950.data.seed-values.sql index 78a8b3c..af65b92 100644 --- a/Open-ILS/src/sql/Pg/950.data.seed-values.sql +++ b/Open-ILS/src/sql/Pg/950.data.seed-values.sql @@ -17252,9 +17252,9 @@ $$ [%- sms_carrier = helpers.get_user_setting(target.id, 'opac.default_sms_carrier') -%] From: [%- helpers.get_org_setting(target.home_ou.id, 'org.bounced_emails') || lib.email || params.sender_email || default_sender %] To: [%- helpers.get_sms_gateway_email(sms_carrier,sms_number) %] -Subject: Test SMS +Subject: Test Text Message -This is a test confirming your default SMS information at [% lib.name %]. +This is a test confirming your mobile number for [% lib.name %] is correct. Sincerely, [% lib.name %] diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1777677-action-triggers-test-notification.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1777677-action-triggers-test-notification.sql index 30f8364..4c22110 100644 --- a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1777677-action-triggers-test-notification.sql +++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1777677-action-triggers-test-notification.sql @@ -58,9 +58,9 @@ $$ [%- sms_carrier = helpers.get_user_setting(target.id, 'opac.default_sms_carrier') -%] From: [%- helpers.get_org_setting(target.home_ou.id, 'org.bounced_emails') || lib.email || params.sender_email || default_sender %] To: [%- helpers.get_sms_gateway_email(sms_carrier,sms_number) %] -Subject: Test SMS +Subject: Test Text Message -This is a test confirming your default SMS information at [% lib.name %]. +This is a test confirming your mobile number for [% lib.name %] is correct. Sincerely, [% lib.name %] diff --git a/Open-ILS/src/templates/opac/myopac/prefs.tt2 b/Open-ILS/src/templates/opac/myopac/prefs.tt2 index e609908..f722020 100644 --- a/Open-ILS/src/templates/opac/myopac/prefs.tt2 +++ b/Open-ILS/src/templates/opac/myopac/prefs.tt2 @@ -93,7 +93,7 @@ - [% INCLUDE "opac/myopac/test_notification.tt2" %] + [% INCLUDE "opac/myopac/test_notification.tt2" message_type = "email" %] diff --git a/Open-ILS/src/templates/opac/myopac/prefs_notify.tt2 b/Open-ILS/src/templates/opac/myopac/prefs_notify.tt2 index a868c40..a778425 100644 --- a/Open-ILS/src/templates/opac/myopac/prefs_notify.tt2 +++ b/Open-ILS/src/templates/opac/myopac/prefs_notify.tt2 @@ -127,7 +127,7 @@ [% setting = 'opac.default_sms_notify' %] - [% INCLUDE "opac/myopac/test_notification.tt2" %] + [% INCLUDE "opac/myopac/test_notification.tt2" message_type = "sms" %] diff --git a/Open-ILS/src/templates/opac/myopac/test_notification.tt2 b/Open-ILS/src/templates/opac/myopac/test_notification.tt2 index a092924..7f5d92e 100644 --- a/Open-ILS/src/templates/opac/myopac/test_notification.tt2 +++ b/Open-ILS/src/templates/opac/myopac/test_notification.tt2 @@ -1,8 +1,12 @@
- [% l('Notification Sent') %] + [% l('Message Sent') %]
- [% l('If you do not receive a notification, contact your Library for more information.') %] + [% l('If you do not receive ') %] [% IF message_type == "email" %] + [% l(a'n email') %] + [% ELSIF message_type == "sms" %] + [% l(' text') %] + [% END %] [% l('message, contact your Library for more information.') %]
[% ctx.user.home_ou.name %]