Beim Speichern von Angeboten etc den Bearbeiter nicht aus $form->{employee} ableiten...
[kivitendo-erp.git] / bin / mozilla / is.pl
index 9922357..2cbf9cd 100644 (file)
@@ -346,7 +346,7 @@ sub form_header {
     <tr>
       <th align="right">| . $locale->text('Contact Person') . qq|</th>
       <td>| .
-      NTI($cgi->popup_menu('-name' => 'cp_id', '-values' => \@values,
+      NTI($cgi->popup_menu('-name' => 'cp_id', '-values' => \@values, '-style' => 'width: 250px',
                            '-labels' => \%labels, '-default' => $form->{"cp_id"}))
       . qq|
       </td>
@@ -374,7 +374,7 @@ sub form_header {
   @values = ();
   foreach my $item (@{ $form->{"ALL_CUSTOMERS"} }) {
     push(@values, $item->{name}.qq|--|.$item->{"id"});
-    $labels{$item->{"id"}} = $item->{name}.qq|--|.$item->{"id"};
+    $labels{$item->{name}.qq|--|.$item->{"id"}} = $item->{"name"};
   }
 
   my $customers = qq|
@@ -384,7 +384,7 @@ sub form_header {
               ? qq|<input type="text" value="| . H($form->{"oldcustomer"}) . qq|" name="customer">|
               : (NTI($cgi->popup_menu('-name' => 'customer', '-default' => $form->{oldcustomer},
                              '-onChange' => 'document.getElementById(\'update_button\').click();',
-                             '-values' => \@values, '-labels' => \%labels)))) . qq|
+                             '-values' => \@values, '-labels' => \%labels, '-style' => 'width: 250px')))) . qq|
         <input type="button" value="?" onclick="show_vc_details('customer')">
       </td>|;
 
@@ -392,8 +392,7 @@ sub form_header {
   @values = ("");
   foreach my $item (@{ $form->{"ALL_SHIPTO"} }) {
     push(@values, $item->{"shipto_id"});
-    $labels{$item->{"shipto_id"}} =
-      $item->{"shiptoname"} . " " . $item->{"shiptodepartment_1"};
+    $labels{$item->{"shipto_id"}} = join "; ", grep { $_ } map { $item->{"shipto${_}" } } qw(name department_1 street city);
   }
 
   my $shipto;
@@ -402,7 +401,7 @@ sub form_header {
     <tr>
       <th align="right">| . $locale->text('Shipping Address') . qq|</th>
       <td>| .
-      NTI($cgi->popup_menu('-name' => 'shipto_id', '-values' => \@values,
+      NTI($cgi->popup_menu('-name' => 'shipto_id', '-values' => \@values, '-style' => 'width: 250px',
                            '-labels' => \%labels, '-default' => $form->{"shipto_id"}))
     . qq|</td>|;
   }
@@ -467,7 +466,7 @@ sub form_header {
       <th align="right">| . $locale->text('Steuersatz') . qq|</th>
       <td>| .
         NTI($cgi->popup_menu('-name' => 'taxzone_id', '-default' => $form->{"taxzone_id"},
-                             '-values' => \@values, '-labels' => \%labels)) . qq|
+                             '-values' => \@values, '-labels' => \%labels, '-style' => 'width: 250px',)) . qq|
       </td>
     </tr>|;
 
@@ -530,7 +529,7 @@ sub form_header {
   $department = qq|
               <tr>
                <th align="right" nowrap>| . $locale->text('Department') . qq|</th>
-               <td colspan="3"><select name="department">$form->{selectdepartment}</select>
+               <td colspan="3"><select name="department" style="width: 250px">$form->{selectdepartment}</select>
                <input type="hidden" name="selectdepartment" value="$form->{selectdepartment}">
                </td>
              </tr>
@@ -541,13 +540,11 @@ sub form_header {
   if ($form->{business}) {
     $business = qq|
              <tr>
-               <th align="right">| . $locale->text('Business') . qq|</th>
-               <td>$form->{business}</td>
-               <th align="right">| . $locale->text('Trade Discount') . qq|</th>
-               <td>|
+          <th align="right">| . $locale->text('Customer type') . qq|</th>
+          <td>$form->{business}; | . $locale->text('Trade Discount') . qq| |
       . $form->format_amount(\%myconfig, $form->{tradediscount} * 100)
       . qq| %</td>
-             </tr>
+        </tr>
 |;
   }
 
@@ -644,11 +641,13 @@ sub form_header {
 
 <form method="post" name="invoice" action="$form->{script}">
 | ;
-map({print $cgi->hidden("-name" => $_ , "-value" => $form->{$_});}
-     qw(id action type media format queued printed emailed title vc discount
-        creditlimit creditremaining tradediscount business closedto locked shipped storno storno_id)) ;
-print ($form->{saved_message} ? qq|<p>$form->{saved_message}</p>| : "") ;
-print qq|
+
+  $form->hide_form(qw(id action type media format queued printed emailed title vc discount
+                      creditlimit creditremaining tradediscount business closedto locked shipped storno storno_id
+                      max_dunning_level dunning_amount));
+  print qq|<p>$form->{saved_message}</p>| if $form->{saved_message};
+
+  print qq|
 
 <input type="hidden" name="lizenzen" value="$lizenzen">
 
@@ -675,7 +674,7 @@ print qq|
         $business
              <tr>
                <th align="right" nowrap>| . $locale->text('Record in') . qq|</th>
-               <td colspan="3"><select name="AR" style="width:280px;">$form->{selectAR}</select></td>
+               <td colspan="3"><select name="AR" style="width:250px;">$form->{selectAR}</select></td>
                <input type="hidden" name="selectAR" value="$form->{selectAR}">
              </tr>
               $taxzone