Bug 31553

Summary: News item contents field does not always expand when you click on a non-default language
Product: Koha Reporter: Alex Buckley <alexbuckley>
Component: ToolsAssignee: Alex Buckley <alexbuckley>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: david, lucas
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: Sponsored Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
22.11.00
Circulation function:
Attachments: Arrow pointing at the un-expanded content field when using the English New Zealand news item tab
Bug 31553: Ensure news item content field is always editable
Bug 31553: Ensure news item content field is always editable
Bug 31553: Ensure news item content field is always editable

Description Alex Buckley 2022-09-13 02:11:23 UTC
Created attachment 140508 [details]
Arrow pointing at the un-expanded content field when using the English New Zealand news item tab

Unfortunately, this is tricky to test as it only happens intermittently.

How I am able to occasionally replicate this:

1. Have a Koha OPAC with multiple languages enabled in the 'OPACLanguages' syspref

1. Add a new news item, or edit an existing news item ( Tools > News ).

2. Click on a language tab (i.e. a tab that is not the 'Default'tab ) and observe the content field (area below the editor buttons) has not expanded to enable you to input your news item content.

Attached screenshot shows the content field has not expanded for me in the 'English New Zealand (en-NZ)' tab.
Comment 1 Alex Buckley 2022-09-13 02:39:01 UTC
Created attachment 140509 [details] [review]
Bug 31553: Ensure news item content field is always editable

Set a padding at the bottom of the news item editor body.

This is a tricky bug to replicate.

Test plan:
1. Set 'AdditionalContentsEditor' syspref = 'a WYSIWYG editor
(TinyMCE)'.

2. Select multiple languages in the 'OPACLanguages' system preference.

3. Go to: Tools > News.

4. Create a new news item. Switch between the different language tabs.

5. Confirm you can always input into the content field in all languages.

6. Edit an exiting news item. Switch between different language tabs.

7. Confirm you can always input into the content field in all languages.

Sponsored-by: Toi Ohomai Institute of Technology, New Zealand
Comment 2 David Nind 2022-09-13 20:33:55 UTC
Created attachment 140608 [details] [review]
Bug 31553: Ensure news item content field is always editable

Set a padding at the bottom of the news item editor body.

This is a tricky bug to replicate.

Test plan:
1. Set 'AdditionalContentsEditor' syspref = 'a WYSIWYG editor
(TinyMCE)'.

2. Select multiple languages in the 'OPACLanguages' system preference.

3. Go to: Tools > News.

4. Create a new news item. Switch between the different language tabs.

5. Confirm you can always input into the content field in all languages.

6. Edit an exiting news item. Switch between different language tabs.

7. Confirm you can always input into the content field in all languages.

Sponsored-by: Toi Ohomai Institute of Technology, New Zealand

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 David Nind 2022-09-13 20:38:08 UTC
I was able to replicate by installing two additional languages:

- sudo koha-translate --install en-NZ --dev kohadev

- sudo koha-translate --install fr-FR --dev kohadev

This gives the default tab and three language tabs (Default, English New Zealand (en-NZ), English (en), Français (fr-FR)).

For me, you couldn't enter anything in the English(en) tab before the patch was applied.

Tested using koha-testing-docker.
Comment 4 Katrin Fischer 2022-10-01 20:41:13 UTC
Created attachment 141192 [details] [review]
Bug 31553: Ensure news item content field is always editable

Set a padding at the bottom of the news item editor body.

This is a tricky bug to replicate.

Test plan:
1. Set 'AdditionalContentsEditor' syspref = 'a WYSIWYG editor
(TinyMCE)'.

2. Select multiple languages in the 'OPACLanguages' system preference.

3. Go to: Tools > News.

4. Create a new news item. Switch between the different language tabs.

5. Confirm you can always input into the content field in all languages.

6. Edit an exiting news item. Switch between different language tabs.

7. Confirm you can always input into the content field in all languages.

Sponsored-by: Toi Ohomai Institute of Technology, New Zealand

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 5 Tomás Cohen Arazi (tcohen) 2022-10-24 20:37:53 UTC
Pushed to master for 22.11.

Nice work everyone, thanks!