Bugzilla – Attachment 25567 Details for
Bug 11707
Additional attributes broken for category code with space
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[PASSED QA] Bug 11707 - Additional attributes broken for category code with space
PASSED-QA-Bug-11707---Additional-attributes-broken.patch (text/plain), 2.40 KB, created by
Katrin Fischer
on 2014-02-23 22:34:00 UTC
(
hide
)
Description:
[PASSED QA] Bug 11707 - Additional attributes broken for category code with space
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2014-02-23 22:34:00 UTC
Size:
2.40 KB
patch
obsolete
>From 452925678a6dfbc83505753eeb124edf911f3e10 Mon Sep 17 00:00:00 2001 >From: Fridolin Somers <fridolin.somers@biblibre.com> >Date: Fri, 7 Feb 2014 10:13:39 +0100 >Subject: [PATCH] [PASSED QA] Bug 11707 - Additional attributes broken for > category code with space >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >When editing additional attributes of a patron of a category with a code with space (ie "CAT 3"), the Javascript is broken and Additional attributes are not displayed. > >This patch corrects by adding simple quotes aroud category code in JS code. > >Test plan : >- Create an patron additional attribute >- Create a new patron category with a space in code. ie "CAT 3" >- Create a new patron of this category : /cgi-bin/koha/members/memberentry.pl?op=add&categorycode=CAT 3 >=> Without patch the JS is broken (Syntax error, unrecognized expression: [data-category_code=CAT 3]) and additional attributes are not displayed. >=> With patch the JS is not broken and additional attributes are displayed and can be edited. > >In current Koha version it is not possible to create categroy codes with blanks. >To test, I changed an existing category code directly in the database. >Then I followed the Test plan. >Without patch, attribute types were not displayed. >With patch, they were displayed as expected. > >Signed-off-by: Marc Véron <veron@veron.ch> >Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> >I recommend not using codes with spaces and fix existing ones. >Koha doesn't allow you to add category codes with spaces, so the only way >to do it is via SQL. >This patch fixes a problem and passes all tests. >--- > koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >index 469bbbd..16ada5c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >@@ -99,7 +99,7 @@ > } > var mytables = $(".attributes_table"); > $(mytables).find("li").hide(); >- $(mytables).find(" li[data-category_code="+category_code+"]").show(); >+ $(mytables).find(" li[data-category_code='"+category_code+"']").show(); > $(mytables).find(" li[data-category_code='']").show(); > } > >-- >1.8.3.2
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 11707
:
25113
|
25301
| 25567