1 # This file has been auto-generated only because it didn't exist.
2 # Feel free to modify it at will; it will not be overwritten automatically.
4 package SL::DB::OrderStatus;
8 use SL::DB::MetaSetup::OrderStatus;
9 use SL::DB::Manager::OrderStatus;
11 use SL::DB::Helper::ActsAsList;
13 __PACKAGE__->meta->initialize;
19 push @errors, $::locale->text('The name is missing.') if !$self->name;
21 my $not_unique_count = SL::DB::Manager::OrderStatus->get_all_count(where => ['!id' => $self->id,
22 name => $self->name]);
23 push @errors, $::locale->text('The name is not unique.') if $not_unique_count;