View | Details | Raw Unified | Return to bug 32627
Collapse All | Expand All

(-)a/Koha/Hold.pm (-3 / +2 lines)
Lines 231-237 sub set_waiting { Link Here
231
    my $max_pickup_delay = C4::Context->preference("ReservesMaxPickUpDelay");
231
    my $max_pickup_delay = C4::Context->preference("ReservesMaxPickUpDelay");
232
    my $cancel_on_holidays = C4::Context->preference('ExpireReservesOnHolidays');
232
    my $cancel_on_holidays = C4::Context->preference('ExpireReservesOnHolidays');
233
233
234
    my $new_expiration_date = $today->clone->add(days => $max_pickup_delay);
234
    my $new_expiration_date = dt_from_string($self->waitingdate)->clone->add( days => $max_pickup_delay );
235
235
236
    if ( C4::Context->preference("ExcludeHolidaysFromMaxPickUpDelay") ) {
236
    if ( C4::Context->preference("ExcludeHolidaysFromMaxPickUpDelay") ) {
237
        my $itemtype = $self->item ? $self->item->effective_itemtype : $self->biblio->itemtype;
237
        my $itemtype = $self->item ? $self->item->effective_itemtype : $self->biblio->itemtype;
Lines 244-250 sub set_waiting { Link Here
244
        );
244
        );
245
        my $calendar = Koha::Calendar->new( branchcode => $self->branchcode, days_mode => $daysmode );
245
        my $calendar = Koha::Calendar->new( branchcode => $self->branchcode, days_mode => $daysmode );
246
246
247
        $new_expiration_date = $calendar->days_forward( dt_from_string(), $max_pickup_delay );
247
        $new_expiration_date = $calendar->days_forward( dt_from_string($self->waitingdate), $max_pickup_delay );
248
    }
248
    }
249
249
250
    # If patron's requested expiration date is prior to the
250
    # If patron's requested expiration date is prior to the
251
- 

Return to bug 32627