From e8fc66f0f612ce6516089894b28899522d13021e Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 31 Jan 2019 16:28:39 -0300 Subject: [PATCH] Bug 21890: Handle can_reset_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 Signed-off-by: Martin Renvoize Signed-off-by: Nick Clemens --- admin/categories.pl | 3 +++ .../prog/en/modules/admin/categories.tt | 12 ++++++++++++ 2 files changed, 15 insertions(+) diff --git a/admin/categories.pl b/admin/categories.pl index b6b6975a77..ba0d11e012 100755 --- a/admin/categories.pl +++ b/admin/categories.pl @@ -92,6 +92,7 @@ elsif ( $op eq 'add_validate' ) { my $BlockExpiredPatronOpacActions = $input->param('BlockExpiredPatronOpacActions'); my $checkPrevCheckout = $input->param('checkprevcheckout'); my $default_privacy = $input->param('default_privacy'); + my $can_reset_password = $input->param('can_reset_password'); my @branches = grep { $_ ne q{} } $input->multi_param('branches'); my $is_a_modif = $input->param("is_a_modif"); @@ -122,6 +123,7 @@ elsif ( $op eq 'add_validate' ) { $category->BlockExpiredPatronOpacActions($BlockExpiredPatronOpacActions); $category->checkprevcheckout($checkPrevCheckout); $category->default_privacy($default_privacy); + $category->can_reset_password($can_reset_password); eval { $category->store; $category->replace_branch_limitations( \@branches ); @@ -148,6 +150,7 @@ elsif ( $op eq 'add_validate' ) { BlockExpiredPatronOpacActions => $BlockExpiredPatronOpacActions, checkprevcheckout => $checkPrevCheckout, default_privacy => $default_privacy, + can_reset_password => $can_reset_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 a7ddf140c9..ff48b74927 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categories.tt @@ -165,6 +165,18 @@ Select All branches if this category type must to be displayed all the time. Otherwise select libraries you want to associate with this value. +
  • + + +