X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/f16c552035ab973a9aed4a1dc29d0e16be7ff541..c6dd542b51ae9549ad42a54f9023b905412bbab9:/SL/DB/Vendor.pm?ds=sidebyside diff --git a/SL/DB/Vendor.pm b/SL/DB/Vendor.pm index ebbe8125f..b1458efc3 100644 --- a/SL/DB/Vendor.pm +++ b/SL/DB/Vendor.pm @@ -41,6 +41,15 @@ sub _before_save_set_vendornumber { return 1; } +sub validate { + my ($self) = @_; + + my @errors; + push @errors, $::locale->text('The vendor name is missing.') if !$self->name; + + return @errors; +} + sub displayable_name { my $self = shift;