Bugzilla – Attachment 76873 Details for
Bug 21053
Editing 008 field with a hash overwrites data
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21053: Encode URI characters in plugin 008
Bug-21053-Encode-URI-characters-in-plugin-008.patch (text/plain), 1.80 KB, created by
Jonathan Druart
on 2018-07-11 21:59:10 UTC
(
hide
)
Description:
Bug 21053: Encode URI characters in plugin 008
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2018-07-11 21:59:10 UTC
Size:
1.80 KB
patch
obsolete
>From 51a3bb957b035c69c2c9a101fb691a041952ed9f Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 11 Jul 2018 18:55:06 -0300 >Subject: [PATCH] Bug 21053: Encode URI characters in plugin 008 > >A # (or &) at any position in 008 field of a bib record causes >all subsequent data in field to be overwritten with default values when >record is saved. > >These characters need to be correctly encoded before being passed as >parameters of the url > >To reproduce: >1. Find and edit a bib record which has an 008 which differs from the >default values for the MARC framework >2. Choose 008 helper >3. Add # in any position before the end of the field noting the current >values of the data >4. Save record >5. Edit record and select 008 helper >6. Review characters after # >--- > cataloguing/value_builder/marc21_field_008.pl | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/cataloguing/value_builder/marc21_field_008.pl b/cataloguing/value_builder/marc21_field_008.pl >index 5da53dcdad..4acbb6946f 100755 >--- a/cataloguing/value_builder/marc21_field_008.pl >+++ b/cataloguing/value_builder/marc21_field_008.pl >@@ -63,7 +63,7 @@ function Click$function_name(event) { > //Only add the parameter to the URL if there is a value to add > leader_parameter = \"&leader=\"+leader_value; > } >- newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue+leader_parameter,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes'); >+ newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008.pl&index=\"+ event.data.id +\"&result=\"+encodeURIComponent(defaultvalue)+leader_parameter,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes'); > > } > //]]> >-- >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 21053
:
76786
|
76873
|
76961
|
77064