Bugzilla – Attachment 112907 Details for
Bug 26172
Add a cashup summary view (with option to print)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26172: Replace calls to _result[set]
Bug-26172-Replace-calls-to-resultset.patch (text/plain), 2.22 KB, created by
Jonathan Druart
on 2020-11-03 10:48:27 UTC
(
hide
)
Description:
Bug 26172: Replace calls to _result[set]
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2020-11-03 10:48:27 UTC
Size:
2.22 KB
patch
obsolete
>From de00c7a0b1b8093a162b0998707e97dae5a71262 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 3 Nov 2020 11:40:57 +0100 >Subject: [PATCH] Bug 26172: Replace calls to _result[set] > >--- > Koha/Cash/Register/Action.pm | 14 ++++++-------- > 1 file changed, 6 insertions(+), 8 deletions(-) > >diff --git a/Koha/Cash/Register/Action.pm b/Koha/Cash/Register/Action.pm >index 157ee7daf6..759bd98ccc 100644 >--- a/Koha/Cash/Register/Action.pm >+++ b/Koha/Cash/Register/Action.pm >@@ -81,16 +81,14 @@ sub cashup_summary { > order_by => { '-desc' => [ 'timestamp', 'id' ] }, > rows => 1 > } >- ); >- >- my $previous = $prior_cashup->single; >+ )->single; > > my $conditions = >- $previous >+ $prior_cashup > ? { > 'date' => { > '-between' => >- [ $previous->_result->get_column('timestamp'), $self->timestamp ] >+ [ $prior_cashup->timestamp, $self->timestamp ] > } > } > : { 'date' => { '<' => $self->timestamp } }; >@@ -105,7 +103,7 @@ sub cashup_summary { > my $income_summary = Koha::Account::Offsets->search( > { > 'me.credit_id' => >- { '-in' => $income_transactions->_resultset->get_column('accountlines_id')->as_query }, >+ { '-in' => [ $income_transactions->get_column('accountlines_id') ] }, > 'me.debit_id' => { '!=' => undef } > }, > { >@@ -120,7 +118,7 @@ sub cashup_summary { > my $outgoing_summary = Koha::Account::Offsets->search( > { > 'me.debit_id' => >- { '-in' => $outgoing_transactions->_resultset->get_column('accountlines_id')->as_query }, >+ { '-in' => [ $outgoing_transactions->get_column('accountlines_id') ] }, > 'me.credit_id' => { '!=' => undef } > }, > { >@@ -148,7 +146,7 @@ sub cashup_summary { > } $outgoing_summary->as_list; > > $summary = { >- from_date => $previous ? $previous->timestamp : undef, >+ from_date => $prior_cashup? $prior_cashup->timestamp : undef, > to_date => $self->timestamp, > income => \@income, > outgoing => \@outgoing, >-- >2.20.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 26172
:
108093
|
108095
|
108523
|
108817
|
108818
|
108822
|
108825
|
108826
|
108827
|
111162
|
111163
|
111164
|
111598
|
111599
|
111600
|
111601
|
111629
|
111630
|
111631
|
111632
|
111633
|
111634
|
111668
|
111683
|
111691
|
111692
|
111731
|
111732
|
112907
|
112908
|
112909