From 47f7cc89008313444c40e2051355e8b4684d342d Mon Sep 17 00:00:00 2001 From: Pasi Kallinen Date: Fri, 9 May 2014 13:40:14 +0300 Subject: [PATCH] Bug 11392: Allow translating the viewlog module and action names When viewing the logs, the user can see module and action, such as "SYSTEMPREFERENCE", "MEMBERS" or "CREATE", "MODIFY", etc. These texts are not translatable. This patch allows translating those. It also adds the missing "CREATE" action to the pulldown. To test: 1) Go browse the system logs. Note the contents of the "Action" and "Module" -pulldowns, and the contents of those columns in the log table. 2) Apply patch 3) Go browse the system logs again. The pull-downs should work, and show the same values as before (plus "Create" for Action), and the Action and Module -columns in the log table should not be in ALL CAPS. 4) cd misc/translator 5) perl translate update xx-YY 6) Check that the po/xx-YY-i-staff-t-prog-v-3006000.po contains the values for the pull-downs in it. (Look for eg. "System prefs") Signed-off-by: Chris Cormack Signed-off-by: Jonathan Druart Signed-off-by: Galen Charlton --- .../prog/en/modules/tools/viewlog.tt | 51 +++++++++++++------ 1 file changed, 35 insertions(+), 16 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt index 56f1f672e6..19d032153f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt @@ -14,6 +14,33 @@ [% INCLUDE 'header.inc' %] [% INCLUDE 'cat-search.inc' %] +[% BLOCK translate_log_module %] +[% SWITCH module %] +[% CASE 'CATALOGUING' %]Catalog +[% CASE 'AUTHORITIES' %]Authorities +[% CASE 'MEMBERS' %]Patrons +[% CASE 'ACQUISITIONS' %]Acquisitions +[% CASE 'SERIAL' %]Serials +[% CASE 'CIRCULATION' %]Circulation +[% CASE 'LETTER' %]Letter +[% CASE 'FINES' %]Fines +[% CASE 'SYSTEMPREFERENCE' %]System prefs +[% CASE %][% module %] +[% END %] +[% END %] + +[% BLOCK translate_log_action %] +[% SWITCH action %] +[% CASE 'ADD' %]Add +[% CASE 'DELETE' %]Delete +[% CASE 'MODIFY' %]Modify +[% CASE 'ISSUE' %]Checkout +[% CASE 'RETURN' %]Return +[% CASE 'CREATE' %]Create +[% CASE %][% action %] +[% END %] +[% END %] +