Bugzilla – Attachment 94887 Details for
Bug 15260
Option for extended loan with useDaysMode
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15260: (follow-up) Fix bug in subtraction
Bug-15260-follow-up-Fix-bug-in-subtraction.patch (text/plain), 1.02 KB, created by
Josef Moravec
on 2019-10-30 18:34:21 UTC
(
hide
)
Description:
Bug 15260: (follow-up) Fix bug in subtraction
Filename:
MIME Type:
Creator:
Josef Moravec
Created:
2019-10-30 18:34:21 UTC
Size:
1.02 KB
patch
obsolete
>From 18c9e677691206af1d6900edae9d8a095e720831 Mon Sep 17 00:00:00 2001 >From: Andrew Isherwood <andrew.isherwood@ptfs-europe.com> >Date: Wed, 1 May 2019 12:12:14 +0100 >Subject: [PATCH] Bug 15260: (follow-up) Fix bug in subtraction > >prev_open_days can receive either positive or negative numbers and >then does the right thing with them. However, we weren't also doing this >with the number it receives back from get_push_amt > >Signed-off-by: Liz Rea <wizzyrea@gmail.com> > >Signed-off-by: Josef Moravec <josef.moravec@gmail.com> >--- > Koha/Calendar.pm | 2 ++ > 1 file changed, 2 insertions(+) > >diff --git a/Koha/Calendar.pm b/Koha/Calendar.pm >index 25299c1c53..775c7755fe 100644 >--- a/Koha/Calendar.pm >+++ b/Koha/Calendar.pm >@@ -310,6 +310,8 @@ sub prev_open_days { > > while ($self->is_holiday($base_date)) { > my $sub_next = $self->get_push_amt($base_date); >+ # Ensure we're subtracting when we need to be >+ $sub_next = $sub_next > 0 ? 0 - $sub_next : $sub_next; > $base_date->add(days => $sub_next); > } > >-- >2.11.0
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 15260
:
87906
|
88052
|
88053
|
88054
|
88055
|
88056
|
88057
|
88059
|
88607
|
88608
|
88609
|
88610
|
88611
|
88612
|
88613
|
89178
|
89380
|
89381
|
89382
|
89383
|
89384
|
89385
|
89386
|
89387
|
89388
|
89885
|
94880
|
94881
|
94882
|
94883
|
94884
|
94885
|
94886
| 94887 |
94888
|
94889