ActionBar: Verwendung bei »Einkauf« → »Berichte« → »Einkaufsrechnungen…«
[kivitendo-erp.git] / templates / webpages / ar / form_header.html
index e0ae0be..8f59a37 100644 (file)
@@ -3,7 +3,11 @@
 [%- USE T8 %]
 [%- USE LxERP %][%- USE P -%]
 
-<form method=post name="arledger" action="[% script %]">
+<h1>[% title | html %]</h1>
+
+[%- INCLUDE 'common/flash.html' %]
+
+<form method=post name="arledger" action="[% script %]" id="form">
 
 [% L.hidden_tag('id', id) %]
 [% L.hidden_tag('sort', sort) %]
 [% L.hidden_tag('follow_up_rowcount', 1) %]
 <input type="hidden" name="lastmtime" value="[% HTML.escape(lastmtime) %]">
 
-<h1>[% title | html %]</h1>
-
 [%- IF saved_message %]<p>[% saved_message | html  %]</p>[% END %]
 
 <div class="tabwidget">
  <ul>
   <li><a href="#ui-tabs-basic-data">[% 'Basic Data' | $T8 %]</a></li>
 [%- IF id %]
+  [%- IF INSTANCE_CONF.get_doc_storage %]
+  <li><a href="controller.pl?action=File/list&file_type=attachment&object_type=invoice&object_id=[% HTML.url(id) %]">[% 'Attachments' | $T8 %]</a></li>
+  [%- END %]
   [% IF AUTH.assert('record_links', 1) %]
   <li><a href="controller.pl?action=RecordLinks/ajax_list&object_model=Invoice&object_id=[% HTML.url(id) %]">[% 'Linked Records' | $T8 %]</a></li>
   [%- END %]
               <tr>
                 <th align="right" nowrap>[% 'Customer' | $T8 %]</th>
                 <td colspan=3>
-[%- IF selectcustomer %]
-    <select id='customer' name="customer" onchange="document.getElementById('update_button').click();"[% IF initial_focus == 'customer'%] class="initial_focus"[% END %]>[% selectcustomer %]</select>
-[%- ELSE %]
-    <input id='customer' name=customer value="[% customer | html %]" size=35[% IF initial_focus == 'customer'%] class="initial_focus"[% END %]>
-[%- END %]
-                <input type="button" value="[% 'Details (one letter abbreviation)' | $T8 %]" onclick="show_vc_details('customer')"></td>
-                [% L.hidden_tag('selectcustomer', selectcustomer) %]
-                [% L.hidden_tag('oldcustomer', oldcustomer) %]
-                [% L.hidden_tag('customer_id', customer_id) %]
-                [% L.hidden_tag('terms', terms) %]
+                 [% P.customer_vendor_picker("customer_id", customer_id, type="customer", style="width: 300px", class=(initial_focus == 'customer_id' ? "initial_focus" : "")) %]
+                 [% L.button_tag("show_vc_details('customer')", LxERP.t8('Details (one letter abbreviation)')) %]
+                 [% L.hidden_tag("previous_customer_id", customer_id) %]
+                 [% L.hidden_tag('terms', terms) %]
+               </td>
               </tr>
 [%- IF max_dunning_level || invoice_obj.dunning_config_id  %]
               <tr>