From 19d9f19d2fc76d3c5967bd0760f0d944cf5ec4ef Mon Sep 17 00:00:00 2001 From: Andrew Isherwood Date: Thu, 21 Nov 2019 14:37:05 +0000 Subject: [PATCH] Bug 24083: Add circ rules management This patch adds the ability to set the "Unseen renewals allowed" value in the circulation rules --- admin/smart-rules.pl | 2 ++ koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/admin/smart-rules.pl b/admin/smart-rules.pl index 403f425e54..afbed52e36 100755 --- a/admin/smart-rules.pl +++ b/admin/smart-rules.pl @@ -230,6 +230,7 @@ elsif ($op eq 'add') { my $maxissueqty = $input->param('maxissueqty'); my $maxonsiteissueqty = $input->param('maxonsiteissueqty'); my $renewalsallowed = $input->param('renewalsallowed'); + my $unseen_renewals_allowed = $input->param('unseen_renewals_allowed'); my $renewalperiod = $input->param('renewalperiod'); my $norenewalbefore = $input->param('norenewalbefore'); $norenewalbefore = undef if $norenewalbefore =~ /^\s*$/; @@ -276,6 +277,7 @@ elsif ($op eq 'add') { chargeperiod => $chargeperiod, chargeperiod_charge_at => $chargeperiod_charge_at, renewalsallowed => $renewalsallowed, + unseen_renewals_allowed => $unseen_renewals_allowed, renewalperiod => $renewalperiod, norenewalbefore => $norenewalbefore, auto_renew => $auto_renew, diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt index 79b002c00a..ba6f2cbe85 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt @@ -96,6 +96,9 @@ Max. suspension duration (day) Suspension charging interval Renewals allowed (count) + [% IF Koha.Preference('UnseenRenewals') %] + Unseen renewals allowed (count) + [% END %] Renewal period No renewal before Automatic renewal @@ -200,6 +203,9 @@ [% rule.maxsuspensiondays | html %] [% rule.suspension_chargeperiod | html %] [% rule.renewalsallowed | html %] + [% IF Koha.Preference('UnseenRenewals') %] + [% rule.unseen_renewals_allowed | html %] + [% END %] [% rule.renewalperiod | html %] [% rule.norenewalbefore | html %] @@ -312,6 +318,7 @@ + @@ -378,6 +385,7 @@ Max. suspension duration (day) Suspension charging interval Renewals allowed (count) + Unseen renewals allowed (count) Renewal period No renewal before Automatic renewal -- 2.11.0