16
16
<group colspan="4" col="4">
17
17
<separator colspan="4" string="Selected lines to source" />
18
<field name="line_ids" nolabel="1" colspan="4">
19
<tree string="Lines to source" hide_new_button="True" noteditable="True">
20
<field name="order_id" string="Order reference" />
21
<field name="line_number" />
22
<field name="product_id" />
23
<field name="product_uom_qty" />
24
<field name="product_uom" />
25
<field name="real_stock" />
26
<field name="available_stock" />
27
<field name="virtual_stock" />
18
<field name="line_ids" nolabel="1" colspan="4" />
30
19
<separator colspan="4" string="Procurement method" />
32
on_change="change_type(type, line_ids)"/>
21
on_change="change_type(type)"/>
33
22
<field name="po_cft" attrs="{'readonly': [('type', '=', 'make_to_stock')]}"
34
23
on_change="change_po_cft(po_cft)"/>
35
24
<separator colspan="4" string="Supplier selection" />
36
<field name="supplier"
25
<field name="supplier_id"
37
26
domain="[('id', '!=', company_id), ('available_for_dpo', '=', po_cft), ('line_contains_fo', '=', line_ids)]"
38
27
attrs="{'readonly': ['|', ('po_cft', '=', 'cft'), ('type', '=', 'make_to_stock')]}"
39
on_change="change_supplier(supplier)"
28
on_change="change_supplier(supplier_id)"
43
32
<field name="location_id" domain="[('usage', '=', 'internal'), ('quarantine_location', '=', False),
44
33
('scrap_location', '=', False), ('destruction_location', '=', False),
45
34
('output_ok', '=', False), ('input_ok', '=', False)]"
46
attrs="{'readonly': [('type', '!=', 'make_to_stock')]}"
35
attrs="{'readonly': [('type', '!=', 'make_to_stock')]}"
47
36
on_change="change_location(location_id, line_ids)" />
59
48
<record id="sourcing_line_special_tree_view" model="ir.ui.view">
60
49
<field name="name">sourcing.line.special.tree.view</field>
61
50
<field name="model">sale.order.line</field>
62
<field name="type">form</field>
63
<field name="priority" eval="5000" />
51
<field name="type">tree</field>
52
<field name="priority" eval="10" />
64
53
<field name="arch" type="xml">
65
54
<tree string="Lines to source" hide_new_button="True" noteditable="True">
66
55
<field name="order_id" string="Order reference" />