Bug 15986: Update for bug 24159

The job is concerned with holds waiting and takes days, I think using days_mode 'Calendar'
makes sense as we are not calculating due dates

Signed-off-by: Kim Gnerre <kgnerre@hotchkiss.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Nick Clemens 2020-07-16 16:34:26 +00:00 committed by Jonathan Druart
parent f719371662
commit 8e014ad644
1 changed files with 1 additions and 1 deletions

View File

@ -233,7 +233,7 @@ foreach my $branchcode (@branchcodes) { #BEGIN BRANCH LOOP
# If respecting calendar get the correct waiting since date
my $waiting_date;
if( $use_calendar ){
my $calendar = Koha::Calendar->new( branchcode => $branchcode );
my $calendar = Koha::Calendar->new( branchcode => $branchcode, days_mode => 'Calendar' );
my $duration = DateTime::Duration->new( days => -$days );
$waiting_date = $calendar->addDays($date_to_run,$duration); #Add negative of days
} else {