Bugzilla – Attachment 62361 Details for
Bug 12388
IssueSlip output should be sorted by date_due, not timestamp
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 12388: IssueSlip output should be sorted by date_due, not timestamp
Bug-12388-IssueSlip-output-should-be-sorted-by-dat.patch (text/plain), 1.22 KB, created by
Lari Taskula
on 2017-04-19 11:29:11 UTC
(
hide
)
Description:
Bug 12388: IssueSlip output should be sorted by date_due, not timestamp
Filename:
MIME Type:
Creator:
Lari Taskula
Created:
2017-04-19 11:29:11 UTC
Size:
1.22 KB
patch
obsolete
>From 5a1e427948c49ee16dc9bbbc9427e05bc169274e Mon Sep 17 00:00:00 2001 >From: Lari Taskula <lari.taskula@jns.fi> >Date: Wed, 19 Apr 2017 11:27:45 +0000 >Subject: [PATCH] Bug 12388: IssueSlip output should be sorted by date_due, not > timestamp > >--- > C4/Members.pm | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > >diff --git a/C4/Members.pm b/C4/Members.pm >index ee10cc7..09a08bf 100644 >--- a/C4/Members.pm >+++ b/C4/Members.pm >@@ -1170,6 +1170,7 @@ sub IssueSlip { > my @issues = @{ GetPendingIssues($borrowernumber) }; > > for my $issue (@issues) { >+ $issue->{date_due_orig} = $issue->{date_due}; > $issue->{date_due} = $issue->{date_due_sql}; > if ($quickslip) { > my $today = output_pref({ dt => dt_from_string, dateformat => 'iso', dateonly => 1 }); >@@ -1182,7 +1183,9 @@ sub IssueSlip { > > # Sort on timestamp then on issuedate (useful for tests and could be if modified in a batch > @issues = sort { >- my $s = $b->{timestamp} <=> $a->{timestamp}; >+ my $s = $a->{date_due_orig} <=> $b->{date_due_orig}; >+ $s == 0 ? >+ $b->{timestamp} <=> $a->{timestamp} : $s; > $s == 0 ? > $b->{issuedate} <=> $a->{issuedate} : $s; > } @issues; >-- >2.7.4
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 12388
:
41784
|
62361
|
91522
|
91766
|
102977
|
104033
|
104034
|
114180