~unifield-team/unifield-wm/us-826

« back to all changes in this revision

Viewing changes to sourcing/sourcing_view.xml

  • Committer: Matthieu Dietrich
  • Date: 2012-07-10 14:12:40 UTC
  • mfrom: (913 unifield-wm)
  • mto: This revision was merged to the branch mainline in revision 935.
  • Revision ID: mdietrich@chloups211-20120710141240-celi3o016fqz7mj1
UF-881: [MERGE] merged with trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
                        <field name="name">sale.order.form</field>
8
8
                        <field name="model">sale.order</field>
9
9
                        <field name="type">form</field>
 
10
                        <field name="priority">500</field>
10
11
                        <field name="inherit_id" ref="sale.view_order_form" />
11
12
                        <field name="arch" type="xml">
12
13
                                <data>
15
16
                                                <field name="supplier" invisible="True" />
16
17
                                                <field name="po_cft" invisible="True" />
17
18
                                        </field>
 
19
                                        
 
20
                                        <xpath expr="/form/notebook/page//button[@name='order_confirm']" position="replace">
 
21
                                                <button name="order_confirm" states="validated" string="Confirm Order" icon="gtk-apply" invisible="True" />
 
22
                        <button name="order_confirm_method" type="object" states="validated" string="Confirm Order" icon="gtk-apply"/>
 
23
                    </xpath>
18
24
 
19
25
                                </data>
20
26
                        </field>
44
50
                                        <field name="display_confirm_button" invisible="True" />
45
51
                                        <field name="procurement_request" invisible="True" />
46
52
                                        <field name="name" invisible="True" />
47
 
                                        <field name="sale_order_id" />
 
53
                                        <field name="sale_order_id" string="Order" />
48
54
                                        <field name="priority" />
49
55
                                        <field name="categ" />
50
56
                                        <field name="line_number" />
57
63
                                                attrs="{'invisible': [('display_confirm_button', '=', False)]}" />
58
64
                                        <field name="rts" />
59
65
                                        <field name="type" string="Proc. Method" on_change="onChangeType(type)" attrs="{'readonly': [('state', '!=', 'draft')]}" />
60
 
                                        <field name="po_cft" attrs="{'readonly': ['|', ('type', '=', 'make_to_stock'), ('state', '!=', 'draft')], 'required': [('type', '=', 'make_to_order')]}" />
 
66
                                        <field name="po_cft"
 
67
                                                on_change="onChangePoCft(po_cft, sale_order_id)" 
 
68
                                                attrs="{'readonly': ['|', ('type', '=', 'make_to_stock'), ('state', '!=', 'draft')], 'required': [('type', '=', 'make_to_order')]}" />
61
69
                                        <field name="real_stock" />
62
70
                                        <field name="available_stock" />
63
71
                                        <field name="virtual_stock" />
64
72
                                        <!-- do not work: attrs="{'readonly': ['|', '|', ('type', '=', 'make_to_stock'), '&amp;', ('type', '=', 'make_to_order'), ('po_cft', '=', 'cft'), ('state', '!=', 'draft')]}" -->
65
73
                                        <field name="company_id" invisible="1" />
66
74
                                        <field name="supplier" colspan="2"
67
 
                                                domain="[('id', '!=', company_id)]"
 
75
                                                domain="[('id', '!=', company_id), ('available_for_dpo', '=', po_cft)]"
68
76
                                                context="{'product_id': product_id, 'choose_supplier': True}"
69
77
                                                attrs="{'readonly': ['|', ('type', '=', 'make_to_stock'), ('state', '!=', 'draft')]}"
70
78
                                                on_change="onChangeSupplier(supplier)" />
88
96
                                        <filter name="need_sourcing" string="Need Sourcing" icon="terp-stock_zoom" domain="[('need_sourcing', '=', True)]" />
89
97
                                        <filter name="sourced" string="Sourced" icon="terp-camera_test" domain="['&amp;', '|', ('state', '!=', 'draft'), ('procurement_request', '=', True), '|', ('sale_order_state', '!=', 'progress'), ('procurement_request', '=', False)]" />
90
98
                                        <separator orientation="vertical"/>
91
 
                                        <field name="sale_order_id" />
 
99
                                        <field name="sale_order_id" string="Order" />
92
100
                                        <field name="priority" />
93
101
                                        <field name="categ" />
94
102
                                        <field name="sale_order_state_search" />