Bug 40453

Summary: Allow newly-added item type translations to be edited
Product: Koha Reporter: Owen Leonard <oleonard>
Component: System AdministrationAssignee: Owen Leonard <oleonard>
Status: Needs Signoff --- QA Contact: Jonathan Druart <jonathan.druart>
Severity: normal    
Priority: P5 - low CC: caroline.cyr-la-rose, gmcharlt, jonathan.druart, testopia
Version: Main   
Hardware: All   
OS: All   
GIT URL: Change sponsored?: ---
Patch complexity: Small patch Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on: 40418    
Bug Blocks:    
Attachments: Bug 40453: Allow newly-added item type translations to be edited

Description Owen Leonard 2025-07-18 16:42:10 UTC
When a new item type translation is added, a new table row is added to the table. The markup of the added row doesn't match the existing rows, and the JS event listeners aren't correctly configured to target the new row.
Comment 1 Owen Leonard 2025-07-18 17:39:30 UTC
Created attachment 184408 [details] [review]
Bug 40453: Allow newly-added item type translations to be edited

This patch updates the item type translation page so that newly-added
rows are editable.

To test you must more than one installed translation.

- Apply the patch and go to Administration -> Item types.
- Edit an item type and click "Translate into other languages."
- If you already have translations for your installed languages, delete
  them.
- Add a new translation.
- In the newly added table row, click the value in the "Language"
  column. A dropdown should appear and changing the language should
  work.
  - Cliking away from the table cell should replace the dropdown with
    the language code you selected.
- Click the value in the "Translation" column. The table cell should
  become editable. Edit the text and tab out of the field. Your edit
  should be saved.
- Reload the page to confirm that everything looks correct.

Sponsored-by: Athens County Public Libraries