Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 06824e7c

Von Hans P. Schlaepfer vor mehr als 4 Jahren hinzugefügt

  • ID 06824e7c7298374a159bd0c0307ce3b324cc4b6c
  • Vorgänger 70053431
  • Nachfolger a3dd425b

Neues Design 2019 Standard-Code templates/webpages/do/form_*

Unterschiede anzeigen:

templates/webpages/do/form_footer.html
[%- IF delivered %]
[%- SET RO = ' readonly' %]
[%- END %]
[% USE T8 %]
[% USE HTML %]
[% USE LxERP %]
[% USE L %]
[% USE P %]
[% IF show_weight %]
<table class="tbl-horizontal">
<tbody>
<tr>
<td>
<table>
<tr valign="bottom">
<th align="left">[% 'Notes' | $T8 %]</th>
<th align="left">[% 'Internal Notes' | $T8 %]</th>
</tr>
<th>[% 'Total weight' | $T8 %]</th>
<td>[% LxERP.format_amount(totalweight, 3) %] [% HTML.escape(weightunit) %]</td>
</tr>
</tbody>
</table>
[% END %]
<tr valign="top">
<td>
[% IF delivered %]
[% L.hidden_tag("notes", notes) %]
<div style="width: 350px; height: 150px; border: 1px solid black">[% P.restricted_html(notes) %]</div>
[% ELSE %]
[% L.textarea_tag("notes", notes, wrap="soft", style="width: 350px; height: 150px", class="texteditor") %]
[% END %]
</td>
<td>[% L.textarea_tag("intnotes", intnotes, wrap="soft", style="width: 350px; height: 150px") %]</td>
</tr>
</div>
<tr>
<th align="right">[% 'Delivery Terms' | $T8 %]</th>
<td>[% L.select_tag('delivery_term_id', ALL_DELIVERY_TERMS, default = delivery_term_id, with_empty = 1, title_key = 'description') %]</td>
</tr>
</table>
</td>
</tr>
[%- IF show_weight %]
<tr>
<td>
<table width="100%">
<tr valign="bottom">
<td align="right">
<table>
<tr>
<th align="left">[% 'Total weight' | $T8 %]</th>
<td align="right">
[% LxERP.format_amount(totalweight, 3) %] [% HTML.escape(weightunit) %]
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
[%- END %]
</table>
</p>
</div>
[% PROCESS 'webdav/_list.html' %]
<div id="ui-tabs-1">
[%- LxERP.t8("Loading...") %]
[% LxERP.t8("Loading...") %]
</div>
</div>
<input type="hidden" id="rowcount" name="rowcount" value="[% HTML.escape(rowcount) %]">
<input name="callback" type="hidden" value="[% HTML.escape(callback) %]">
<input type="hidden" name="rowcount" value="[% HTML.escape(rowcount) %]">
<input name="callback" type="hidden" value="[% HTML.escape(callback) %]">
[%- IF !delivered %]
[% IF !delivered %]
<div id="shipto_inputs" class="hidden">
[%- PROCESS 'common/_ship_to_dialog.html' vc_obj=VC_OBJ cvars=shipto_cvars %]
[% PROCESS 'common/_ship_to_dialog.html' vc_obj=VC_OBJ cvars=shipto_cvars %]
</div>
[%- END %]
[% END %]
<div id="email_inputs" class="hidden"></div>
<div id="email_inputs" class="hidden"></div>
<div id="print_options" class="hidden">
[% PRINT_OPTIONS %]
</div>
</form>
<div id="print_options" class="hidden">
[% PRINT_OPTIONS %]
</div>
</form>
<script type='text/javascript'>
$(kivi.SalesPurchase.init_on_submit_checks);
</script>
[%- IF !delivered %]
<div id="shipto_dialog" class="hidden"></div>
[%- END %]
[% IF !delivered %]
<div id="shipto_dialog" class="hidden"></div>
[% END %]
<div id="print_dialog" class="hidden">
[%- PROCESS 'common/_print_dialog.html' %]
[% PROCESS 'common/_print_dialog.html' %]
</div>
templates/webpages/do/form_header.html
[%# Determine which shipping address to show if the delivery order has been shipped already. %]
[%- IF delivered;
SET shipto_label = [];
IF shipto_id;
FOREACH row = ALL_SHIPTO ;
IF row.shipto_id == shipto_id ;
SET shipto_label = [ row.shiptoname, row.shiptodepartment_1, row.shiptostreet, row.shiptocity ] ;
END ;
END ;
ELSE ;
SET shipto_label = [ shiptoname, shiptodepartment_1, shiptostreet, shiptocity ] ;
[% USE T8 %]
[% USE HTML %]
[% USE LxERP %]
[% USE L %]
[% USE P %]
[% # Determine which shipping address to show if the delivery order has been shipped already. %]
[% IF delivered;
SET shipto_label = [];
IF shipto_id;
FOREACH row = ALL_SHIPTO ;
IF row.shipto_id == shipto_id ;
SET shipto_label = [ row.shiptoname, row.shiptodepartment_1, row.shiptostreet, row.shiptocity ] ;
END ;
END ;
ELSE ;
SET shipto_label = [ shiptoname, shiptodepartment_1, shiptostreet, shiptocity ] ;
END ;
SET shipto_label = shipto_label.grep('.') ;
IF !shipto_label.size ;
shipto_label = [ LxERP.t8('no shipping address') ] ;
END ;
END ; %]
SET shipto_label = shipto_label.grep('.') ;
IF !shipto_label.size ;
shipto_label = [ LxERP.t8('no shipping address') ] ;
END ;
END ; %]
<h1>[% title %]</h1>
<script type="text/javascript" src="js/show_form_details.js"></script>
<script type="text/javascript" src="js/show_history.js"></script>
<script type="text/javascript" src="js/show_vc_details.js"></script>
<script type="text/javascript" src="js/delivery_customer_selection.js"></script>
<script type="text/javascript" src="js/calculate_qty.js"></script>
<script type="text/javascript" src="js/stock_in_out.js"></script>
<script type="text/javascript" src="js/follow_up.js"></script>
<script type="text/javascript" src="js/kivi.SalesPurchase.js"></script>
<style type="text/css">
.fixed_width {
width: 250px;
}
</style>
[%- IF vc == 'customer' %]
[%- SET is_customer = '1' %]
[%- ELSE %]
[%- SET vc = 'vendor' %]
[%- SET is_customer = '0' %]
[%- END %]
[%- SET vc_id = vc _ "_id" %]
[%- IF delivered %]
[%- SET DISABLED = ' disabled' %]
[%- END %]
[%- INCLUDE 'common/flash.html' %]
[%- INCLUDE 'generic/set_longdescription.html' %]
[%- IF ERRORS && ERRORS.size %]
<p><font color="#ff0000">[% ERRORS.join('<br>') %]</font></p>
[%- END %]
<form id="form" method="post" name="do" action="do.pl">
<div id="do_tabs" class="tabwidget">
<script type="text/javascript" src="js/show_form_details.js"></script>
<script type="text/javascript" src="js/show_history.js"></script>
<script type="text/javascript" src="js/show_vc_details.js"></script>
<script type="text/javascript" src="js/delivery_customer_selection.js"></script>
<script type="text/javascript" src="js/calculate_qty.js"></script>
<script type="text/javascript" src="js/stock_in_out.js"></script>
<script type="text/javascript" src="js/follow_up.js"></script>
<script type="text/javascript" src="js/kivi.SalesPurchase.js"></script>
[% IF vc == 'customer' %]
[% SET is_customer = '1' %]
[% ELSE %]
[% SET vc = 'vendor' %]
[% SET is_customer = '0' %]
[% END %]
[% SET vc_id = vc _ "_id" %]
[% IF delivered %]
[% SET DISABLED = ' disabled' %]
[% END %]
[% INCLUDE 'common/flash.html' %]
[% INCLUDE 'generic/set_longdescription.html' %]
[% IF ERRORS && ERRORS.size %]
<p class="message message_error">[% ERRORS.join('<br>') %]</p>
[% END %]
<form id="form" method="post" name="do" action="do.pl">
<div id="do_tabs" class="tabwidget">
<ul>
<li><a href="#ui-tabs-basic-data">[% 'Basic Data' | $T8 %]</a></li>
[%- IF INSTANCE_CONF.get_webdav %]
<li><a href="#ui-tabs-webdav">[% 'WebDAV' | $T8 %]</a></li>
[%- END %]
[%- IF id AND INSTANCE_CONF.get_doc_storage %]
<li><a href="#ui-tabs-basic-data">[% 'Basic Data' | $T8 %]</a></li>
[% IF INSTANCE_CONF.get_webdav %]
<li><a href="#ui-tabs-webdav">[% 'WebDAV' | $T8 %]</a></li>
[% END %]
[% IF id AND INSTANCE_CONF.get_doc_storage %]
<li><a href="controller.pl?action=File/list&file_type=document&object_type=[% HTML.escape(type) %]&object_id=[% HTML.url(id) %]">[% 'Documents' | $T8 %]</a></li>
<li><a href="controller.pl?action=File/list&file_type=attachment&object_type=[% HTML.escape(type) %]&object_id=[% HTML.url(id) %]">[% 'Attachments' | $T8 %]</a></li>
[%- END %]
[%- IF id AND AUTH.assert('record_links', 1) %]
<li><a href="controller.pl?action=RecordLinks/ajax_list&object_model=DeliveryOrder&object_id=[% HTML.url(id) %]">[% 'Linked Records' | $T8 %]</a></li>
[%- END %]
[% END %]
[% IF id AND AUTH.assert('record_links', 1) %]
<li><a href="controller.pl?action=RecordLinks/ajax_list&object_model=DeliveryOrder&object_id=[% HTML.url(id) %]">[% 'Linked Records' | $T8 %]</a></li>
[% END %]
</ul>
<div id="ui-tabs-basic-data">
<input type="hidden" name="follow_up_trans_id_1" id="follow_up_trans_id_1" value="[% HTML.escape(id) %]">
<input type="hidden" name="follow_up_trans_type_1" id="follow_up_trans_type_1" value="[% HTML.escape(type) %]">
<input type="hidden" name="follow_up_trans_info_1" id="follow_up_trans_info_1" value="[% HTML.escape(follow_up_trans_info) %]">
<input type="hidden" name="follow_up_rowcount" id="follow_up_rowcount" value="1">
<input type="hidden" name="business" id="business" value="[% HTML.escape(business) %]">
<input type="hidden" name="closed" id="closed" value="[% HTML.escape(closed) %]">
<input type="hidden" name="convert_from_oe_ids" id="convert_from_oe_ids" value="[% HTML.escape(convert_from_oe_ids) %]">
<input type="hidden" name="currency" id="currency" value="[% HTML.escape(currency) %]">
<input type="hidden" name="customer_pricegroup_id" id="customer_pricegroup_id" value="[% HTML.escape(customer_pricegroup_id) %]">
<input type="hidden" name="discount" id="discount" value="[% HTML.escape(discount) %]">
<input type="hidden" name="dunning_amount" id="dunning_amount" value="[% HTML.escape(dunning_amount) %]">
<input type="hidden" name="emailed" id="emailed" value="[% HTML.escape(emailed) %]">
<input type="hidden" name="id" id="id" value="[% HTML.escape(id) %]">
<input type="hidden" name="max_dunning_level" id="max_dunning_level" value="[% HTML.escape(max_dunning_level) %]">
<input type="hidden" name="printed" id="printed" value="[% HTML.escape(printed) %]">
<input type="hidden" name="proforma" id="proforma" value="[% HTML.escape(proforma) %]">
<input type="hidden" name="queued" id="queued" value="[% HTML.escape(queued) %]">
<input type="hidden" name="saved_donumber" id="saved_donumber" value="[% HTML.escape(saved_donumber) %]">
[%- IF delivered %]
<div id="ui-tabs-basic-data">
<div class="wrapper" id="wrapper-1">
[% INCLUDE 'generic/toggle_wrapper.html' %]
<input type="hidden" name="follow_up_trans_id_1" id="follow_up_trans_id_1" value="[% HTML.escape(id) %]">
<input type="hidden" name="follow_up_trans_type_1" id="follow_up_trans_type_1" value="[% HTML.escape(type) %]">
<input type="hidden" name="follow_up_trans_info_1" id="follow_up_trans_info_1" value="[% HTML.escape(follow_up_trans_info) %]">
<input type="hidden" name="follow_up_rowcount" id="follow_up_rowcount" value="1">
<input type="hidden" name="business" id="business" value="[% HTML.escape(business) %]">
<input type="hidden" name="closed" id="closed" value="[% HTML.escape(closed) %]">
<input type="hidden" name="convert_from_oe_ids" id="convert_from_oe_ids" value="[% HTML.escape(convert_from_oe_ids) %]">
<input type="hidden" name="currency" id="currency" value="[% HTML.escape(currency) %]">
<input type="hidden" name="customer_pricegroup_id" id="customer_pricegroup_id" value="[% HTML.escape(customer_pricegroup_id) %]">
<input type="hidden" name="discount" id="discount" value="[% HTML.escape(discount) %]">
<input type="hidden" name="dunning_amount" id="dunning_amount" value="[% HTML.escape(dunning_amount) %]">
<input type="hidden" name="emailed" id="emailed" value="[% HTML.escape(emailed) %]">
<input type="hidden" name="id" id="id" value="[% HTML.escape(id) %]">
<input type="hidden" name="max_dunning_level" id="max_dunning_level" value="[% HTML.escape(max_dunning_level) %]">
<input type="hidden" name="printed" id="printed" value="[% HTML.escape(printed) %]">
<input type="hidden" name="proforma" id="proforma" value="[% HTML.escape(proforma) %]">
<input type="hidden" name="queued" id="queued" value="[% HTML.escape(queued) %]">
<input type="hidden" name="saved_donumber" id="saved_donumber" value="[% HTML.escape(saved_donumber) %]">
[% IF delivered %]
<input type="hidden" name="shipto_id" id="shipto_id" value="[% HTML.escape(shipto_id) %]">
<input type="hidden" name="shiptocity" id="shiptocity" value="[% HTML.escape(shiptocity) %]">
<input type="hidden" name="shiptocontact" id="shiptocontact" value="[% HTML.escape(shiptocontact) %]">
......
<input type="hidden" name="shiptostreet" id="shiptostreet" value="[% HTML.escape(shiptostreet) %]">
<input type="hidden" name="shiptozipcode" id="shiptozipcode" value="[% HTML.escape(shiptozipcode) %]">
<input type="hidden" name="shiptocp_gender" id="shiptocp_gender" value="[% HTML.escape(shiptocp_gender) %]">
[%- END %]
<input type="hidden" name="show_details" id="show_details" value="[% HTML.escape(show_details) %]">
<input type="hidden" name="taxincluded" id="taxincluded" value="[% HTML.escape(taxincluded) %]">
<input type="hidden" name="taxzone_id" id="taxzone_id" value="[% HTML.escape(taxzone_id) %]">
<input type="hidden" name="title" id="title" value="[% HTML.escape(title) %]">
<input type="hidden" name="type" id="type" value="[% HTML.escape(type) %]">
<input type="hidden" name="vc" id="vc" value="[% HTML.escape(vc) %]">
<input type="hidden" name="lastmtime" id="lastmtime" value="[% HTML.escape(lastmtime) %]">
<p>
<table width="100%">
<tr valign="top">
<td>
<table width="100%">
<tr>
<th align="right">[% IF is_customer %][% 'Customer' | $T8 %][% ELSE %][% 'Vendor' | $T8 %][% END %]</th>
<td>
[% IF RO %]
[% END %]
<input type="hidden" name="show_details" id="show_details" value="[% HTML.escape(show_details) %]">
<input type="hidden" name="taxincluded" id="taxincluded" value="[% HTML.escape(taxincluded) %]">
<input type="hidden" name="taxzone_id" id="taxzone_id" value="[% HTML.escape(taxzone_id) %]">
<input type="hidden" name="title" id="title" value="[% HTML.escape(title) %]">
<input type="hidden" name="type" id="type" value="[% HTML.escape(type) %]">
<input type="hidden" name="vc" id="vc" value="[% HTML.escape(vc) %]">
<input type="hidden" name="lastmtime" id="lastmtime" value="[% HTML.escape(lastmtime) %]">
<table class="tbl-horizontal col">
<caption>[% 'Customer & Order Information' | $T8 %]</caption>
<colgroup><col class="wi-mediumsmall"><col class="wi-wide"></colgroup>
<tbody>
<tr>
<th>[% IF is_customer %][% 'Customer' | $T8 %][% ELSE %][% 'Vendor' | $T8 %][% END %]</th>
<td class="wi-wide">
[% IF RO %]
[% P.hidden_tag(vc_id, $vc_id) %]
[% HTML.escape(VC_OBJ.name) %]
[% ELSE %]
[% P.customer_vendor.picker(vc_id, $vc_id, type=vc, class="fixed_width", onchange="\$('#update_button').click()") %]
[% END %]
[% P.hidden_tag("previous_" _ vc_id, $vc_id) %]
[% P.button_tag("show_vc_details('" _ HTML.escape(vc) _ "')", LxERP.t8("Details (one letter abbreviation)")) %]
</td>
[%- IF ALL_CONTACTS.size %]
<tr>
<th align="right">[% 'Contact Person' | $T8 %]</th>
<td>
[%- IF delivered %]
[% L.hidden_tag("cp_id", cp_id) %]
[% HTML.escape(CONTACT_OBJ.full_name) %][% IF CONTACT_OBJ.cp_abteilung %] ([% HTML.escape(CONTACT_OBJ.cp_abteilung) %])[% END %]
[%- ELSE %]
[% L.select_tag('cp_id', ALL_CONTACTS, default = cp_id, value_key = 'cp_id', title_key = 'full_name_dep', with_empty = 1, style='width: 250px') %]
[%- END %]
</td>
</tr>
[%- END %]
<tr>
<th align="right">[% 'Shipping Address' | $T8 %]</th>
<td>
[%- IF delivered %]
[% HTML.escape(shipto_label.join('; ')) %]
[%- ELSE %]
[%- IF ALL_SHIPTO.size %]
[% ELSE %]
[% P.customer_vendor.picker(vc_id, $vc_id, type=vc, class="wi-wide tooltipstered", onchange="\$('#update_button').click()", title=VC_OBJ.name ) %]
[% END %]
[% #P.button_tag("show_vc_details('" _ HTML.escape(vc) _ "')", LxERP.t8("Details (one letter abbreviation)"), class="wi-tiny neutral", title=LxERP.t8('Detailed information about this contact') ) %]
<a href="javascript:show_vc_details('[% HTML.escape(vc) %]');" title="[% 'Show detail informationen' | $T8 %]" class="button-image info"><img src="image/detail.png"></a>
[% P.hidden_tag("previous_" _ vc_id, $vc_id) %]
</td>
</tr>
[% IF ALL_CONTACTS.size %]
<tr>
<th>[% 'Contact Person' | $T8 %]</th>
<td>
[% IF delivered %]
<input type="hidden" name="cp_id" value="[% HTML.escape(cp_id) %]">
[% IF cp_id == row.cp_id %]
<span class="data wi-wide">[% HTML.escape(row.cp_name) %][% IF row.cp_abteilung %] ([% HTML.escape(row.cp_abteilung) %])[% END -%]</span>
[% END %]
[% ELSE %]
[% L.select_tag('cp_id', ALL_CONTACTS, default = cp_id, value_key = 'cp_id', title_key = 'full_name_dep', with_empty = 1, class='wi-wide') %]
[% END %]
</td>
</tr>
[% END %]
<tr>
<th>[% 'Shipping Address' | $T8 %]</th>
<td>
[% IF delivered %]
<span class="data wi-wide">[% HTML.escape(shipto_label.join('; ')) %]</span>
[% ELSE %]
[% IF ALL_SHIPTO.size %]
[% shiptos = [ [ "", LxERP.t8("No/individual shipping address") ] ] ;
L.select_tag('shipto_id', shiptos.import(ALL_SHIPTO), default=shipto_id, value_key='shipto_id', title_key='displayable_id', style='width: 250px') %]
[%- END %]
[% L.button_tag("kivi.SalesPurchase.edit_custom_shipto()", LxERP.t8("Custom shipto")) %]
[%- END %]
</td>
</tr>
[%- IF business %]
<tr>
<th align="right">[% IF is_customer %][% 'Customer type' | $T8 %][% ELSE %][% 'Vendor type' | $T8 %][% END %]</th>
<td>[% HTML.escape(business) %]</td>
</tr>
[%- END %]
[%- IF max_dunning_level %]
<tr>
<th align="right">[% 'Max. Dunning Level' | $T8 %]</th>
<td>
<b>[% HTML.escape(max_dunning_level) %]</b>; [% 'Dunning Amount' | $T8 %]:
L.select_tag('shipto_id', shiptos.import(ALL_SHIPTO), default=shipto_id, value_key='shipto_id', title_key='displayable_id', class='wi-wide') %]
[% END %]
[% L.button_tag("kivi.SalesPurchase.edit_custom_shipto()", LxERP.t8("Custom shipto"), class='button neutral below wi-wide') %]
[% END %]
</td>
</tr>
[% IF business %]
<tr>
<th>[% IF is_customer %][% 'Customer type' | $T8 %][% ELSE %][% 'Vendor type' | $T8 %][% END %]</th>
<td><span class="data wi-wide">[% HTML.escape(business) %]</span><!-- PENDENT: Behandlung von Text in Formular-Tabellen --> </td>
</tr>
[% END %]
[% IF max_dunning_level %]
<tr>
<th>[% 'Max. Dunning Level' | $T8 %]</th>
<td>
<b>[% HTML.escape(max_dunning_level) %]</b>, [% 'Dunning Amount' | $T8 %]:
<b>[% HTML.escape(LxERP.format_amount(dunning_amount, 2)) %]</b>
</td>
</tr>
[%- END %]
</tr>
[%- IF ALL_DEPARTMENTS.size %]
<tr>
<th align="right" nowrap>[% 'Department' | $T8 %]</th>
<td colspan="3">
</td>
</tr>
[% END %]
[% IF ALL_DEPARTMENTS.size %]
<tr>
<th>[% 'Department' | $T8 %]</th>
<td>
[% IF ( delivered ) %]
[% L.hidden_tag('department_id', department_id) %]
[% ELSE %]
[% L.select_tag('department_id', ALL_DEPARTMENTS, default = department_id, title_key = 'description', with_empty = 1, style = 'width: 250px', disabled = delivered )%]
[% L.select_tag('department_id', ALL_DEPARTMENTS, default = department_id, title_key = 'description', with_empty = 1, class='wi-wide', disabled = delivered )%]
[% END %]
</td>
</tr>
[%- END %]
<tr>
<th align="right">[% 'Shipping Point' | $T8 %]</th>
<td colspan="3"><input name="shippingpoint" size="35" value="[% HTML.escape(shippingpoint) %]"[% RO %]></td>
</tr>
<tr>
<th align="right">[% 'Ship via' | $T8 %]</th>
<td colspan="3"><input name="shipvia" size="35" value="[% HTML.escape(shipvia) %]"[% RO %]></td>
</tr>
<tr>
<th align="right">[% 'Transaction description' | $T8 %]</th>
<td colspan="3">[% L.input_tag("transaction_description", transaction_description, size=35, "data-validate"=(INSTANCE_CONF.get_require_transaction_description_ps ? 'required' : ''), readonly=delivered) %]</td>
</tr>
</table>
</td>
<td align="right">
<table>
<tr>
<td colspan="2" align="center">
[%- IF delivered %]
[%- IF is_customer %]
[% 'transferred out' | $T8 %]
[%- ELSE %]
[% 'transferred in' | $T8 %]
[%- END %]
[%- ELSE %]
[%- IF is_customer %]
[% 'not transferred out yet' | $T8 %]
[%- ELSE %]
[% 'not transferred in yet' | $T8 %]
[%- END %]
[%- END %]
;
[%- IF closed %]
[% 'Closed' | $T8 %]
[%- ELSE %]
[% 'Open' | $T8 %]
[%- END %]
</td>
</tr>
<input type="hidden" name="delivered" value="[% HTML.escape(delivered) %]">
<tr>
<th align="right">[% 'Employee' | $T8 %]</th>
<td>
[%- IF delivered %]
<input type="hidden" name="employee_id" value="[% HTML.escape(employee_id) %]">
[%- FOREACH row = ALL_EMPLOYEES %]
[% IF row.id == employee_id %][%- IF row.name %][%- HTML.escape(row.name) %][%- ELSE %][% HTML.escape(row.login) %][%- END %][% END %]
[%- END %]
[%- ELSE %]
[% L.select_tag('employee_id', ALL_EMPLOYEES, default = employee_id, title_key = 'safe_name') %]
[%- END %]
</td>
</tr>
[%- IF is_customer %]
[%- IF salesman_id %]
[%- SET the_salesman_id = salesman_id %]
[%- ELSE %]
[%- SET the_salesman_id = employee_id %]
[%- END %]
<tr>
<th align="right">[% 'Salesman' | $T8 %]</th>
<td>
[%- IF delivered %]
<input type="hidden" name="salesman_id" value="[% HTML.escape(salesman_id) %]">
[%- FOREACH row = ALL_SALESMEN %]
[% IF row.id == the_salesman_id %][%- IF row.name %][%- HTML.escape(row.name) %][%- ELSE %][% HTML.escape(row.login) %][%- END %][% END %]
[%- END %]
[%- ELSE %]
[% L.select_tag('salesman_id', ALL_SALESMEN, default = (salesman_id ? salesman_id : employee_id), title_key = 'safe_name') %]
[%- END %]
</td>
</tr>
[%- END %]
<tr>
<th width="70%" align="right" nowrap>[% 'Delivery Order Number' | $T8 %]</th>
<td><input name="donumber" id="donumber" size="11" value="[% HTML.escape(donumber) %]"[% RO %]></td>
</tr>
<tr>
<th width="70%" align="right" nowrap>[% 'Order Number' | $T8 %]</th>
<td><input name="ordnumber" id="ordnumber" size="11" value="[% HTML.escape(ordnumber) %]"[% RO %]></td>
</tr>
<tr>
<th width="70%" align="right" nowrap>[% IF is_customer %][% 'Customer Order Number' | $T8 %][% ELSE %][% 'Vendor Order Number' | $T8 %][% END %]</th>
<td><input name="cusordnumber" id="cusordnumber" size="11" value="[% HTML.escape(cusordnumber) %]"[% RO %]></td>
</tr>
<tr>
<th align="right" nowrap>[% 'Delivery Order Date' | $T8 %]</th>
<td nowrap>
[% L.date_tag('transdate', transdate, readonly => delivered) %]
</td>
</tr>
</tr>
[% END %]
<tr>
<th>[% 'Shipping Point' | $T8 %]</th>
<td><input type="text" name="shippingpoint" class="wi-wide" value="[% HTML.escape(shippingpoint) %]"[% RO %]></td>
</tr>
<tr>
<th>[% 'Ship via' | $T8 %]</th>
<td><input type="text" name="shipvia" class="wi-wide" value="[% HTML.escape(shipvia) %]"[% RO %]></td>
</tr>
<tr>
<th>[% 'Transaction description' | $T8 %]</th>
<td>[% L.input_tag("transaction_description", transaction_description, class="wi-wide tooltipstered", "data-validate"=(INSTANCE_CONF.get_require_transaction_description_ps ? 'required' : ''), readonly=delivered, title=transaction_description) %]</td>
</tr>
<tr>
<td colspan="2">
<span class="label above">[% 'Internal Notes' | $T8 %]</span>
[% IF delivered %][% SET RO=' readonly' %][% END %]
[% L.textarea_tag("notes", notes, wrap="soft", style="width: 350px; height: 150px", class="texteditor") %]
</td>
</tr>
</tbody>
</table>
<tr>
<th align="right" nowrap>[% 'Reqdate' | $T8 %]</th>
<td nowrap>
[% L.date_tag('reqdate', reqdate, readonly => delivered) %]
</td>
</tr>
[%- IF is_customer %]
<tr>
<th align="right" nowrap>[% 'Insert Date' | $T8 %]</th>
<td>[% insertdate %]</td>
</tr>
[%- END %]
<tr>
<th width="70%" align="right" nowrap>[% 'Project Number' | $T8 %]</th>
<table class="tbl-horizontal col">
<caption>[% 'Delivery Terms' | $T8 %]</caption>
<colgroup><col class="wi-wide"></colgroup>
<tbody>
<tr>
<td>[% L.select_tag('delivery_term_id', ALL_DELIVERY_TERMS, default=delivery_term_id, with_empty=1, title_key='description', class='wi-wide') %]</td>
</tr>
<tr>
<th class="caption"> [% 'Notes' | $T8 %] </th>
</tr>
<tr>
<td class="wi-wide">
[% IF delivered %]
[% L.hidden_tag("notes", notes) %]
<div class="fake-textarea fake-wi-wide">[% P.restricted_html(notes) %]</div>
[% ELSE %]
[% L.textarea_tag("notes", notes, wrap="soft", rows=3, cols=10, class="texteditor wi-wide") %]
[% END %]
</td>
</tr>
</tbody>
</table>
<table class="tbl-horizontal">
<caption>[% 'Status & Handling' | $T8 %]</caption>
<tbody>
<tr>
<th>[% 'Transfer Status' | $T8 %]</th>
<td>
<span class="data wi-normal">[% IF delivered %]
[% IF is_customer %]
[% 'transferred out' | $T8 %]
[% ELSE %]
[% 'transferred in' | $T8 %]
[% END %]
[% ELSE %]
[% IF is_customer %]
[% 'not transferred out yet' | $T8 %]
[% ELSE %]
[% 'not transferred in yet' | $T8 %]
[% END %]
[% END %]</span>
</td>
</tr>
<tr>
<th>[% 'Status' | $T8 %]</th>
<td>
<span class="data wi-normal">[% IF closed %][% 'Closed' | $T8 %][% ELSE %][% 'Open' | $T8 %][% END %]</span>
<input type="hidden" name="delivered" value="[% HTML.escape(delivered) %]">
</td>
</tr>
<tr>
<th>[% 'Employee' | $T8 %]</th>
<td>
[% IF delivered %]
<input type="hidden" name="employee_id" value="[% HTML.escape(employee_id) %]">
[% FOREACH row = ALL_EMPLOYEES %]
[% IF row.id == employee_id %]
[% IF row.name %]
<span class="data wi-normal">[% HTML.escape(row.name) %]</span>
[% ELSE %]
<span class="data wi-normal">[% HTML.escape(row.login) %]</span>
[% END %]
[% END %]
[% END %]
[% ELSE %]
[% L.select_tag('employee_id', ALL_EMPLOYEES, default = employee_id, title_key = 'safe_name', class='wi-normal') %]
[% END %]
</td>
</tr>
[% IF is_customer %]
[% IF salesman_id %]
[% SET the_salesman_id = salesman_id %]
[% ELSE %]
[% SET the_salesman_id = employee_id %]
[% END %]
<tr>
<th>[% 'Salesman' | $T8 %]</th>
<td>
[%- IF delivered %]
<input type="hidden" name="globalproject_id" value="[% HTML.escape(globalproject_id) %]">
[%- FOREACH row = ALL_PROJECTS %]
[% IF globalproject_id == row.id %][% HTML.escape(row.projectnumber) %][% END %]
[%- END %]
[%- ELSE %]
<select name="globalproject_id">
<option></option>
[%- FOREACH row = ALL_PROJECTS %]
<option value="[% HTML.escape(row.id) %]"[% IF globalproject_id == row.id %] selected[% END %]>[% HTML.escape(row.projectnumber) %]</option>
[%- END %]
</select>
[%- END %]
[% IF delivered %]
<input type="hidden" name="salesman_id" value="[% HTML.escape(salesman_id) %]">
[% FOREACH row = ALL_SALESMEN %]
[% IF row.id == the_salesman_id %]
[% IF row.name %]
<span class="data wi-normal">[% HTML.escape(row.name) %][% ELSE %][% HTML.escape(row.login) %]</span>
[% END %]
[% END %]
[% END %]
[% ELSE %]
[% L.select_tag('salesman_id', ALL_SALESMEN, default = (salesman_id ? salesman_id : employee_id), title_key = 'safe_name', class='wi-normal') %]
[% END %]
</td>
</tr>
</table>
</td>
</tr>
[% END %]
<tr>
<th class="caption" colspan="2">[% 'IDs & Dates' | $T8 %]</th>
</tr>
<tr>
<th>[% 'Delivery Order Number' | $T8 %]</th>
<td><input type="text" name="donumber" id="donumber" class="wi-mediumsmall" value="[% HTML.escape(donumber) %]"[% RO %]></td>
</tr>
<tr>
<th>[% 'Order Number' | $T8 %]</th>
<td><input type="text" name="ordnumber" id="ordnumber" class="wi-mediumsmall" value="[% HTML.escape(ordnumber) %]"[% RO %]></td>
</tr>
<tr>
<th>[% IF is_customer %][% 'Customer Order Number' | $T8 %][% ELSE %][% 'Vendor Order Number' | $T8 %][% END %]</th>
<td><input type="text" name="cusordnumber" id="cusordnumber" class="wi-mediumsmall" value="[% HTML.escape(cusordnumber) %]"[% RO %]></td>
</tr>
<tr>
<th>[% 'Project Number' | $T8 %]</th>
<td>
[% IF delivered %]
<input type="hidden" name="globalproject_id" value="[% HTML.escape(globalproject_id) %]">
[% FOREACH row = ALL_PROJECTS %]
[% IF globalproject_id == row.id %][% HTML.escape(row.projectnumber) %][% END %]
[% END %]
[% ELSE %]
<select name="globalproject_id" class="wi-mediumsmall">
<option></option>
[% FOREACH row = ALL_PROJECTS %]
<option value="[% HTML.escape(row.id) %]"[% IF globalproject_id == row.id %] selected[% END %]>[% HTML.escape(row.projectnumber) %]</option>
[% END %]
</select>
[% END %]
</td>
</tr>
<tr>
<th>[% 'Delivery Order Date' | $T8 %]</th>
<td> [% L.date_tag('transdate', transdate, readonly => delivered, class='wi-small') %] </td>
</tr>
<tr>
<th>[% 'Reqdate' | $T8 %]</th>
<td> [% L.date_tag('reqdate', reqdate, readonly => delivered, class='wi-small') %] </td>
</tr>
</table>
[% IF is_customer %]
<tr>
<th>[% 'Insert Date' | $T8 %]</th>
<td><span class="data wi-small">[% insertdate %]</span></td>
</tr>
[% END %]
</tbody>
</table>
</div><!-- /.wrapper -->

Auch abrufbar als: Unified diff