X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FDB%2FRequirementSpecType.pm;h=65256808b1e3ebe378ffb437cd2068558f1847e4;hb=1b032ef45d886922f1fe347ec234c9b0c8c50efd;hp=cf489542ff1e862a94507b74c19bc35898c0c4d9;hpb=baac72df4777f1d63da63867e893c302b5c0bf5a;p=kivitendo-erp.git diff --git a/SL/DB/RequirementSpecType.pm b/SL/DB/RequirementSpecType.pm index cf489542f..65256808b 100644 --- a/SL/DB/RequirementSpecType.pm +++ b/SL/DB/RequirementSpecType.pm @@ -7,11 +7,14 @@ use SL::DB::Manager::RequirementSpecType; use SL::DB::Helper::ActsAsList; use SL::Locale::String; +__PACKAGE__->meta->initialize; + sub validate { my ($self) = @_; my @errors; - push @errors, t8('The description is missing.') if !$self->description; + push @errors, t8('The description is missing.') if !$self->description; + push @errors, t8('The description is not unique.') if $self->get_first_conflicting('description'); return @errors; }