https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31235 Bug ID: 31235 Summary: UseDaysMode is used for calculating the expiration date for waiting holds Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Circulation Assignee: koha-bugs@lists.koha-community.org Reporter: katrin.fischer@bsz-bw.de QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com This is also a confusing one: The UseDaysMode system preference, that can also be set in the circulation rules is described as: ... when calculating the date due. BUT: In set_waiting it's also used to calculate the expiration date for holds: my $max_pickup_delay = C4::Context->preference("ReservesMaxPickUpDelay"); my $cancel_on_holidays = C4::Context->preference('ExpireReservesOnHolidays'); my $expirationdate = $today->clone; $expirationdate->add(days => $max_pickup_delay); if ( C4::Context->preference("ExcludeHolidaysFromMaxPickUpDelay") ) { my $itemtype = $self->item ? $self->item->effective_itemtype : $self->biblio->itemtype; my $daysmode = Koha::CirculationRules->get_effective_daysmode( { categorycode => $self->borrower->categorycode, itemtype => $itemtype, branchcode => $self->branchcode, } ); my $calendar = Koha::Calendar->new( branchcode => $self->branchcode, days_mode => $daysmode ); $expirationdate = $calendar->days_forward( dt_from_string(), $max_pickup_delay ); } I feel like this is quite odd as you can set ExcludeHolidaysFromMaxPickUpDelay to ignore the calendar (and then it will be ignored). But if you set it to use the calendar, it can still be ignored when the UseDaysMode setting is set to ignore calendar. So it should probably be: Ignore the calendar | Use UseDaysMode setting ... If asked previously, I'd have said don't make this rely on UseDaysMode and just use calendar or not. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.