Bugzilla – Attachment 128159 Details for
Bug 29385
Add missing cash register support to SIP2
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 29385: [ALTERNATIVE] Catch register_id for payments against fees
Bug-29385-ALTERNATIVE-Catch-registerid-for-payment.patch (text/plain), 2.18 KB, created by
Jonathan Druart
on 2021-12-02 12:53:15 UTC
(
hide
)
Description:
Bug 29385: [ALTERNATIVE] Catch register_id for payments against fees
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2021-12-02 12:53:15 UTC
Size:
2.18 KB
patch
obsolete
>From 81afea46a9f83e530995f21b565f45fcc89af226 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 2 Dec 2021 13:52:45 +0100 >Subject: [PATCH] Bug 29385: [ALTERNATIVE] Catch register_id for payments > against fees > >--- > C4/SIP/ILS/Transaction/FeePayment.pm | 41 +++++++++------------------- > 1 file changed, 13 insertions(+), 28 deletions(-) > >diff --git a/C4/SIP/ILS/Transaction/FeePayment.pm b/C4/SIP/ILS/Transaction/FeePayment.pm >index 7748b1a1d8f..287d171ff1b 100644 >--- a/C4/SIP/ILS/Transaction/FeePayment.pm >+++ b/C4/SIP/ILS/Transaction/FeePayment.pm >@@ -57,22 +57,17 @@ sub pay { > return { ok => 0 } if $account->balance < $amt; > } > >+ my $pay_options = { >+ amount => $amt, >+ type => $type, >+ payment_type => 'SIP' . $sip_type, >+ interface => C4::Context->interface >+ }; >+ > if ($fee_id) { > my $fee = Koha::Account::Lines->find($fee_id); > if ( $fee ) { >- my $pay_response = $account->pay( >- { >- amount => $amt, >- type => $type, >- payment_type => 'SIP' . $sip_type, >- lines => [$fee], >- interface => C4::Context->interface >- } >- ); >- return { >- ok => 1, >- pay_response => $pay_response >- }; >+ $pay_options->{lines} = [$fee]; > } > else { > return { >@@ -80,21 +75,11 @@ sub pay { > }; > } > } >- else { >- my $pay_response = $account->pay( >- { >- amount => $amt, >- type => $type, >- payment_type => 'SIP' . $sip_type, >- interface => C4::Context->interface, >- cash_register => $register_id >- } >- ); >- return { >- ok => 1, >- pay_response => $pay_response >- }; >- } >+ my $pay_response = $account->pay($pay_options); >+ return { >+ ok => 1, >+ pay_response => $pay_response >+ }; > } > > #sub DESTROY { >-- >2.25.1
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 29385
:
127173
|
127178
|
128159
|
129583
|
130469
|
130595