~unifield-team/unifield-wm/us-671-homere

« back to all changes in this revision

Viewing changes to consumption_calculation/consumption_view.xml

  • Committer: jf
  • Date: 2012-04-17 15:29:16 UTC
  • mfrom: (631.3.7 UF_828)
  • Revision ID: jf@tempo4-20120417152916-svm6ioq8ur2bi5tu
UF-955 [DEV] Reporting (Month-end) - 2 remaining reports
lp:~unifield-team/unifield-wm/UF_955

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
            <field name="type">form</field>
9
9
            <field name="arch" type="xml">
10
10
                <form string="Real consumption reporting">
11
 
                    <group colspan="4" col="6">
12
 
                        <field name="id" invisible="1" />
13
 
                        <separator colspan="6" string="General information" />
14
 
                        <field name="name" readonly="1" colspan="3" />
15
 
                        <field name="creation_date" attrs="{'readonly': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}" colspan="2"/>
16
 
                        <field name="cons_location_id" attrs="{'readonly': ['|', '|', ('state', '=', 'cancel'), ('id', '!=', 0), ('created_ok', '=', True)]}" context="{'no3buttons': True}" colspan="2"/>
17
 
                        <button name="change_cons_location_id" string="Change location" icon="gtk-preferences" type="object" attrs="{'readonly': ['|', '|', ('state', '=', 'cancel'), ('id', '=', 0), ('created_ok', '=', True)]}" />
18
 
                        <group colspan="3" col="2">
19
 
                            <field name="picking_id" attrs="{'invisible': [('created_ok', '=', False)]}" />
20
 
                            <button name="import_rac" colspan="2" string="Import a file" icon="gtk-leave-fullscreen" type="object" attrs="{'invisible': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}"/>
21
 
                        </group>
22
 
                        <field name="activity_id" attrs="{'readonly': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}" colspan="3"/>
23
 
                        <button name="export_rac" colspan="3" string="Export lines" icon="terp-mail-forward" type="object" />
24
 
                        <separator colspan="6" string="Period of consumption" />
25
 
                        <field name="period_from" attrs="{'readonly': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}" colspan="3"/>
26
 
                        <field name="period_to" attrs="{'readonly': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}" colspan="3"/>
27
 
                        <group colspan="6" col="6" name="import" string="Import lines" attrs="{'invisible': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}">
28
 
                            <button name="add_multiple_lines" string="Add multiple lines" type="object" icon="gtk-add" colspan="3" />
29
 
                            <button name="button_remove_lines" string="Delete Lines" icon="gtk-remove" colspan="3" type="object" />
30
 
                        </group>
31
 
                    </group>
 
11
                    <separator colspan="4" string="General information" />
 
12
                    <field name="name" readonly="1" />
 
13
                    <field name="creation_date" attrs="{'readonly': [('created_ok', '=', True)]}"/>
 
14
                    <field name="cons_location_id" attrs="{'readonly': [('created_ok', '=', True)]}" context="{'no3buttons': True}"/>
 
15
                    <group colspan="2" col="2">
 
16
                        <field name="picking_id" attrs="{'invisible': [('created_ok', '=', False)]}" />
 
17
                        <button name="import_rac" colspan="2" string="Import a file" icon="gtk-leave-fullscreen" type="object" attrs="{'invisible': [('created_ok', '=', True)]}"/>
 
18
                    </group>
 
19
                    <field name="activity_id" attrs="{'readonly': [('created_ok', '=', True)]}"/>
 
20
                    <button name="export_rac" colspan="2" string="Export lines" icon="terp-mail-forward" type="object" />
 
21
                    <separator colspan="4" string="Period of consumption" />
 
22
                    <field name="period_from" attrs="{'readonly': [('created_ok', '=', True)]}"/>
 
23
                    <field name="period_to" attrs="{'readonly': [('created_ok', '=', True)]}"/>
 
24
                    <separator colspan="4" string="Product filters" />
 
25
                    <field name="sublist_id" attrs="{'readonly': ['|',('created_ok', '=', True), ('nomen_manda_0', '!=', False)]}"/>
 
26
 
 
27
                    <group colspan="2" col="4" attrs="{'readonly': [('sublist_id', '!=', False)]}">
 
28
                        <field name="nomen_manda_0"
 
29
                            domain="[('level', '=', '0'), ('type', '=', 'mandatory')]"
 
30
                            widget="selection"
 
31
                            on_change="onChangeSearchNomenclature(0, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
32
                        />
 
33
                        <field name="nomen_manda_1"
 
34
                            domain="[('id','=', 0)]"
 
35
                            widget="selection"
 
36
                            get_selection="get_nomen"
 
37
                            on_change="onChangeSearchNomenclature(1, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
38
                        />
 
39
                        <field name="nomen_manda_2"
 
40
                            domain="[('id','=', 0)]"
 
41
                            widget="selection"
 
42
                            get_selection="get_nomen"
 
43
                            on_change="onChangeSearchNomenclature(2, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
44
                        />
 
45
                        <field name="nomen_manda_3"
 
46
                            domain="[('id','=', 0)]"
 
47
                            widget="selection"
 
48
                            get_selection="get_nomen"
 
49
                            on_change="onChangeSearchNomenclature(3, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
50
                        />
 
51
                    </group>
 
52
 
 
53
                    <button colspan="4" icon="gtk-go-down" string="Fill lines" type="object" name="fill_lines" attrs="{'invisible': [('created_ok', '=', True)]}" />
32
54
                    <separator colspan="4" string="Products" />
33
 
                    <button name="button_remove_lines" string="Remove lines" icon="gtk-remove" type="object" 
34
 
                    confirm="Are you sure that you want to remove all lines?" invisible="1"/>
35
 
                    <button colspan="4" icon="gtk-go-down" string="Copy all" type="object" name="copy_all" attrs="{'invisible': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}" />
36
 
                    <field name="hide_column_error_ok" invisible="1" />
37
 
                    <field colspan="4" name="line_ids" mode="tree" nolabel="1" widget="one2many_list" attrs="{'readonly': ['|', ('state', '=', 'cancel'), ('created_ok', '=', True)]}"
38
 
                    context="{'hide_column_error_ok': hide_column_error_ok, 'active_id': active_id}">
39
 
                        <tree string="Products" editable="top" colors="red: consumed_qty>0 and (inactive_product or to_correct_ok or consumed_qty > product_qty or (batch_mandatory and not prodlot_id) or (date_mandatory and not expiry_date));blue: not prodlot_id and consumed_qty>product_qty and not to_correct_ok and not inactive_product">
 
55
                    <field colspan="4" name="line_ids" mode="tree" nolabel="1" widget="one2many_list" attrs="{'readonly': [('created_ok', '=', True)]}">
 
56
                        <tree string="Products" editable="top" colors="red:prodlot_id and consumed_qty>product_qty or not prodlot_id and batch_mandatory;blue: not prodlot_id and consumed_qty>product_qty">
40
57
                            <field name="product_id" on_change="product_onchange(product_id, parent.cons_location_id, uom_id, prodlot_id)"
41
 
                                context="{'location': parent.cons_location_id, 'compute_child': False, 'available_for_restriction': 'consumption', 'search_default_not_restricted': 1}" />
42
 
                            <!-- domain="[('list_ids', '=', parent.sublist_id)]" /> -->
 
58
                                context="{'location': parent.cons_location_id, 'compute_child': False}"
 
59
                                domain="[('list_ids', '=', parent.sublist_id)]" />
43
60
                            <field name="uom_id" 
44
 
                                on_change="uom_onchange(product_id, consumed_qty, parent.cons_location_id, uom_id, prodlot_id)"/>
 
61
                                on_change="uom_onchange(product_id, parent.cons_location_id, uom_id, prodlot_id)"/>
45
62
                            <field name="product_qty" />
46
63
                            <field name="prodlot_id" 
47
 
                                on_change="change_prodlot(product_id, prodlot_id, expiry_date, parent.cons_location_id, uom_id, remark)"
 
64
                                on_change="change_prodlot(product_id, prodlot_id, expiry_date, parent.cons_location_id, uom_id)"
48
65
                                domain="[('product_id', '=', product_id), ('stock_available', '>', 0)]"
49
 
                                context="{'location_id': parent.cons_location_id, 'uom': uom_id, 'hidden_perishable_mandatory': not batch_mandatory}"
50
 
                                attrs="{'required': [('batch_mandatory', '=', True)], 'readonly': [('date_mandatory', '=', False), ('batch_mandatory', '=', False)]}" />
 
66
                                context="{'location_id': parent.cons_location_id, 'uom': uom_id, 'hidden_perishable_mandatory': date_mandatory}"
 
67
                                attrs="{'required': [('batch_mandatory', '=', True)], 'readonly': [('batch_mandatory', '=', False)]}" />
51
68
                            <field name="expiry_date"
52
 
                                on_change="change_expiry(expiry_date, product_id, parent.cons_location_id, uom_id, remark)"
53
 
                                attrs="{'required': [('date_mandatory', '=', True), ('batch_mandatory', '=', False)], 'readonly': ['|', ('batch_mandatory', '=', True), ('date_mandatory', '=', False)]}"/>
54
 
                            <field name="asset_id"
55
 
                                attrs="{'required': [('asset_mandatory', '=', True)], 'readonly': [('asset_mandatory', '=', False)]}"
56
 
                                on_change="change_asset(asset_id, product_id, parent.cons_location_id, uom_id, remark)"
57
 
                                domain="[('product_id', '=', product_id)]" />
 
69
                                on_change="change_expiry(expiry_date, product_id, parent.cons_location_id, uom_id)"
 
70
                                attrs="{'required': [('date_mandatory', '=', True)], 'readonly': [('date_mandatory', '=', False)]}"/>
58
71
                            <field name="consumed_qty" on_change="change_qty(consumed_qty, product_id, prodlot_id, parent.cons_location_id, uom_id)"/>
59
 
                            <field name="move_id" invisible="1" />
60
 
                            <button string="Duplicate line" icon="terp-stock_effects-object-colorize" name="copy" type="object" attrs="{'invisible': [('move_id', '!=', False)]}" />
61
 
                            <field name="remark" invisible="1" />
62
 
                            <field name="batch_mandatory" invisible="0" string="B.Num" readonly="1" />
63
 
                            <field name="date_mandatory" invisible="0" string="Exp" readonly="1" />
64
 
                            <field name="asset_mandatory" invisible="0" string="Asset" readonly="1" />
65
 
                            <field name="to_correct_ok" invisible="1"/>
66
 
                            <field name="text_error" invisible="context.get('hide_column_error_ok', False) != True" />
67
 
                            <field name="inactive_product" invisible="1" />
68
 
                            <field name="inactive_error" readonly="1" />
 
72
                            <field name="remark" />
 
73
                            <field name="batch_mandatory" invisible="1" />
 
74
                            <field name="date_mandatory" invisible="1" />
69
75
                        </tree>
70
76
                    </field>
71
77
                    <field name="created_ok" invisible="1" />
72
 
                    <group colspan="4" col="6">
73
 
                        <button name="button_update_stock" string="Update Indicative Stock" icon="gtk-refresh" colspan="2" type="object" attrs="{'invisible': [('state','!=','draft')]}" />
74
 
                        <button name="cancel_button" string="Cancel" icon="gtk-cancel" type="object" colspan="2" attrs="{'invisible': [('state', '!=', 'draft')]}" />
75
 
                        <button name="process_moves" string="Save &amp; Process" icon="gtk-execute" type="object" colspan="2" attrs="{'invisible': [('state','!=','draft')]}" />
76
 
                        <button name="draft_button" string="Draft" icon="gtk-apply" type="object" colspan="2" attrs="{'invisible': [('state', '!=', 'cancel')]}" />
77
 
                    </group>
78
 
                    <group colspan="4" >
79
 
                        <field name="state" />
80
 
                    </group>
 
78
                    <button name="button_update_stock" string="Update Indicative Stock" icon="gtk-refresh" colspan="2" type="object" attrs="{'invisible': [('created_ok', '=', True)]}" />
 
79
                    <button name="save_and_process" string="Save &amp; Process" icon="gtk-execute" type="object" colspan="2" attrs="{'invisible': [('created_ok', '=', True)]}" />
81
80
                </form>
82
81
            </field>
83
82
        </record>
84
 
      
 
83
        
85
84
        <record id="real_average_consumption_confirmation_view" model="ir.ui.view">
86
85
            <field name="name">real.average.consumption.confirmation.view</field>
87
86
            <field name="model">real.average.consumption</field>
89
88
            <field name="priority" eval="99" />
90
89
            <field name="arch" type="xml">
91
90
                <form string="Need confirmation">
 
91
                    <separator colspan="4" string="Need confirmation" />
 
92
                    <field name="valid_ok" />
92
93
                    <separator colspan="4" string="Actions" />
93
94
                    <button name="process_moves" string="Process moves" icon="gtk-execute" type="object" colspan="2" />
94
95
                </form>
101
102
            <field name="type">tree</field>
102
103
            <field name="arch" type="xml">
103
104
                <tree string="Real consumption reports">
104
 
            <field name="name" />
 
105
                    <field name="name" />
105
106
                    <field name="cons_location_id" />
106
107
                    <field name="activity_id" />
107
108
                    <field name="period_from" />
108
109
                    <field name="period_to" />
109
110
                    <field name="nb_lines" />
110
111
                    <field name="created_ok" />
111
 
            <field name="state" />
112
112
                    <field name="sublist_id" invisible="1" />
113
113
                    <field name="nomen_manda_0" invisible="1" />
114
114
                    <field name="nomen_manda_1" invisible="1" />
125
125
            <field name="arch" type="xml">
126
126
                <search string="Real consumption reports">
127
127
                    <group col="10" colspan="4">
128
 
                        <filter icon="terp-check" string="Closed" domain="[('created_ok','=',True)]"/>
 
128
                        <filter icon="terp-check" string="Moves created" domain="[('created_ok','=',True)]"/>
129
129
                        <separator orientation="vertical"/>
130
130
                        <field name="cons_location_id"/>
131
131
                        <field name="activity_id"/>
134
134
                    </group>
135
135
                    <newline/>
136
136
                    <group expand="0" string="Group By...">
137
 
                        <filter string="Consumer" icon="terp-stock" domain="[]" context="{'group_by': 'cons_location_id'}" />
138
 
                        <filter string="Activity" icon="terp-administration" domain="[]" context="{'group_by':'activity_id'}"/>
 
137
                        <filter string="Consumer" icon="terp-stock" domain="" context="{'group_by': 'cons_location_id'}" />
 
138
                        <filter string="Activity" icon="terp-administration" domain="" context="{'group_by':'activity_id'}"/>
139
139
                        <separator orientation="vertical"/>
140
 
                        <filter string="Sublist" icon="terp-go-week" domain="[]" context="{'group_by':'sublist_id'}"/>
141
 
                        <filter string="Main type" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_0'}"/>
142
 
                        <filter string="Group" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_1'}"/>
143
 
                        <filter string="Family" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_2'}"/>
144
 
                        <filter string="Root" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_3'}"/>
 
140
                        <filter string="Sublist" icon="terp-go-week" domain="" context="{'group_by':'sublist_id'}"/>
 
141
                        <filter string="Main type" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_0'}"/>
 
142
                        <filter string="Group" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_1'}"/>
 
143
                        <filter string="Family" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_2'}"/>
 
144
                        <filter string="Root" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_3'}"/>
145
145
                    </group>
146
146
                </search>
147
147
            </field>
148
148
        </record>
149
149
        
150
150
        <record id="action_real_average_consumption" model="ir.actions.act_window">
151
 
            <field name="name">Real consumption</field>
 
151
            <field name="name">Real consumption reports</field>
152
152
            <field name="res_model">real.average.consumption</field>
153
153
            <field name="view_type">form</field>
154
154
            <field name="view_mode">tree,form</field>
165
165
        
166
166
        <menuitem
167
167
             id="warehouse_consumption_menu"
168
 
             name="Consumption reports"
 
168
             name="Consumption"
169
169
             sequence="-20"
170
170
             parent="stock.next_id_61" />
171
171
             
174
174
            action="action_real_average_consumption"
175
175
            parent="warehouse_consumption_menu" />
176
176
          
 
177
        <!-- <menuitem
 
178
            id="new_consumption_reports_menu"
 
179
            action="action_new_real_consumption_report"
 
180
            parent="warehouse_consumption_menu" /> -->
 
181
            
 
182
            
177
183
        <record id="monthly_review_consumption_form_view" model="ir.ui.view">
178
184
            <field name="name">monthly.review.consumption.form.view</field>
179
185
            <field name="model">monthly.review.consumption</field>
182
188
                <form string="Monthly consumption">
183
189
                    <separator colspan="4" string="General information" />
184
190
                    <field name="period_from" on_change="period_change(period_from, period_to)" />
185
 
                    <!-- uf-1344 => we replace the import export of csv by import export of xml file (Excel compatibility). (see msf_doc_import) -->
186
191
                    <button name="import_fmc" string="Import a file" icon="gtk-leave-fullscreen" type="object" colspan="2" />
187
192
                    <field name="period_to" on_change="period_change(period_from, period_to)" />
188
 
                    <!-- uf-1344 => we replace the import export of csv by import export of xml file (Excel compatibility). (see msf_doc_import) -->
189
193
                    <button name="export_fmc" string="Export lines" icon="terp-mail-forward" type="object" colspan="2" />
190
194
                    <field name="cons_location_id" />
191
195
                    <newline />
 
196
                    <field name="sublist_id" attrs="{'readonly': [('nomen_manda_0', '!=', False)]}"/>
 
197
                    <group colspan="2" col="4" attrs="{'readonly': [('sublist_id', '!=', False)]}">
 
198
                        <field name="nomen_manda_0"
 
199
                            domain="[('level', '=', '0'), ('type', '=', 'mandatory')]"
 
200
                            widget="selection"
 
201
                            on_change="onChangeSearchNomenclature(0, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
202
                        />
 
203
                        <field name="nomen_manda_1"
 
204
                            domain="[('id','=', 0)]"
 
205
                            widget="selection"
 
206
                            get_selection="get_nomen"
 
207
                            on_change="onChangeSearchNomenclature(1, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
208
                        />
 
209
                        <field name="nomen_manda_2"
 
210
                            domain="[('id','=', 0)]"
 
211
                            widget="selection"
 
212
                            get_selection="get_nomen"
 
213
                            on_change="onChangeSearchNomenclature(2, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
214
                        />
 
215
                        <field name="nomen_manda_3"
 
216
                            domain="[('id','=', 0)]"
 
217
                            widget="selection"
 
218
                            get_selection="get_nomen"
 
219
                            on_change="onChangeSearchNomenclature(3, 'mandatory', nomen_manda_0, nomen_manda_1, nomen_manda_2, nomen_manda_3, False)"
 
220
                        />
 
221
                    </group>
 
222
                    <button colspan="4" icon="gtk-go-down" string="Fill lines" type="object" name="fill_lines" />
192
223
                    <separator colspan="4" string="Products" />
193
 
                    <group colspan="4" col="6" name="import" string="Import lines">
194
 
                        <button name="add_multiple_lines" string="Add multiple lines" type="object" icon="gtk-add" colspan="2" />
195
 
                        <button name="button_remove_lines" string="Delete Lines" icon="gtk-remove" colspan="2" type="object" />
196
 
                    </group>
197
 
                    <button name="button_remove_lines" string="Remove lines" icon="gtk-remove" type="object"
198
 
                    confirm="Are you sure that you want to remove all lines?" invisible="1"/>
199
 
                    <field name="hide_column_error_ok" invisible="1" />
200
 
                    <field colspan="4" name="line_ids" mode="tree" nolabel="1" widget="one2many_list"
201
 
                    context="{'hide_column_error_ok': hide_column_error_ok, 'active_id': active_id}">
202
 
                        <tree string="Products" editable="top" colors="red: to_correct_ok==True"> 
203
 
                            <field name="name" on_change="product_onchange(name, parent.id, parent.period_from, parent.period_to)" />
 
224
                    <field colspan="4" name="line_ids" mode="tree" nolabel="1" widget="one2many_list">
 
225
                        <tree string="Products" editable="top"> 
 
226
                            <field name="name" on_change="product_onchange(name, parent.id, parent.period_from, parent.period_to)" 
 
227
                                domain="[('list_ids', '=', parent.sublist_id)]" />
204
228
                            <field name="amc" />
205
229
                            <field name="fmc" on_change="fmc_change(amc, fmc, name)" attrs="{'readonly': [('valid_ok', '=', True)]}" />
206
 
                            <field name="security_stock" />
207
230
                            <field name="last_reviewed" />
208
231
                            <field name="valid_ok" />
209
232
                            <field name="valid_until" />
210
 
                            <field name="fmc2" invisible="1" />
211
 
                            <field name="last_reviewed2" invisible="1" />
 
233
                            <field name="fmc2" invisible="1" />
 
234
                            <field name="last_reviewed2" invisible="1" />
 
235
                            <!--<button name="valid_line" type="object" string="Valid line" icon="gtk-execute" attrs="{'invisible': [('valid_ok', '=', True)]}" />-->
212
236
                            <button name="display_graph" type="object" string="Display graph" icon="terp-purchase" />
213
 
                            <field name="to_correct_ok" invisible="1"/>
214
 
                            <field name="text_error" invisible="context.get('hide_column_error_ok', False) != True" />
215
237
                        </tree>
216
238
                    </field>
217
239
                    <button colspan="4" icon="gtk-execute" string="Valid all lines" type="object" name="valid_multiple_lines" />
243
265
            <field name="type">search</field>
244
266
            <field name="arch" type="xml">
245
267
                <search string="Monthly consumption">
246
 
                    <group col="10" colspan="4">
 
268
                        <group col="10" colspan="4">
247
269
                        <field name="period_from"/>
248
270
                        <field name="period_to"/>
249
271
                    </group>
250
272
                    <newline/>
251
273
                    <group expand="0" string="Group By...">
252
 
                        <filter string="Sublist" icon="terp-go-week" domain="[]" context="{'group_by':'sublist_id'}"/>
253
 
                        <filter string="Main type" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_0'}"/>
254
 
                        <filter string="Group" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_1'}"/>
255
 
                        <filter string="Family" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_2'}"/>
256
 
                        <filter string="Root" icon="terp-tools" domain="[]" context="{'group_by':'nomen_manda_3'}"/>
 
274
                        <filter string="Sublist" icon="terp-go-week" domain="" context="{'group_by':'sublist_id'}"/>
 
275
                        <filter string="Main type" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_0'}"/>
 
276
                        <filter string="Group" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_1'}"/>
 
277
                        <filter string="Family" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_2'}"/>
 
278
                        <filter string="Root" icon="terp-tools" domain="" context="{'group_by':'nomen_manda_3'}"/>
257
279
                    </group>
258
280
                </search>
259
281
            </field>
260
282
        </record>
261
283
        
262
284
        <record id="action_monthly_review_consumption" model="ir.actions.act_window">
263
 
            <field name="name">Monthly consumption</field>
 
285
            <field name="name">Monthly consumptions</field>
264
286
            <field name="res_model">monthly.review.consumption</field>
265
287
            <field name="view_type">form</field>
266
288
            <field name="view_mode">tree,form</field>
280
302
            action="action_monthly_review_consumption"
281
303
            parent="warehouse_consumption_menu" />
282
304
          
 
305
        <!-- <menuitem
 
306
            id="new_consumption_monthly_review_menu"
 
307
            action="action_new_monthly_review_consumption"
 
308
            parent="warehouse_consumption_menu" /> -->
 
309
            
283
310
        <record id="monthly_cons_product_form_view" model="ir.ui.view">
284
311
            <field name="name">monthlu.cons.product.form.view</field>
285
312
            <field name="model">product.product</field>
318
345
                </search>
319
346
            </field>
320
347
        </record>
321
 
 
322
 
    <!-- REAL AVERAGE CONSUMPTION -->
323
 
        <report
324
 
            id="report_real_consumption_xls"
325
 
            string="Real Consumption Excel Export"
326
 
            model="real.average.consumption"
327
 
            name="real.consumption.xls"
328
 
            file="consumption_calculation/report/report_real_consumption_xls.mako"
329
 
            report_type="webkit"
330
 
            header="False"
331
 
            auto="False"
332
 
            menu="False"
333
 
            />
334
 
 
335
 
    <!-- MONTHLY REVIEW CONSUMPTION -->
336
 
        <report
337
 
            id="report_monthly_consumption_xls"
338
 
            string="Monthly Consumption Excel Export"
339
 
            model="monthly.review.consumption"
340
 
            name="monthly.consumption.xls"
341
 
            file="consumption_calculation/report/report_monthly_consumption_xls.mako"
342
 
            report_type="webkit"
343
 
            header="False"
344
 
            auto="False"
345
 
            menu="False"
346
 
            />
347
 
 
348
 
        <!-- INCOMING SHIPMENT CONSUMPTION EXPORT -->
349
 
        <report
350
 
            id="report_incoming_consumption_xls"
351
 
            string="XML Export"
352
 
            model="stock.picking"
353
 
            name="incoming.consumption.xls"
354
 
            file="consumption_calculation/report/report_incoming_consumption_xls.mako"
355
 
            report_type="webkit"
356
 
            header="False"
357
 
            auto="False"
358
 
            menu="False"
359
 
        />
360
 
 
361
 
 
362
 
        <record id="action_incoming_print_xml_export" model="ir.actions.server">
363
 
            <field name="name">XML Export</field>
364
 
            <field name="model_id" ref="model_wizard_incoming_xml_export" />
365
 
            <field name="state">code</field>
366
 
            <field name="code">action = obj.print_report(context=context)</field>
367
 
        </record>
368
 
 
369
 
        <record id="ir_print_incoming_xml_export" model="ir.values">
370
 
            <field name="key2">client_print_multi</field>
371
 
            <field name="model">stock.picking</field>
372
 
            <field name="name">XML Export</field>
373
 
            <field eval="'ir.actions.server,%d'%action_incoming_print_xml_export" name="value" />
374
 
            <field eval="True" name="object" />
375
 
        </record>
376
 
 
377
 
        <record id="view_real_consumption_change_location" model="ir.ui.view">
378
 
            <field name="name">real.consumption.change.location.form.view</field>
379
 
            <field name="model">real.consumption.change.location</field>
380
 
            <field name="type">form</field>
381
 
            <field name="arch" type="xml">
382
 
                <form string="Change location">
383
 
                    <separator colspan="4" string="New location" />
384
 
                    <label colspan="4" string="Are you sure you want to change the consumer location ? It will change the indicative stock, so please check the report lines before validating" />
385
 
                    <label colspan="4" string=" "/>
386
 
                    <field name="location_id" required="1" domain="[('usage', '=', 'internal')]" />
387
 
                    <separator colspan="4" string="Actions" />
388
 
                    <label colspan="2"> </label>
389
 
                    <button special="cancel" string="Cancel" icon="gtk-cancel" />
390
 
                    <button name="change_location" string="Change location" type="object" icon="gtk-preferences" />
391
 
                </form>
392
 
            </field>
393
 
        </record>
394
 
 
395
348
    </data>
396
349
</openerp>