Bugzilla – Attachment 87298 Details for
Bug 10796
Allow password changes for logged in OPAC users by patron category
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10796: Handle can_change_password on the staff interface
Bug-10796-Handle-canchangepassword-on-the-staff-in.patch (text/plain), 4.91 KB, created by
Martin Renvoize (ashimema)
on 2019-04-01 18:23:32 UTC
(
hide
)
Description:
Bug 10796: Handle can_change_password on the staff interface
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2019-04-01 18:23:32 UTC
Size:
4.91 KB
patch
obsolete
>From 9916d299d2ebc00287458dfb6b9ae1401ca96576 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Wed, 20 Feb 2019 13:36:55 -0300 >Subject: [PATCH] Bug 10796: Handle can_change_password on the staff interface > >This patch makes the staff interface handle the new flag when editing >the categories. I didn't add the flag to the list of categories table >because it makes it too big, but can be easily added if required by >users or QA. > >To test: >- Along with other patches from this bug, edit patron categories >=> SUCCESS: Notice the changes are correctly stored >- Sign off :-D > >Signed-off-by: Liz Rea <wizzyrea@gmail.com> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > admin/categories.pl | 4 +++ > .../prog/en/modules/admin/categories.tt | 32 +++++++++++++++++++ > 2 files changed, 36 insertions(+) > >diff --git a/admin/categories.pl b/admin/categories.pl >index b824b9b6b6..f9144e7ced 100755 >--- a/admin/categories.pl >+++ b/admin/categories.pl >@@ -93,9 +93,11 @@ elsif ( $op eq 'add_validate' ) { > my $checkPrevCheckout = $input->param('checkprevcheckout'); > my $default_privacy = $input->param('default_privacy'); > my $reset_password = $input->param('reset_password'); >+ my $change_password = $input->param('change_password'); > my @branches = grep { $_ ne q{} } $input->multi_param('branches'); > > $reset_password = undef if $reset_password eq -1; >+ $change_password = undef if $change_password eq -1; > > my $is_a_modif = $input->param("is_a_modif"); > >@@ -126,6 +128,7 @@ elsif ( $op eq 'add_validate' ) { > $category->checkprevcheckout($checkPrevCheckout); > $category->default_privacy($default_privacy); > $category->reset_password($reset_password); >+ $category->change_password($change_password); > eval { > $category->store; > $category->replace_branch_limitations( \@branches ); >@@ -153,6 +156,7 @@ elsif ( $op eq 'add_validate' ) { > checkprevcheckout => $checkPrevCheckout, > default_privacy => $default_privacy, > reset_password => $reset_password, >+ change_password => $change_password, > }); > eval { > $category->store; >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt >index 5cc99d7a0b..143c1a6711 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt >@@ -197,6 +197,38 @@ > [% END %] > </select> > </li> >+ <li> >+ <label for="change_password">Password change in OPAC: </label> >+ <select name="change_password" id="change_password"> >+ [% IF category.change_password.defined %] >+ [% IF category.change_password %] >+ [% IF Koha.Preference('OpacPasswordChange') %] >+ <option value="-1">Follow system preference OpacPasswordChange (enabled)</option> >+ [% ELSE %] >+ <option value="-1">Follow system preference OpacPasswordChange (disabled)</option> >+ [% END %] >+ <option value="1" selected="selected">Allowed</option> >+ <option value="0">Not allowed</option> >+ [% ELSE %] >+ [% IF Koha.Preference('OpacPasswordChange') %] >+ <option value="-1">Follow system preference OpacPasswordChange (enabled)</option> >+ [% ELSE %] >+ <option value="-1">Follow system preference OpacPasswordChange (disabled)</option> >+ [% END %] >+ <option value="1">Allowed</option> >+ <option value="0" selected="selected">Not allowed</option> >+ [% END %] >+ [% ELSE %] >+ [% IF Koha.Preference('OpacPasswordChange') %] >+ <option value="-1" selected="selected">Follow system preference OpacPasswordChange (enabled)</option> >+ [% ELSE %] >+ <option value="-1" selected="selected">Follow system preference OpacPasswordChange (disabled)</option> >+ [% END %] >+ <option value="1">Allowed</option> >+ <option value="0">Not allowed</option> >+ [% END %] >+ </select> >+ </li> > <li><label for="block_expired">Block expired patrons:</label> > <select name="BlockExpiredPatronOpacActions" id="block_expired"> > [% IF not category or category.BlockExpiredPatronOpacActions == -1%] >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 10796
:
85389
|
85390
|
85391
|
85392
|
85393
|
87117
|
87118
|
87119
|
87120
|
87121
|
87296
|
87297
| 87298 |
87299
|
87300