Bugzilla – Attachment 28126 Details for
Bug 11392
logaction() modulename and action are untranslatable
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Allow translating the viewlog module and action names
0001-Bug-11392-Allow-translating-the-viewlog-module-and-a.patch (text/plain), 5.22 KB, created by
paxed
on 2014-05-09 11:22:38 UTC
(
hide
)
Description:
Allow translating the viewlog module and action names
Filename:
MIME Type:
Creator:
paxed
Created:
2014-05-09 11:22:38 UTC
Size:
5.22 KB
patch
obsolete
>From 74d285e60db9a2d70d73589359327208451d23ff Mon Sep 17 00:00:00 2001 >From: Pasi Kallinen <pasi.kallinen@pttk.fi> >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. >--- > .../intranet-tmpl/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 56f1f67..19d0321 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 %] >+ > <div id="breadcrumbs"> > <a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> › > [% IF ( do_it ) %] >@@ -44,26 +71,18 @@ > <label for="modules">Module:</label> > <select name="modules" id="modules" multiple="multiple"> > <option value="" selected="selected">All</option> >- <option value ="CATALOGUING">Catalog</option> >- <option value ="AUTHORITIES">Authorities</option> >- <option value ="MEMBERS">Patrons</option> >- <option value ="ACQUISITION">Acquisitions</option> >- <option value ="SERIAL">Serials</option> >- <option value="CIRCULATION">Circulation</option> >- <option value="LETTER">Letter</option> >- <option value="FINES">Fines</option> >- <option value="SYSTEMPREFERENCE">System prefs</option> >+ [% FOREACH modx IN [ CATALOGUING AUTHORITIES MEMBERS ACQUISITIONS SERIAL CIRCULATION LETTER FINES SYSTEMPREFERENCE ] %] >+ <option value="[% modx %]">[% PROCESS translate_log_module module=modx %]</option> >+ [% END %] > </select> > </li> > <li> > <label for="action">Action:</label> > <select name="action" id="action"> > <option value ="">All</option> >- <option value ="ADD">Add</option> >- <option value ="DELETE">Delete</option> >- <option value ="MODIFY">Modify</option> >- <option value="ISSUE">Checkout</option> >- <option value="RETURN">Return</option> >+ [% FOREACH actx IN [ ADD DELETE MODIFY ISSUE RETURN CREATE ] %] >+ <option value="[% actx %]">[% PROCESS translate_log_action action=actx %]</option> >+ [% END %] > </select> > </li> > <li> >@@ -129,8 +148,8 @@ > <td> > <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% loopro.user %]" title="display detail for this librarian."> [% IF ( loopro.userfirstname ) || ( loopro.usersurname ) %][% loopro.userfirstname %] [% loopro.usersurname %] ([% loopro.user %]) [% ELSE %][% loopro.user %][% END %]</a> > </td> >- <td>[% loopro.module %]</td> >- <td>[% loopro.action %]</td> >+ <td>[% PROCESS translate_log_module module=loopro.module %]</td> >+ <td>[% PROCESS translate_log_action action=loopro.action %]</td> > <td> > [% IF ( loopro.module == 'MEMBERS' ) || ( loopro.module == 'CIRCULATION' ) || ( loopro.module == 'FINES' ) %] > <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% loopro.object %]" title="Display member details."> [% IF ( loopro.object ) %][% IF ( loopro.borrowerfirstname ) || ( loopro.borrowersurname ) %][% loopro.borrowerfirstname %] [% loopro.borrowersurname %] ([% loopro.object %]) [% ELSE %]Member [% loopro.object %][% END %][% END %] </a> >-- >1.8.3.2 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 11392
:
28126
|
28191
|
28276