Bugzilla – Attachment 159048 Details for
Bug 35331
Add an ILL table actions plugin hook
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35331: (QA follow-up):
Bug-35331-QA-follow-up.patch (text/plain), 2.01 KB, created by
David Nind
on 2023-11-16 13:19:05 UTC
(
hide
)
Description:
Bug 35331: (QA follow-up):
Filename:
MIME Type:
Creator:
David Nind
Created:
2023-11-16 13:19:05 UTC
Size:
2.01 KB
patch
obsolete
>From 9565639d86002d1e1e2cee3f737d3a0e9797ad51 Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Date: Wed, 15 Nov 2023 15:26:33 +0000 >Subject: [PATCH] Bug 35331: (QA follow-up): > >Avoid code pattern iterating on plugin responses (see bug 28010) >Use plugin call pattern established in bug 28211. > >Please utilize version 1.0.1 of the plugin to test this follow-up: >https://github.com/PTFS-Europe/koha-plugin-ill-actions/releases/tag/v1.0.1 > >Signed-off-by: David Nind <david@davidnind.com> >--- > Koha/Illrequest.pm | 5 +---- > t/lib/plugins/Koha/Plugin/Test.pm | 17 ++++++++++------- > 2 files changed, 11 insertions(+), 11 deletions(-) > >diff --git a/Koha/Illrequest.pm b/Koha/Illrequest.pm >index 5f6dea5c7b..b6061109db 100644 >--- a/Koha/Illrequest.pm >+++ b/Koha/Illrequest.pm >@@ -2025,10 +2025,7 @@ sub get_staff_table_actions { > } > ]; > >- my @plugin_responses = Koha::Plugins->call('ill_table_actions'); >- for my $plugin_variables (@plugin_responses) { >- push( @{$ill_table_actions}, $plugin_variables ); >- } >+ Koha::Plugins->call( 'ill_table_actions', \$ill_table_actions ); > > return $ill_table_actions; > } >diff --git a/t/lib/plugins/Koha/Plugin/Test.pm b/t/lib/plugins/Koha/Plugin/Test.pm >index 9ce039528d..95f588e877 100644 >--- a/t/lib/plugins/Koha/Plugin/Test.pm >+++ b/t/lib/plugins/Koha/Plugin/Test.pm >@@ -370,14 +370,17 @@ sub after_recall_action { > } > > sub ill_table_actions { >- my ( $self ) = @_; >+ my ( $self, $table_actions ) = @_; > >- return { >- button_link_text => 'Test text', >- append_column_data_to_link => 1, >- button_class => 'test class', >- button_link => 'test link' >- }; >+ push( >+ @{$$table_actions}, >+ { >+ button_link_text => 'Test text', >+ append_column_data_to_link => 1, >+ button_class => 'test class', >+ button_link => 'test link' >+ } >+ ); > } > > sub _private_sub { >-- >2.30.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 35331
:
158916
|
158917
|
158993
|
159037
|
159046
|
159047
|
159048
|
159049
|
159105
|
159106
|
159107
|
159108
|
159109
|
160634
|
160635
|
160636
|
160637
|
162812
|
162813
|
162814
|
162815
|
162816