Bug 22904 - Untranslatable strings in members-menu.js
Summary: Untranslatable strings in members-menu.js
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: master
Hardware: All All
: P5 - low major (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on: 19641
Blocks: 22490
  Show dependency treegraph
 
Reported: 2019-05-14 13:13 UTC by Owen Leonard
Modified: 2019-10-14 20:02 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
19.05.00, 18.11.06


Attachments
Bug 22904: Untranslatable strings in members-menu.js (6.54 KB, patch)
2019-05-14 14:39 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 22904: Untranslatable strings in members-menu.js (6.61 KB, patch)
2019-05-27 12:27 UTC, Michal Denar
Details | Diff | Splinter Review
Bug 22904: Untranslatable strings in members-menu.js (6.67 KB, patch)
2019-05-27 20:10 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2019-05-14 13:13:09 UTC
There are a few strings in members-menu.js which won't get picked up by the translation tool:

Line 23+ _("Dates of birth ...

Line 108: _("Are you sure you want to update this child to an Adult category?  This cannot be undone.")

Line 123: _("Are you sure you want to renew this patron's registration?")
Comment 1 Owen Leonard 2019-05-14 14:39:04 UTC Comment hidden (obsolete)
Comment 2 Michal Denar 2019-05-27 12:27:28 UTC Comment hidden (obsolete)
Comment 3 Katrin Fischer 2019-05-27 20:10:44 UTC
Created attachment 90120 [details] [review]
Bug 22904: Untranslatable strings in members-menu.js

This patch moves several English strings out of members-menu.js and into
str/members-menu.inc where they can be picked up by the translation
process. The following strings are affected:

"Are you sure you want to renew this patron's registration?"
"Are you sure you want to update this child to an Adult category?  This
cannot be undone."
"Dates of birth should be entered in the format 'MM/DD/YYYY'"
"Dates of birth should be entered in the format 'YYYY-MM-DD'"
"Dates of birth should be entered in the format 'DD/MM/YYYY'"
"Dates of birth should be entered in the format 'DD.MM.YYYY'"

This patch also makes a correction to members-toolbar.inc in order to
enable the presence of the "Update child to Adult" menu item.

To test:

 - Install and update a language.
 - Check the po-file for that language. You should find no msgid for
   the strings listed above.
 - Apply the patch.
 - Update the language you installed.
 - You should find entries for all the strings above.
 - Translate those messages and update the translated templates.
 - Reinstall the translation.

In the staff client:

 - Select your updated translation.
 - Open an expired patron's account and choose "Renew patron" from the
   "More" button in the toolbar. You should be prompted for confirmation
   using the translation you provided.
 - To test the "Update child" confirmation you should have only one
   patron category in the "Adult" category.
   - Open a patron record with a child category and choose "Update
     child" from the "More" menu in the toolbar. You should be prompted
     for confirmation using the translation you provided.
 - To test the date format messages: From the patrons home page, expand
   the advanced search options in the header search form. Select "Date
   of birth" under "Search fields." A correctly-translated tooltip
   should appear above the search field.

Signed-off-by: Michal Denar <black23@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 4 Nick Clemens 2019-05-30 10:35:22 UTC
Awesome work all!

Pushed to master for 19.05
Comment 5 Martin Renvoize 2019-05-30 20:21:01 UTC
Pushed to 18.11.x for 18.11.06