Bug 13080

Summary: Addition of noEnterSubmit class should not apply to textarea, only to input
Product: Koha Reporter: Claudio Costales <costalc>
Component: TemplatesAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: major    
Priority: P2 CC: fridolin.somers, katrin.fischer, m.de.rooy, tomascohen
Version: Main   
Hardware: All   
OS: All   
See Also: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11563
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: noEnterSubmit
Bug 13080 - Addition of noEnterSubmit class should not apply to textarea, only to input
[PASSED QA] Bug 13080 - Addition of noEnterSubmit class should not apply to textarea, only to input

Description Claudio Costales 2014-10-13 23:38:22 UTC
Created attachment 32293 [details]
noEnterSubmit

Tested in koha-common 3.16.4. 

When trying to input text in a textarea html tag while cataloging the "intro" key does not funcion.

Needs to fix file intranet-tmpl/prog/*LANG*/js/cataloging.js 

In LINE 486 erase 'noEnterSubmit' parameter in function addClass.

So:
-    $(".input_marceditor, .indicator").addClass('noEnterSubmit');
+    $(".input_marceditor, .indicator").addClass('');
Comment 1 Owen Leonard 2014-10-15 16:01:19 UTC Comment hidden (obsolete)
Comment 2 Claudio Costales 2014-10-16 00:04:08 UTC
(In reply to Owen Leonard from comment #1)
> Created attachment 32363 [details] [review] [review]
> Bug 13080 - Addition of noEnterSubmit class should not apply to textarea,
> only to input
> 
> The application of the "noEnterSubmit" class to textareas in the
> cataloging editor prevents the user from being able to use the Enter key
> to create line breaks. This is not intentional and should be corrected.
> 
> This patch adds more specific scoping to the relevant JavaScript.
> 
> To test, apply the patch and clear your browser cache if necessary. Open
> up the MARC editor and locate a tag which uses a textarea for entry. Try
> typing lines of text separated by line breaks. The enter key should work
> correctly.


Tested and the enter key works correctly!! Great job!
Comment 3 Claudio Costales 2014-10-16 01:29:23 UTC
Tested and the enter key works correctly!! Great job!
Comment 4 Katrin Fischer 2014-10-16 14:35:38 UTC
Hi Bondiurbano,
thx for testing! - I have added a sing-off line for you on the patch. If you are using the sandboxes for testing they can do that for you too.
Comment 5 Katrin Fischer 2014-10-16 14:37:42 UTC
Created attachment 32421 [details] [review]
[PASSED QA] Bug 13080 - Addition of noEnterSubmit class should not apply to textarea, only to input

The application of the "noEnterSubmit" class to textareas in the
cataloging editor prevents the user from being able to use the Enter key
to create line breaks. This is not intentional and should be corrected.

This patch adds more specific scoping to the relevant JavaScript.

To test, apply the patch and clear your browser cache if necessary. Open
up the MARC editor and locate a tag which uses a textarea for entry. Try
typing lines of text separated by line breaks. The enter key should work
correctly.

Signed-off-by: bondiurbano costalc@gmail.com
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes tests and fixes the problem.
Comment 6 Tomás Cohen Arazi 2014-10-27 17:20:33 UTC
Patch pushed to master.

Thanks Owen!
Comment 7 Fridolin Somers 2015-04-09 09:07:08 UTC
Can this be backported to 3.16.x ?