Bugzilla – Attachment 97691 Details for
Bug 23777
Text converted to html entity codes in cataloguing edit form
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 23777: Use To.json in request.tt
Bug-23777-Use-Tojson-in-requesttt.patch (text/plain), 2.14 KB, created by
Hayley Pelham
on 2020-01-22 03:40:43 UTC
(
hide
)
Description:
Bug 23777: Use To.json in request.tt
Filename:
MIME Type:
Creator:
Hayley Pelham
Created:
2020-01-22 03:40:43 UTC
Size:
2.14 KB
patch
obsolete
>From 3024a81c77fb4d7e229dc204635ae69ba8afcf42 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 12 Nov 2019 09:30:40 +0100 >Subject: [PATCH] Bug 23777: Use To.json in request.tt > >Test plan: >Use quotes in a library's name, then place an item on hold for a patron >that cannot do it. >If you are allowed to overwrite this restriction you will get a warning: >"This item normally cannot be put on hold except for patrons from >BRANCHNAME" >The library's name should be correcty displayed > >Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >index 8c34184557d..2e9d0b3cdaa 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >@@ -1,4 +1,5 @@ > [% USE raw %] >+[% USE To %] > [% USE Asset %] > [% USE Koha %] > [% USE KohaDates %] >@@ -949,10 +950,10 @@ > var biblionumber = "[% biblionumber | $raw %]"; > var borrowernumber = "[% patron.borrowernumber | $raw %]"; > var MSG_CONFIRM_DELETE_HOLD = _("Are you sure you want to cancel this hold?"); >- var patron_homebranch = "[% Branches.GetName( patron.branchcode ) |replace("'", "\'") |replace('"', '\"') |replace('\n', '\\n') |replace('\r', '\\r') | html %]"; >+ var patron_homebranch = "[% To.json( Branches.GetName( patron.branchcode ) ) | $raw %]"; > var override_items = {[% FOREACH bibitemloo IN bibitemloop %][% FOREACH itemloo IN bibitemloo.itemloop %][% IF ( itemloo.override ) %] > [% itemloo.itemnumber | html %]: { >- homebranch: "[% Branches.GetName( itemloo.homebranch ) |replace("'", "\'") |replace('"', '\"') |replace('\n', '\\n') |replace('\r', '\\r') | html %]", >+ homebranch: "[% To.json( Branches.GetName( itemloo.homebranch ) ) | $raw %]"; > holdallowed: [% itemloo.holdallowed | html %] > }, > [% END %][% END %][% END %] >-- >2.11.0
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 23777
:
95275
|
95279
|
95280
|
95281
|
95282
|
95283
|
95284
|
97685
|
97686
|
97687
|
97688
|
97689
|
97690
|
97691
|
98698
|
98699
|
98700
|
99341
|
99342
|
99343
|
99344
|
99345
|
99346
|
99347
|
99348
|
99570