From: Dan Scott Date: Thu, 22 Sep 2011 05:11:06 +0000 (-0400) Subject: Password resets: avoid run-on subjects X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=3ba2b7b83280933a36b9b24a19bf386afa8dab3f;p=evergreen%2Fjoelewis.git Password resets: avoid run-on subjects The password reset template had a space on the first blank line after the Subject: which lead to the first paragraph being tacked onto the Subject line. Get rid of the space, and create an upgrade script ready to roll. Signed-off-by: Dan Scott --- 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 a5641e9464..8b8b29727a 100644 --- a/Open-ILS/src/sql/Pg/950.data.seed-values.sql +++ b/Open-ILS/src/sql/Pg/950.data.seed-values.sql @@ -6668,7 +6668,7 @@ $$ To: [%- params.recipient_email || user.email %] From: [%- params.sender_email || user.home_ou.email || default_sender %] Subject: [% user.home_ou.name %]: library account password reset request - + You have received this message because you, or somebody else, requested a reset of your library system password. If you did not request a reset of your library system password, just ignore this message and your current password will diff --git a/Open-ILS/src/sql/Pg/upgrade/0627.data.patron-password-reset-msg.sql b/Open-ILS/src/sql/Pg/upgrade/0627.data.patron-password-reset-msg.sql new file mode 100644 index 0000000000..05af6a4caa --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/0627.data.patron-password-reset-msg.sql @@ -0,0 +1,37 @@ +-- Evergreen DB patch 0627.data.patron-password-reset-msg.sql +-- +-- Updates password reset template to match TPAC reset form +-- +BEGIN; + +-- check whether patch can be applied +SELECT evergreen.upgrade_deps_block_check('0627', :eg_version); + +UPDATE action_trigger.event_definition SET template = +$$ +[%- USE date -%] +[%- user = target.usr -%] +To: [%- params.recipient_email || user.email %] +From: [%- params.sender_email || user.home_ou.email || default_sender %] +Subject: [% user.home_ou.name %]: library account password reset request + +You have received this message because you, or somebody else, requested a reset +of your library system password. If you did not request a reset of your library +system password, just ignore this message and your current password will +continue to work. + +If you did request a reset of your library system password, please perform +the following steps to continue the process of resetting your password: + +1. Open the following link in a web browser: https://[% params.hostname %]/eg/opac/password_reset/[% target.uuid %] +The browser displays a password reset form. + +2. Enter your new password in the password reset form in the browser. You must +enter the password twice to ensure that you do not make a mistake. If the +passwords match, you will then be able to log in to your library system account +with the new password. + +$$ +WHERE id = 20; -- Password reset request notification + +COMMIT; diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.patron-password-reset-msg.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.patron-password-reset-msg.sql deleted file mode 100644 index 7eb3bfc266..0000000000 --- a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.patron-password-reset-msg.sql +++ /dev/null @@ -1,38 +0,0 @@ --- Evergreen DB patch XXXX.data.patron-password-reset-msg.sql --- --- FIXME: insert description of change, if needed --- -BEGIN; - - --- check whether patch can be applied -SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version); - -UPDATE action_trigger.event_definition SET template = -$$ -[%- USE date -%] -[%- user = target.usr -%] -To: [%- params.recipient_email || user.email %] -From: [%- params.sender_email || user.home_ou.email || default_sender %] -Subject: [% user.home_ou.name %]: library account password reset request - -You have received this message because you, or somebody else, requested a reset -of your library system password. If you did not request a reset of your library -system password, just ignore this message and your current password will -continue to work. - -If you did request a reset of your library system password, please perform -the following steps to continue the process of resetting your password: - -1. Open the following link in a web browser: https://[% params.hostname %]/eg/opac/password_reset/[% target.uuid %] -The browser displays a password reset form. - -2. Enter your new password in the password reset form in the browser. You must -enter the password twice to ensure that you do not make a mistake. If the -passwords match, you will then be able to log in to your library system account -with the new password. - -$$ -WHERE id = 20; -- Password reset request notification - -COMMIT;