diff --git a/lib/NGCP/Panel/Controller/Contact.pm b/lib/NGCP/Panel/Controller/Contact.pm index c6401804be..b8b9abdc9d 100644 --- a/lib/NGCP/Panel/Controller/Contact.pm +++ b/lib/NGCP/Panel/Controller/Contact.pm @@ -126,7 +126,7 @@ sub edit :Chained('base') :PathPart('edit') :Args(0) { $params->{reseller}{id} = $c->user->reseller_id; } elsif($c->user->is_superuser) { $form = NGCP::Panel::Form::Contact::Admin->new; - $params->{reseller}{id} = $c->stash->{contact}->reseller->id; + $params->{reseller}{id} = $c->stash->{contact}->reseller_id; } else { $form = NGCP::Panel::Form::Contact::Reseller->new; } diff --git a/lib/NGCP/Panel/Form/Contact/Reseller.pm b/lib/NGCP/Panel/Form/Contact/Reseller.pm index 5b037e303c..f6723a4721 100644 --- a/lib/NGCP/Panel/Form/Contact/Reseller.pm +++ b/lib/NGCP/Panel/Form/Contact/Reseller.pm @@ -41,7 +41,8 @@ has_field 'street' => ( ); has_field 'postcode' => ( - type => 'Integer', + type => 'Text', + maxlength => 16, ); has_field 'city' => (