From 9350ad82885cbb56211195a1acd677173097b66d Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Thu, 12 May 2022 15:53:55 +0000 Subject: [PATCH] Bug 26549: Show value of global system preferences on subscription form This patch modifies the subscription entry form so that the values of two system preferences are displayed as a hint to the user: The "Number of issues to display to staff" field will show the value of the StaffSerialIssueDisplayCount preference, and the "Number of issues to display to the public" field will show OPACSerialIssueDisplayCount. If the user has permission the system preference names will link to the system preferences page. To test, apply the patch and log into the staff interface as a user with permission to edit system preferences. - Go to Serials -> New subscription. - The "Number of issues to display to staff" field should have a hint under it: "Default: XX (StaffSerialIssueDisplayCount system preference)" - The "Number of issues to display to the public" field should have a hint under it: "Default: XX (OPACSerialIssueDisplayCount system preference)" - Log out and log back in as a user who does not have permission to edit system preferences. Return to the form and confirm that the hints do not link to system preferences. --- .../en/modules/serials/subscription-add.tt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-add.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-add.tt index 53760cf4fb..dad25f3781 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-add.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-add.tt @@ -247,10 +247,28 @@ fieldset.rows table { clear: none; margin: 0; }
  • +
    + Default: + [% Koha.Preference('StaffSerialIssueDisplayCount') | html %] + [% IF ( CAN_user_parameters_manage_sysprefs ) %] + (StaffSerialIssueDisplayCount system preference) + [% ELSE %] + (StaffSerialIssueDisplayCount system preference) + [% END %] +
  • +
    + Default: + [% Koha.Preference('OPACSerialIssueDisplayCount') | html %] + [% IF ( CAN_user_parameters_manage_sysprefs ) %] + (OPACSerialIssueDisplayCount system preference) + [% ELSE %] + (OPACSerialIssueDisplayCount system preference) + [% END %] +
  • -- 2.20.1