$::request->layout->focus() größtenteils durch class="initial_focus" ersetzen
[kivitendo-erp.git] / templates / webpages / ct / form_header.html
index 26e71b1..294cf47 100644 (file)
@@ -1,7 +1,6 @@
 [%- USE T8 %]
 [% USE HTML %][% USE LxERP %]
 [% USE L %]
-<body>
 
  <h1>[% title %]</h1>
 
@@ -9,22 +8,21 @@
 
  <form method="post" name="ct" action="ct.pl" >
 
-  <ul id="maintab" class="shadetabs">
-   <li class="selected"><a href="#" rel="billing">[% 'Billing Address' | $T8 %]</a></li>
-   <li><a href="#" rel="shipto">[% 'Shipping Address' | $T8 %]</a></li>
-   <li><a href="#" rel="contacts">[% 'Contacts' | $T8 %]</a></li>
+  <div class="tabwidget">
+   <ul>
+    <li><a href="#billing">[% 'Billing Address' | $T8 %]</a></li>
+    <li><a href="#shipto">[% 'Shipping Address' | $T8 %]</a></li>
+    <li><a href="#contacts">[% 'Contacts' | $T8 %]</a></li>
 [%- IF id %]
-   <li><a href="#" rel="deliveries">[% 'Supplies' | $T8 %]</a></li>
+    <li><a href="#deliveries">[% 'Supplies' | $T8 %]</a></li>
 [%- END %]
-   <li><a href="#" rel="vcnotes">[% 'Notes' | $T8 %]</a></li>
-   [%- IF CUSTOM_VARIABLES.CT.size %]
-   <li><a href="#" rel="custom_variables">[% 'Custom Variables' | $T8 %]</a></li>
-   [%- END %]
-  </ul>
-
-  <div class="tabcontentstyle">
+    <li><a href="#vcnotes">[% 'Notes' | $T8 %]</a></li>
+[%- IF CUSTOM_VARIABLES.CT.size %]
+    <li><a href="#custom_variables">[% 'Custom Variables' | $T8 %]</a></li>
+[%- END %]
+   </ul>
 
-   <div id="billing" class="tabcontent">
+   <div id="billing">
 
     <table width="100%">
      <tr height="5"></tr>
@@ -82,7 +80,7 @@
      <tr>
       <th align="right" nowrap>[% 'Greeting' | $T8 %]</th>
       <td>
-       <input id="greeting" name="greeting" size="30" value="[% HTML.escape(greeting) %]">&nbsp;
+       <input id="greeting" name="greeting" size="30" value="[% HTML.escape(greeting) %]" class="initial_focus">&nbsp;
        [%- INCLUDE generic/multibox.html
              name       = 'selected_company_greeting',
              DATA       = MB_COMPANY_GREETINGS,
 
      <tr>
       <th align="right" nowrap>[% 'Street' | $T8 %]</th>
-      <td><input name="street" size="35" maxlength="75" value="[% HTML.escape(street) %]"></td>
+      <td>
+        <input name="street" size="35" maxlength="75" value="[% HTML.escape(street) %]">
+        <a
+          href="#"
+          onclick="window.open('https://maps.google.com/maps?q='+ encodeURIComponent($('#billing input[name=street]').val() +', '+ $('#billing input[name=zipcode]').val() +' '+ $('#billing input[name=city]').val() +', '+ $('#billing input[name=country]').val()), '_blank'); window.focus();"
+          title="[% 'Map' | $T8 %]"
+          >
+            <img src="image/map.png" alt="[% 'Map' | $T8 %]" />
+          </a>
+      </td>
      </tr>
 
      <tr>
       <td><input name="email" size="45" value="[% HTML.escape(email) %]"></td>
      </tr>
 
+     <tr>
+      <th align="right" nowrap>[% 'Cc E-mail' | $T8 %]</th>
+      <td><input name="cc" size="45" value="[% HTML.escape(cc) %]"></td>
+     </tr>
+
+     <tr>
+      <th align="right" nowrap>[% 'Bcc E-mail' | $T8 %]</th>
+      <td><input name="bcc" size="45" value="[% HTML.escape(bcc) %]"></td>
+     </tr>
+
+
      <tr>
       <th align="right" nowrap>
       [% IF homepage %]<a href="[% HTML.escape(homepage) %]" title="[% 'Open this Website' | $T8 %]" target="_blank">[% 'Homepage' | $T8 %]</a>
       <td><input name="taxnumber" size="20" value="[% HTML.escape(taxnumber) %]"></td>
       <!-- Anm.: R&B 15.11.2008     VAT Reg No ist Ust-ID in GB, aber generell sollte es laut Richardson die sales tax id sein -->
       <th align="right">[% 'sales tax identification number' | $T8 %]</th>
-      <td><input name="ustid" id="ustid" maxlength="14" size="20" value="[% HTML.escape(ustid) %]"></td>
+      <td>[% L.input_tag('ustid', ustid, maxlength=14, size=30) %]</td>
       [%- IF is_customer %]
       <th align="right">[% 'our vendor number at customer' | $T8 %]</th>
-      <td><input name="c_vendor_id" size="10" value="[% HTML.escape(c_vendor_id) %]"></td>
+      <td>[% L.input_tag('c_vendor_id', c_vendor_id, size=30) %]</td>
       [%- ELSE %]
       <th align="right">[% 'Customer Number' | $T8 %]</th>
-      <td><input name="v_customer_id" size="10" value="[% HTML.escape(v_customer_id) %]"></td>
+      <td>[% L.input_tag('v_customer_id', v_customer_id, size=30) %]</td>
       [%- END %]
      </tr>
 
      <tr>
       <th align="right">[% 'Account Number' | $T8 %]</th>
-      <td><input name="account_number" size="10" maxlength="100" value="[% HTML.escape(account_number) %]"></td>
+      <td>[% L.input_tag('account_number', account_number, size=30) %]</td>
       <th align="right">[% 'Bank Code Number' | $T8 %]</th>
-      <td><input name="bank_code" size="10" maxlength="100" value="[% HTML.escape(bank_code) %]"></td>
+      <td>[% L.input_tag('bank_code', bank_code, size=30) %]</td>
       <th align="right">[% 'Bank' | $T8 %]</th>
-      <td><input name="bank" size="20" value="[% HTML.escape(bank) %]"></td>
+      <td>[% L.input_tag('bank', bank, size=30) %]</td>
      </tr>
 
      <tr>
       <th align="right">[% 'IBAN' | $T8 %]</th>
-      <td><input name="iban" size="10" maxlength="100" value="[% HTML.escape(iban) %]"></td>
+      <td>[% L.input_tag('iban', iban, maxlength=100, size=30) %]</td>
       <th align="right">[% 'BIC' | $T8 %]</th>
-      <td><input name="bic" size="10" maxlength="100" value="[% HTML.escape(bic) %]"></td>
+      <td>[% L.input_tag('bic', bic, maxlength=100, size=30) %]</td>
       [%- IF ALL_CURRENCIES.size %]
         <th align="right">[% 'Currency' | $T8 %]</th>
-        <td>[% L.select_tag('currency', ALL_CURRENCIES, default = currency, with_empty = 1) %]</td>
+        <td>[% L.select_tag('currency', ALL_CURRENCIES, default = currency) %]</td>
       [%- END %]
      </tr>
 
      </tr>
 
      <tr>
-      <td align="right">[% 'Obsolete' | $T8 %]</td>
-      <td><input name="obsolete" class="checkbox" type="checkbox" value="1" [% IF obsolete %]checked[% END %]></td>
-      <td align="right">[% 'direct debit' | $T8 %]</td>
-      <td><input name="direct_debit" class="checkbox" type="checkbox" value="1" [% IF direct_debit %]checked[% END %]></td>
+      <td align="right"><label for="obsolete">[% 'Obsolete' | $T8 %]</label></td>
+      <td><input name="obsolete" id="obsolete" class="checkbox" type="checkbox" value="1" [% IF obsolete %]checked[% END %]></td>
+      <td align="right"><label for="direct_debit">[% 'direct debit' | $T8 %]</label></td>
+      <td><input name="direct_debit" id="direct_debit" class="checkbox" type="checkbox" value="1" [% IF direct_debit %]checked[% END %]></td>
      </tr>
 
      <tr>
       <th align="right">[% 'Salesman' | $T8 %]</th>
       <td>[% L.select_tag('salesman_id', ALL_SALESMEN, default = salesman_id, with_empty = 1, title_key = 'safe_name') %]</td>
       [%- END %]
-     </tr>
 
-     <tr>
       <td>[% 'taxincluded checked' | $T8 %]</td>
       <td>[% L.select_tag('taxincluded_checked', [[undef, LxERP.t8('use user config')], ['1', LxERP.t8('Yes')], ['0', LxERP.t8('No')]], default = taxincluded_checked) %]</td>
      </tr>
       <td><textarea name="notes" rows="3" cols="60" wrap="soft">[% HTML.escape(notes) %]</textarea></td>
      </tr>
     </table>
-
-    <br style="clear: left" />
    </div>
 
-   <div id="shipto" class="tabcontent">
+   <div id="shipto">
     [% INCLUDE 'ct/_shipto.html' %]
    </div>
 
-   <div id="contacts" class="tabcontent">
+   <div id="contacts">
     [% INCLUDE 'ct/_contact.html' %]
    </div>
 
-   <div id="deliveries" class="tabcontent">
+   <div id="deliveries">
     <table>
      <tr>
       <th align="right">[% 'Shipping Address' | $T8 %]</th>
       <td colspan="3">
-       [% L.select_tag('delivery_id', SHIPTO_ALL, title_sub = \shipto_label, with_empty = 1,
-                       onchange = "\$('#delivery').load('ct.pl?action=get_delivery&id=' + \$('#cvid').attr('value') + '&db=' + \$('#db').attr('value') + '&shipto_id=' + this.value)") %]
+       [% L.select_tag('delivery_id', SHIPTO_ALL, value_key = 'shipto_id', title_sub = \shipto_label, with_empty = 1,
+                       onchange = "\$('#delivery').load('ct.pl?action=get_delivery&id=' + \$('#cvid').val() + '&db=' + \$('#db').val() + '&shipto_id=' + this.value)") %]
       </td>
      </tr>
 
       </td>
      </tr>
     </table>
-
-    <br style="clear: left" />
    </div>
 
-   <div id="vcnotes" class="tabcontent">
+   <div id="vcnotes">
 
     [%- IF NOTES && NOTES.size %]
     <p>
        <td>
         [% L.date_tag('FU_date', FU_date) %]
         [% 'for' | $T8 %]
-        [% L.select_tag('FU_created_for_user', ALL_EMPLOYEES, default = (FU_created_for_user ? FU_created_for_user : USER.id), title='safe_name') %]
+        [% L.select_tag('FU_created_for_user', ALL_EMPLOYEES, default = (FU_created_for_user ? FU_created_for_user : USER.id), title_key='safe_name') %]
        </td>
       </tr>
 
       </tr>
      </table>
     </p>
-
-    <br style="clear: left" />
    </div>
 
    [%- IF CUSTOM_VARIABLES.CT.size %]
-   <div id="custom_variables" class="tabcontent">
+   <div id="custom_variables">
 
     <p>
      <table>
       [%- END %]
      </table>
     </p>
-
-    <br style="clear: left" />
    </div>
    [%- END %]