From c4dd097d20040cc2786ca062d306b8eee1f005e2 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 2 Feb 2017 11:37:54 +0100 Subject: [PATCH] Bug 14224: Replace AllowIssueNotes with AllowCheckoutNotes MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jonathan Druart Signed-off-by: Josef Moravec Signed-off-by: Marc Véron Signed-off-by: Kyle M Hall --- .../mysql/atomicupdate/bug_14224-issue_notes_syspref.sql | 2 +- installer/data/mysql/sysprefs.sql | 2 +- .../prog/en/modules/admin/preferences/circulation.pref | 2 +- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-issue-note.tt | 2 +- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt | 6 +++--- opac/opac-issue-note.pl | 2 +- opac/svc/patron_notes | 2 +- 7 files changed, 9 insertions(+), 9 deletions(-) diff --git a/installer/data/mysql/atomicupdate/bug_14224-issue_notes_syspref.sql b/installer/data/mysql/atomicupdate/bug_14224-issue_notes_syspref.sql index e619b21389..63d359f1cd 100644 --- a/installer/data/mysql/atomicupdate/bug_14224-issue_notes_syspref.sql +++ b/installer/data/mysql/atomicupdate/bug_14224-issue_notes_syspref.sql @@ -1 +1 @@ -INSERT IGNORE INTO systempreferences (`variable`, `value`, `options`, `explanation`,`type`) VALUES ('AllowIssueNotes', '0', NULL, 'Allow patrons to submit notes about checked out items.','YesNo'); +INSERT IGNORE INTO systempreferences (`variable`, `value`, `options`, `explanation`,`type`) VALUES ('AllowCheckoutNotes', '0', NULL, 'Allow patrons to submit notes about checked out items.','YesNo'); diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql index 5c79160797..3e0f93b13d 100644 --- a/installer/data/mysql/sysprefs.sql +++ b/installer/data/mysql/sysprefs.sql @@ -22,7 +22,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('AllowHoldPolicyOverride','0',NULL,'Allow staff to override hold policies when placing holds','YesNo'), ('AllowHoldsOnDamagedItems','1','','Allow hold requests to be placed on damaged items','YesNo'), ('AllowHoldsOnPatronsPossessions','1',NULL,'Allow holds on records that patron have items of it','YesNo'), -('AllowIssueNotes', '0', NULL, 'Allow patrons to submit notes about checked out items.','YesNo'), +('AllowCheckoutNotes', '0', NULL, 'Allow patrons to submit notes about checked out items.','YesNo'), ('AllowItemsOnHoldCheckout','0','','Do not generate RESERVE_WAITING and RESERVED warning when checking out items reserved to someone else. This allows self checkouts for those items.','YesNo'), ('AllowItemsOnHoldCheckoutSCO','0','','Do not generate RESERVE_WAITING and RESERVED warning in the SCO module when checking out items reserved to someone else. This allows self checkouts for those items.','YesNo'), ('AllowMultipleCovers','0','1','Allow multiple cover images to be attached to each bibliographic record.','YesNo'), diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref index bd43e41320..a583f2b70f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref @@ -145,7 +145,7 @@ Circulation: no: "Do not show" - all items in the "Checked-in items" list, even items that were not checked out. - - - pref: AllowIssueNotes + - pref: AllowCheckoutNotes choices: yes: Allow no: "Don't allow" diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-issue-note.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-issue-note.tt index 6876477ca6..03a6a7b6ea 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-issue-note.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-issue-note.tt @@ -26,7 +26,7 @@

Editing issue note for [% title %] [% author %]

- [% IF not(Koha.Preference("AllowIssueNotes")) %] + [% IF not(Koha.Preference("AllowCheckoutNotes")) %] Issue notes have not been enabled. Please contact the library. [% ELSE %]
diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt index f2607965f6..cded80d2e5 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt @@ -185,7 +185,7 @@ Using this account is not recommended because some parts of Koha will not functi [% IF ( OPACMySummaryHTML ) %] Links [% END %] - [% IF ( Koha.Preference('AllowIssueNotes') ) %] + [% IF ( Koha.Preference('AllowCheckoutNotes') ) %] Note [% END %] @@ -309,7 +309,7 @@ Using this account is not recommended because some parts of Koha will not functi [% IF ( OPACMySummaryHTML ) %] [% ISSUE.MySummaryHTML %] [% END %] - [% IF ( Koha.Preference('AllowIssueNotes') ) %] + [% IF ( Koha.Preference('AllowCheckoutNotes') ) %] @@ -934,7 +934,7 @@ Using this account is not recommended because some parts of Koha will not functi [% END %] [% END %] - [% IF ( Koha.Preference('AllowIssueNotes') ) %] + [% IF ( Koha.Preference('AllowCheckoutNotes') ) %] /* If JS enabled, show button, otherwise show link to redirect to a page where note can be submitted */ $("a[name='nonjs_submitnote']").hide(); diff --git a/opac/opac-issue-note.pl b/opac/opac-issue-note.pl index de2d82bb82..becd7083f7 100755 --- a/opac/opac-issue-note.pl +++ b/opac/opac-issue-note.pl @@ -63,7 +63,7 @@ $template->param( ); my $action = $query->param('action') || ""; -if ( $action eq 'issuenote' && C4::Context->preference('AllowIssueNotes') ) { +if ( $action eq 'issuenote' && C4::Context->preference('AllowCheckoutNotes') ) { my $note = $query->param('note'); my $scrubber = C4::Scrubber->new(); my $clean_note = $scrubber->scrub($note); diff --git a/opac/svc/patron_notes b/opac/svc/patron_notes index 2e25b36799..2e4dfc9842 100755 --- a/opac/svc/patron_notes +++ b/opac/svc/patron_notes @@ -50,7 +50,7 @@ if ($is_ajax) { my $action = $query->param('action'); # Issue Note - if ( $action eq 'issuenote' && C4::Context->preference('AllowIssueNotes') ) { + if ( $action eq 'issuenote' && C4::Context->preference('AllowCheckoutNotes') ) { my $scrubber = C4::Scrubber->new(); my $note = $query->param('note'); my $issue_id = $query->param('issue_id'); -- 2.20.1