From 2453a5f30d7610b0a4d3b6de7f7453e9e373d53e Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Tue, 23 Jun 2020 11:06:55 -0300 Subject: [PATCH] Bug 25845: Add 'api' to the log viewer interface options MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch simply adds the API option to the log viewer. To test: 1. Have BorrowersLog set 2. Update some patron using the API. For example curl --location --request PUT 'http://koha:koha@kohadev-intra.mydnsname.org:8081/api/v1/patrons/1' \ --header 'Content-Type: application/json' \ --data-raw '{ "firstname": "Tomasito", "surname": "None", "address": "Address", "category_id": "ST", "city": "Córdoba", "library_id": "MPL" }' 3. Open the log viewer => FAIL: There's no way to filter on interface, choosing API 4. Apply this patch 5. Reload the log viewer => SUCCESS: There are options to filter by 'API' interface => SUCCESS: Filtering by 'API' works 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi --- koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) 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 259d36d32bd..60bc277cb10 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt @@ -85,6 +85,7 @@ fieldset.rows label.viewlog { [% CASE 'OPAC' %]OPAC [% CASE 'SIP' %]SIP [% CASE 'COMMANDLINE' %]Command-line +[% CASE 'API' %]API [% CASE %][% log_interface | html %] [% END %] [% END %] @@ -176,7 +177,7 @@ fieldset.rows label.viewlog { [% END %] - [% FOREACH interf IN [ 'INTRANET' 'OPAC' 'SIP' 'COMMANDLINE' ] %] + [% FOREACH interf IN [ 'INTRANET' 'OPAC' 'SIP' 'COMMANDLINE' 'API' ] %] [% IF interfaces.grep(interf).size %] [% ELSE %] -- 2.27.0