From f27794056c50783ab7af7fb4af5c48097001cc3b Mon Sep 17 00:00:00 2001 From: "G. Richardson" Date: Thu, 11 Aug 2016 15:52:58 +0200 Subject: [PATCH] Part validate --- SL/DB/Part.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SL/DB/Part.pm b/SL/DB/Part.pm index be6851eec..46a06513c 100644 --- a/SL/DB/Part.pm +++ b/SL/DB/Part.pm @@ -72,7 +72,7 @@ sub validate { my ($self) = @_; my @errors; - push @errors, $::locale->text('The partnumber is missing.') unless $self->partnumber; + push @errors, $::locale->text('The partnumber is missing.') if $self->id and !$self->partnumber; push @errors, $::locale->text('The unit is missing.') unless $self->unit; push @errors, $::locale->text('The buchungsgruppe is missing.') unless $self->buchungsgruppen_id or $self->buchungsgruppe; -- 2.20.1