{{extend 'nmc/layout.html'}} {{block header}} {{=response.cmd_menu}} {{if form.formname!='trans/create':}}

{{=response.subtitle}}

{{=response.transnumber}}

{{else:}}

{{=response.subtitle}}

{{pass}} {{=response.cmd_commands}} {{end}} {{=response.active_page}}
{{=form.custom.begin}}
{{if response.transtype_name=="waybill":}} {{elif response.transtype_name in("production","formula"):}} {{if response.transtype_name =="production":}} {{else:}} {{pass}} {{else:}} {{pass}}
{{=response.state_ico}}
{{=form.custom.label.transnumber}}
{{=form.custom.widget.transnumber}}
{{=form.custom.label.direction}}
{{=form.custom.label.crdate}}
{{=form.custom.widget.direction}}{{=response.transdate}} {{=form.custom.widget.crdate}}{{=response.crdate}}

{{=T('Reference')}}
{{=response.reftype}}{{=response.refnumber_type}}
{{=response.trans_id}}{{=response.trans_transnumber}} {{=response.customer_id}}{{=response.customer_custname}} {{=response.employee_id}}{{=response.employee_empnumber}}
{{if not response.direction:}} {{pass}}
{{=response.transref_change}}
{{=form.custom.label.ref_transnumber}}
{{=response.trans_transnumber}}{{=response.ref_transnumber}}{{=response.trans_id}} {{=response.direction_id}}{{=response.cruser_id}}{{=response.transtype}}

{{=form.custom.label.crdate}}
{{=form.custom.label.transdate}}
{{=form.custom.widget.crdate}}{{=response.crdate}} {{=form.custom.widget.transdate}}
{{=form.custom.label.duedate}}
{{=form.custom.widget.duedate}}
{{=T("Formula")}}
{{=response.cmb_formula}}{{=response.production_id}}

{{=T("Product")}}
{{=response.production_product_selector}}{{=response.production_product_id}}
{{=response.trans_production_qty_label}}
{{=response.trans_production_qty_data}}
{{=response.trans_production_batch_label}}
{{=response.trans_production_batch_data}}
{{=form.custom.label.place_id}}
{{=response.production_place_selector}}{{=response.production_place_id}}
{{=form.custom.label.crdate}}
{{=response.trans_production_qty_label}}
{{=form.custom.widget.crdate}}{{=response.crdate}}{{=response.transdate}} {{=response.trans_production_qty_data}}
{{=T("Product")}}
{{=response.production_product_selector}}{{=response.production_product_id}}
{{if not response.direction:}} {{pass}}
{{=response.transref_change}}
{{=form.custom.label.ref_transnumber}}
{{=response.trans_transnumber}}{{=response.ref_transnumber}}{{=response.trans_id}} {{=response.direction_id}}{{=response.cruser_id}}{{=response.transtype}}

{{=form.custom.label.crdate}}
{{=form.custom.label.transdate}}
{{=form.custom.widget.crdate}}{{=response.crdate}} {{=form.custom.widget.transdate}}{{=response.transdate}}
{{=form.custom.label.place_id}}
{{=response.place_control}}{{=response.place_id}}

{{=form.custom.label.notes}}
{{=form.custom.label.transtate}}
{{=form.custom.widget.transtate}}
{{=form.custom.widget.notes}}
{{=form.custom.label.intnotes}}
{{=form.custom.widget.intnotes}}
{{=form.custom.end}}
{{if form.formname!='trans/create':}} {{pass}}
{{=response.cmd_back}} {{=response.cmd_close}}

{{=response.cmd_prev}} {{=response.cmd_next}}
{{=form.custom.submit}} {{if form.formname!='trans/create':}} {{=response.cmd_report}} {{if response.cmd_load_formula:}} {{=response.cmd_load_formula}} {{pass}} {{=response.cmd_more}} {{pass}}
{{if form.formname!='trans/create':}} {{pass}}
{{=response.menu_trans}} {{=response.menu_groups}} {{=response.menu_movement}} {{=response.menu_fields}}