From: Bernd Bleßmann Date: Fri, 2 Jun 2017 09:24:49 +0000 (+0200) Subject: Part Controller - Artikelnummern immer änderbar X-Git-Tag: release-3.5.4~1052 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=0db760fd70816d2199a188799534c3ef3d8d36ec;p=kivitendo-erp.git Part Controller - Artikelnummern immer änderbar behebt #264 (redmine) --- diff --git a/SL/Controller/Part.pm b/SL/Controller/Part.pm index 267c5d58d..10c6c10b6 100644 --- a/SL/Controller/Part.pm +++ b/SL/Controller/Part.pm @@ -681,8 +681,6 @@ sub parse_form { my $params = delete($::form->{part}) || { }; delete $params->{id}; - # never overwrite existing partnumber for parts in use, should be a read-only field in that case anyway - delete $params->{partnumber} if $self->part->partnumber and $self->part->used_in_record; $self->part->assign_attributes(%{ $params}); $self->part->bin_id(undef) unless $self->part->warehouse_id; diff --git a/templates/webpages/part/_basic_data.html b/templates/webpages/part/_basic_data.html index a923d9134..38b15d2e5 100644 --- a/templates/webpages/part/_basic_data.html +++ b/templates/webpages/part/_basic_data.html @@ -19,9 +19,7 @@ - [% SET readonly = 1 %] - [%- IF !SELF.part.id or !SELF.part.used_in_record %][% readonly = 0 %][% END %] - + @@ -239,4 +237,3 @@
[% 'Part Number' | $T8 %][% L.input_tag("part.partnumber", SELF.part.partnumber, size=40, readonly=readonly class="initial_focus") %][% L.input_tag("part.partnumber", SELF.part.partnumber, size=40, class="initial_focus") %]
[% 'Part Classification' | $T8 %]
-