Browse Source

Bug 27993: Add handling for datecancelled in in_transit

This patch adds handling for the datecancelled field in the in_transit
method.

Test plan
1/ Run the new unit test in t/db_dependent/Koha/Item/Transfer.t

Signed-off-by: Petro Vashchuk <stalkernoid@gmail.com>
Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
21.05.x
Martin Renvoize 2 years ago
committed by Jonathan Druart
parent
commit
b60fe963f9
  1. 4
      Koha/Item/Transfer.pm

4
Koha/Item/Transfer.pm

@ -94,7 +94,9 @@ Boolean returning whether the transfer is in transit or waiting
sub in_transit {
my ($self) = @_;
return ( defined( $self->datesent ) && !defined( $self->datearrived ) );
return ( defined( $self->datesent )
&& !defined( $self->datearrived )
&& !defined( $self->datecancelled ) );
}
=head3 receive

Loading…
Cancel
Save