Bugzilla – Attachment 78865 Details for
Bug 18655
Unimarc field 210c fails on importing fields with a simple quote
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18655: Correct the choose link in unimarc_field_210c value builder
Bug-18655-Correct-the-choose-link-in-unimarcfield2.patch (text/plain), 2.74 KB, created by
Biblibre Sandboxes
on 2018-09-15 17:29:45 UTC
(
hide
)
Description:
Bug 18655: Correct the choose link in unimarc_field_210c value builder
Filename:
MIME Type:
Creator:
Biblibre Sandboxes
Created:
2018-09-15 17:29:45 UTC
Size:
2.74 KB
patch
obsolete
>From 67eb5b5304132069d3a8047ddf7887e6ef679144 Mon Sep 17 00:00:00 2001 >From: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com> >Date: Tue, 23 May 2017 08:54:00 +0000 >Subject: [PATCH] Bug 18655: Correct the choose link in unimarc_field_210c > value builder > >- Link 'choose' is now a button. >- It doesn't call directly javascript anymore (use of listener). >- field to load stored in html on the page (less escaping needed). > >Test plan : >1) Use UNIMARC catalog >2) Define unimarc_field_210c value builder on 210$c >3) Define an autority type EDITORS with heading on 200$b >4) Create an autority of this type with a single quote in heading, ie : l'avenir >5) Index this new autority >6) Edit a biblio record and launch 210$c value builder >7) Search for new autority >8) Click on 'Choose' >=> Heading should be pasted in 210$c > >Signed-off-by: David Nind <david@davidnind.com> >--- > .../modules/cataloguing/value_builder/unimarc_field_210c.tt | 13 ++++++++++--- > 1 file changed, 10 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tt >index c4970e5..0ce0861 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_210c.tt >@@ -66,9 +66,10 @@ > <td>[% PROCESS authresult summary=resul.summary %]</td> > <td>[% resul.used | html %] times</td> > <td> >- [% IF ( resul.to_report ) %] >- <a href="javascript:report('[% resul.to_report |replace("'", "\'") |replace('"', '\"') |replace('\n', '\\n') |replace('\r', '\\r') | html %]')"><img alt="choose" src="[% interface | html %]/[% theme | html %]/images/arrow.gif" width="32" /></a> >- [% END %] >+ [% IF ( resul.to_report ) %] >+ <button class="choosebt">Choose</button> >+ <p class="toreport" style="display:none">[% resul.to_report |replace('\n', '\\n') |replace('\r', '\\r') |html %]</p> >+ [% END %] > </td> > </tr> > [% END %] >@@ -83,6 +84,12 @@ > > [% MACRO jsinclude BLOCK %] > <script type="text/javascript"> >+ $(document).ready(function(){ >+ $(".choosebt").on("click",function(){ >+ var toreport = $(this).siblings(".toreport").text(); >+ report(toreport); >+ }); >+ }); > function report(summary){ > var doc = opener.document; > var field = doc.getElementById('[% index | html %]'); >-- >2.7.4
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 18655
:
63644
|
63652
|
63653
|
76168
|
78710
|
78865
|
80315