Bug 18791: (follow up) Fix translation of copy messages
commit6c48a1e2c2b5ea246a4ea0f3b0e2d8dadc3279ed
authorOwen Leonard <oleonard@myacpl.org>
Tue, 27 Mar 2018 15:09:08 +0000 (27 15:09 +0000)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Fri, 13 Apr 2018 16:55:22 +0000 (13 13:55 -0300)
treed8d111d46e823e8e90777bbe4924fda24cfe00ae
parent0c35b35ad0311ec74d27518d794d63a2e6f3e8b6
Bug 18791: (follow up) Fix translation of copy messages

This patch updates DataTables configuration so that more strings are
translatable:

https://datatables.net/extensions/buttons/examples/html5/copyi18n.html

To test, apply the patch and clear your browser cache.

- Open the account tab for a patron who has only one fine.
- Confirm that the new DataTables buttons appear.
- Click the 'Copy' button and confirm that a "Copied 1 row to clipboard"
  message appears.
- Test again with a patron who has multiple fines, confirm that the
  message reads "Copied X rows to clipboard."

To test the translation:

- Confirm that "Copied 1 row to clipboard" is missing from the language
  file you're testing with (misc/translator/po/xx-YY-staff-prog.po).
- Run 'translate update xx-YY'
- Check that the clipboard strings are now in the po file.
- Add translations for those strings.
- Run 'translate update xx-YY' and 'translate install xx-YY'
- Switch to the translated language and clear your browser cache.
- Test the 'Copy' button again. Your translated text should appear.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/intranet-tmpl/prog/en/includes/datatables.inc
koha-tmpl/intranet-tmpl/prog/js/datatables.js