From 1875d5e12ef432b6cfa26369bc363b5fad34efa3 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 31 Jan 2024 11:13:48 +0100 Subject: [PATCH] Bug 34478: Rename action with op - offline_circ Signed-off-by: Jonathan Druart --- .../intranet-tmpl/prog/en/modules/offline_circ/list.tt | 4 ++-- offline_circ/process.pl | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/offline_circ/list.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/offline_circ/list.tt index 022796ea04..f1df1f6170 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/offline_circ/list.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/offline_circ/list.tt @@ -132,12 +132,12 @@ $("#operations input:checkbox").prop("checked", true ); }); $('#process,#delete').click(function() { - var action = $(this).attr("id"); + var op = $(this).attr("id"); $(":checkbox[name=operationid]:checked").each(function() { var cb = $(this); $.ajax({ url: "process.pl", - data: { 'action': action, 'operationid': this.value }, + data: { 'op': 'cud-' + op, 'operationid': this.value }, async: false, dataType: "text", success: function(data) { diff --git a/offline_circ/process.pl b/offline_circ/process.pl index 6203857416..9e6121aea4 100755 --- a/offline_circ/process.pl +++ b/offline_circ/process.pl @@ -34,13 +34,13 @@ my ($template, $loggedinuser, $cookie) = get_template_and_user({ }); my $operationid = $query->param('operationid'); -my $action = $query->param('action'); +my $op = $query->param('op') || q{}; my $result; -if ( $action eq 'process' ) { +if ( $op eq 'cud-process' ) { my $operation = GetOfflineOperation( $operationid ); $result = ProcessOfflineOperation( $operation ); -} elsif ( $action eq 'cud-delete' ) { +} elsif ( $op eq 'cud-delete' ) { $result = DeleteOfflineOperation( $operationid ); } -- 2.39.5