@@ -, +, @@ deleted_at --- Koha/ItemType.pm | 2 +- t/db_dependent/Items_DelItemCheck.t | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) --- a/Koha/ItemType.pm +++ a/Koha/ItemType.pm @@ -101,7 +101,7 @@ Counts up the number of biblioitems and items with itemtype (code) and hands bac sub can_be_deleted { my ($self) = @_; - my $nb_items = Koha::Items->search( { itype => $self->itemtype, deleted_at => undef } )->count; + my $nb_items = Koha::Items->search( { itype => $self->itemtype, deleted_on => undef } )->count; my $nb_biblioitems = Koha::Biblioitems->search( { itemtype => $self->itemtype } )->count; return $nb_items + $nb_biblioitems == 0 ? 1 : 0; } --- a/t/db_dependent/Items_DelItemCheck.t +++ a/t/db_dependent/Items_DelItemCheck.t @@ -161,7 +161,7 @@ DelItemCheck( $biblio->{biblionumber}, $item->{itemnumber} ); my $test_item = GetItem( $item->{itemnumber} ); -isnt( $test_item->{deleted_at}, undef, +isnt( $test_item->{deleted_on}, undef, "DelItemCheck should delete item if ItemSafeToDelete returns true" ); --