1
<?xml version="1.0" encoding="utf-8"?>
4
<!ENTITY general SYSTEM "mcdb_view_general.xml">
5
<!ENTITY account SYSTEM "mcdb_view_account.xml">
6
<!ENTITY currency SYSTEM "mcdb_view_currency.xml">
7
<!ENTITY end SYSTEM "mcdb_view_end.xml">
13
<!-- Account Multi-Criteria Data Browser Form -->
14
<record model="ir.ui.view" id="account_mcdb_form">
15
<field name="name">account.mcdb.form</field>
16
<field name="model">account.mcdb</field>
17
<field name="type">form</field>
18
<field name="arch" type="xml">
19
<form string="Selector - G/L" hide_new_button="1" hide_duplicate_button="1" hide_delete_button="1">
21
<group col="4" colspan="4">
22
<group col="2" colspan="2">
23
<group col="4" colspan="2">
24
<separator string="G/L journals" colspan="3"/>
25
<field name="display_journal" colspan="1" nolabel="1"/>
27
<group col="2" colspan="2" attrs="{'invisible': [('display_journal', '=', False)]}">
28
<group col="2" colspan="2">
29
<button name="button_journal_clear" type="object" string="Remove all Journals" icon="gtk-clear" colspan="1"/>
30
<button name="button_journal_add" type="object" string="Add all Journals" icon="gtk-add" colspan="1"/>
32
<field name="rev_journal_ids" colspan="2"/>
33
<field name="journal_ids" colspan="2" nolabel="1">
34
<tree string="Journals" editable="top" noteditable="1">
36
<field name="name" string="Name"/>
42
<group col="2" colspan="2">
43
<group col="4" colspan="2">
44
<separator string="Periods" colspan="3"/>
45
<field name="display_period" colspan="1" nolabel="1"/>
47
<group col="2" colspan="2" attrs="{'invisible': [('display_period', '=', False)]}">
48
<group col="2" colspan="2">
49
<button name="button_period_clear" type="object" string="Remove all Periods" icon="gtk-clear" colspan="1"/>
50
<button name="button_period_add" type="object" string="Add all Periods" icon="gtk-add" colspan="1"/>
52
<field name="rev_period_ids" colspan="2"/>
53
<field name="period_ids" colspan="2" nolabel="1">
54
<tree string="Periods" editable="top" noteditable="1">
55
<field name="name" string="Name"/>
62
<group colspan="2" col="2">
68
<separator string="Reconciliation" colspan="4"/>
69
<field name="reconciled"/>
70
<field name="reconcile_id"/>
72
<group colspan="4" col="6">
73
<separator string="Third Party" colspan="6"/>
74
<field name="partner_id" colspan="2"/>
75
<field name="employee_id" colspan="2" context="{'disrupt_inactive': True}"/>
76
<field name="transfer_journal_id" colspan="2"/>
83
<!-- Analytic Multi-Criteria Data Browser Form -->
84
<record model="ir.ui.view" id="account_mcdb_analytic_form">
85
<field name="name">account.mcdb.analytic.form</field>
86
<field name="model">account.mcdb</field>
87
<field name="type">form</field>
88
<field name="arch" type="xml">
89
<form string="Selector - Analytic" hide_new_button="1" hide_duplicate_button="1" hide_delete_button="1">
91
<group col="4" colspan="4">
92
<group col="2" colspan="2">
93
<group col="4" colspan="2">
94
<separator string="Analytic journals" colspan="3"/>
95
<field name="display_analytic_journal" colspan="1" nolabel="1"/>
97
<group colspan="2" col="2" attrs="{'invisible': [('display_analytic_journal', '=', False)]}">
98
<group col="2" colspan="2">
99
<button name="button_analytic_journal_clear" type="object" string="Remove all Analytic Journals" icon="gtk-clear" colspan="1"/>
100
<button name="button_analytic_journal_add" type="object" string="Add all Analytic Journals" icon="gtk-add" colspan="1"/>
102
<field name="rev_analytic_journal_ids" colspan="2"/>
103
<field name="analytic_journal_ids" colspan="2" nolabel="1">
104
<tree string="Analytic Journals" editable="top" noteditable="1">
106
<field name="name" string="Name"/>
112
<group col="2" colspan="2">
113
<group col="4" colspan="2">
114
<separator string="Periods" colspan="3"/>
115
<field name="display_period" colspan="1" nolabel="1"/>
117
<group col="2" colspan="2" attrs="{'invisible': [('display_period', '=', False)]}">
118
<group col="2" colspan="2">
119
<button name="button_period_clear" type="object" string="Remove all Periods" icon="gtk-clear" colspan="1"/>
120
<button name="button_period_add" type="object" string="Add all Periods" icon="gtk-add" colspan="1"/>
122
<field name="rev_period_ids" colspan="2"/>
123
<field name="period_ids" colspan="2" nolabel="1">
124
<tree string="Periods" editable="top" noteditable="1">
125
<field name="name" string="Name"/>
126
<field name="state"/>
131
<group col="2" colspan="2">
132
<group col="4" colspan="2">
133
<separator string="Accounts" colspan="3"/>
134
<field name="display_account" colspan="1" nolabel="1"/>
136
<group colspan="2" col="2" attrs="{'invisible': [('display_account', '=', False)]}">
137
<group colspan="2" col="2">
138
<button name="button_account_clear" type="object" string="Remove all Accounts" icon="gtk-clear" colspan="1"/>
139
<button name="button_account_add" type="object" string="Add all Accounts" icon="gtk-add" colspan="1"/>
141
<field name="rev_account_ids"/>
142
<field name="account_ids" colspan="2" nolabel="1" domain="[('parent_id', '!=', False)]">
143
<tree string="Accounts" colors="blue:type in ('view');black:type not in ('view')" editable="top" noteditable="1">
146
<field name="type" string="Type"/>
152
<group colspan="2" col="2">
157
<group col="4" colspan="4" attrs="{'invisible': [('analytic_axis', '!=', 'fp')]}">
158
<group col="2" colspan="2">
159
<group col="4" colspan="2">
160
<separator string="Cost Centers" colspan="3"/>
161
<field name="display_cost_center" colspan="1" nolabel="1"/>
163
<label string="" colspan="2"/>
164
<group colspan="2" col="2" attrs="{'invisible': [('display_cost_center', '=', False)]}">
165
<group col="2" colspan="2">
166
<button name="button_cost_center_clear" type="object" string="Remove all Cost Centers" icon="gtk-clear" colspan="1"/>
167
<button name="button_cost_center_add" type="object" string="Add all Cost Centers" icon="gtk-add" colspan="1"/>
169
<field name="rev_analytic_account_cc_ids"/>
170
<field name="analytic_account_cc_ids" colspan="2" nolabel="1" domain="[('type', '!=', 'view'), ('category', '=', 'OC')]">
171
<tree string="Cost Center" editable="top" noteditable="1">
172
<field name="code" string="Ana. Code"/>
173
<field name="name" string="Ana. Name"/>
174
<field name="type" string="Ana. Type"/>
179
<group col="2" colspan="2">
180
<group col="4" colspan="2">
181
<separator string="Destinations" colspan="3"/>
182
<field name="display_destination" colspan="1" nolabel="1"/>
184
<group colspan="2" col="2" attrs="{'invisible': [('display_destination', '=', False)]}">
185
<group col="2" colspan="2">
186
<button name="button_destination_clear" type="object" string="Remove all Destinations" icon="gtk-clear" colspan="1"/>
187
<button name="button_destination_add" type="object" string="Add all Destinations" icon="gtk-add" colspan="1"/>
189
<field name="rev_analytic_account_dest_ids"/>
190
<field name="analytic_account_dest_ids" colspan="2" nolabel="1" domain="[('type', '!=', 'view'), ('category', '=', 'DEST')]">
191
<tree string="Destination" editable="top" noteditable="1">
192
<field name="code" string="Ana. Code"/>
193
<field name="name" string="Ana. Name"/>
194
<field name="type" string="Ana. Type"/>
200
<group col="2" colspan="2">
205
<group col="4" colspan="4" attrs="{'invisible': [('analytic_axis', '!=', 'fp')]}">
206
<group col="2" colspan="2">
207
<group col="4" colspan="2">
208
<separator string="Funding pools" colspan="3"/>
209
<field name="display_funding_pool" colspan="1" nolabel="1"/>
211
<group colspan="2" col="2" attrs="{'invisible': [('display_funding_pool', '=', False)]}">
212
<group col="2" colspan="2">
213
<button name="button_funding_pool_clear" type="object" string="Remove all Funding Pools" icon="gtk-clear" colspan="1"/>
214
<button name="button_funding_pool_add" type="object" string="Add all Funding Pools" icon="gtk-add" colspan="1"/>
216
<field name="rev_analytic_account_fp_ids"/>
217
<field name="analytic_account_fp_ids" colspan="2" nolabel="1" domain="[('type', '!=', 'view'), ('category', '=', 'FUNDING')]">
218
<tree string="Funding Pool" editable="top" noteditable="1">
219
<field name="code" string="Ana. Code"/>
220
<field name="name" string="Ana. Name"/>
221
<field name="type" string="Ana. Type"/>
226
<group col="2" colspan="2">
227
<label string="" colspan="2"/>
230
<group col="4" colspan="4" attrs="{'invisible': [('analytic_axis', '!=', 'f1')]}">
231
<group col="2" colspan="2">
232
<group col="4" colspan="2">
233
<separator string="Free 1" colspan="3"/>
234
<field name="display_free1" colspan="1" nolabel="1"/>
236
<group colspan="2" col="2" attrs="{'invisible': [('display_free1', '=', False)]}">
237
<group col="2" colspan="2">
238
<button name="button_free_1_clear" type="object" string="Remove all Free 1" icon="gtk-clear" colspan="1"/>
239
<button name="button_free_1_add" type="object" string="Add all Free 1" icon="gtk-add" colspan="1"/>
241
<field name="rev_analytic_account_f1_ids"/>
242
<field name="analytic_account_f1_ids" colspan="2" nolabel="1" domain="[('type', '!=', 'view'), ('category', '=', 'FREE1')]">
243
<tree string="Free 1" editable="top" noteditable="1">
244
<field name="code" string="Ana. Code"/>
245
<field name="name" string="Ana. Name"/>
246
<field name="type" string="Ana. Type"/>
251
<group col="2" colspan="2">
252
<label string="" colspan="2"/>
255
<group col="4" colspan="4" attrs="{'invisible': [('analytic_axis', '!=', 'f2')]}">
256
<group col="2" colspan="2">
257
<group col="4" colspan="2">
258
<separator string="Free 2" colspan="3"/>
259
<field name="display_free2" colspan="1" nolabel="1"/>
261
<group colspan="2" col="2" attrs="{'invisible': [('display_free2', '=', False)]}">
262
<group col="2" colspan="2">
263
<button name="button_free_2_clear" type="object" string="Remove all Free 2" icon="gtk-clear" colspan="1"/>
264
<button name="button_free_2_add" type="object" string="Add all Free 2" icon="gtk-add" colspan="1"/>
266
<field name="rev_analytic_account_f2_ids"/>
267
<field name="analytic_account_f2_ids" colspan="2" nolabel="1" domain="[('type', '!=', 'view'), ('category', '=', 'FREE2')]">
268
<tree string="Free 2" editable="top" noteditable="1">
269
<field name="code" string="Ana. Code"/>
270
<field name="name" string="Ana. Name"/>
271
<field name="type" string="Ana. Type"/>
276
<group col="2" colspan="2">
277
<label string="" colspan="2"/>
280
<group col="2" colspan="2">
285
<separator string="Reallocation" colspan="4"/>
286
<field name="reallocated" colspan="2"/>
287
<field name="reversed" colspan="2"/>
289
<group colspan="4" col="6">
290
<separator string="Third Party" colspan="6"/>
291
<field name="partner_txt" colspan="2"/>
299
<record id="account_mcdb_tree" model="ir.ui.view">
300
<field name="name">account.mcdb.tree</field>
301
<field name="model">account.mcdb</field>
302
<field name="type">tree</field>
303
<field name="arch" type="xml">
304
<tree string="Selector list">
305
<field name="description"/>
311
<!-- Search view with different name -->
312
<record id="account_mcdb_search" model="ir.ui.view">
313
<field name="name">account.mcdb.search</field>
314
<field name="model">account.mcdb</field>
315
<field name="type">search</field>
316
<field name="arch" type="xml">
317
<search string="Selector - G/L">
318
<field name="description" select="1"/>
319
<field name="user" select="1"/>
324
<record id="account_mcdb_analytic_search" model="ir.ui.view">
325
<field name="name">account.mcdb.analytic.search</field>
326
<field name="model">account.mcdb</field>
327
<field name="type">search</field>
328
<field name="arch" type="xml">
329
<search string="Selector - Analytic">
330
<field name="description" select="1"/>
331
<field name="user" select="1"/>
336
<!-- Actions to display search view (analytic OR G/L) -->
337
<record id="action_account_mcdb" model="ir.actions.act_window">
338
<field name="name">G/L Selector - Saved queries</field>
339
<field name="res_model">account.mcdb</field>
340
<field name="view_type">form</field>
341
<field name="view_mode">tree,form</field>
342
<field name="view_id" ref="account_mcdb_tree"/>
343
<field name="search_view_id" ref="account_mcdb_search"/>
344
<field name="domain">[('description', '!=', False), ('model', '=', 'account.move.line')]</field>
345
<field name="context">{'search_default_user': uid}</field>
348
<record id="action_account_mcdb_analytic" model="ir.actions.act_window">
349
<field name="name">Analytic Selector - Saved queries</field>
350
<field name="res_model">account.mcdb</field>
351
<field name="view_type">form</field>
352
<field name="view_mode">tree,form</field>
353
<field name="view_id" ref="account_mcdb_tree"/>
354
<field name="search_view_id" ref="account_mcdb_analytic_search"/>
355
<field name="context">{'from': 'account.analytic.line', 'search_default_user': uid}</field>
356
<field name="domain">[('description', '!=', False), ('model', '=', 'account.analytic.line')]</field>
359
<!-- Actions to display form view (analytic OR G/L) -->
360
<record id="action_account_mcdb_form" model="ir.actions.act_window">
361
<field name="name">G/L Selector</field>
362
<field name="res_model">account.mcdb</field>
363
<field name="view_type">form</field>
364
<field name="view_mode">form,tree</field>
365
<field name="view_id" ref="account_mcdb_form"/>
366
<field name="search_view_id" ref="account_mcdb_search"/>
367
<field name="domain">[('description', '!=', False), ('model', '=', 'account.move.line')]</field>
368
<field name="context">{'search_default_user': uid}</field>
371
<record id="action_account_mcdb_analytic_form" model="ir.actions.act_window">
372
<field name="name">Analytic Selector</field>
373
<field name="res_model">account.mcdb</field>
374
<field name="view_type">form</field>
375
<field name="view_mode">form,tree</field>
376
<field name="view_id" ref="account_mcdb_analytic_form"/>
377
<field name="search_view_id" ref="account_mcdb_analytic_search"/>
378
<field name="context">{'from': 'account.analytic.line', 'search_default_user': uid}</field>
379
<field name="domain">[('description', '!=', False), ('model', '=', 'account.analytic.line')]</field>
382
<!-- Actions that link each specific search view to a specific form view -->
383
<record model="ir.actions.act_window.view" id="action_account_mcdb_form2">
384
<field name="sequence" eval="20"/>
385
<field name="view_mode">form</field>
386
<field name="view_id" ref="account_mcdb_form"/>
387
<field name="act_window_id" ref="action_account_mcdb"/>
389
<record model="ir.actions.act_window.view" id="action_account_mcdb_tree">
390
<field name="sequence" eval="10"/>
391
<field name="view_mode">tree</field>
392
<field name="view_id" ref="account_mcdb_tree"/>
393
<field name="act_window_id" ref="action_account_mcdb"/>
396
<record model="ir.actions.act_window.view" id="action_account_mcdb_analytic_form2">
397
<field name="sequence" eval="20"/>
398
<field name="view_mode">form</field>
399
<field name="view_id" ref="account_mcdb_analytic_form"/>
400
<field name="act_window_id" ref="action_account_mcdb_analytic"/>
402
<record model="ir.actions.act_window.view" id="action_account_mcdb_analytic_tree">
403
<field name="sequence" eval="10"/>
404
<field name="view_mode">tree</field>
405
<field name="view_id" ref="account_mcdb_tree"/>
406
<field name="act_window_id" ref="action_account_mcdb_analytic"/>
410
<menuitem id="menu_finance_mcdb" name="Selector" parent="account.menu_finance" sequence="9"/>
411
<menuitem string="G/L Selector" action="action_account_mcdb_form" id="menu_finance_mcdb_move_line" parent="menu_finance_mcdb" sequence="1"/>
412
<menuitem string="G/L Selector - Saved queries" action="action_account_mcdb" id="menu_finance_mcdb_move_line_search" parent="menu_finance_mcdb" sequence="2"/>
413
<menuitem string="Analytic Selector" action="action_account_mcdb_analytic_form" id="menu_finance_mcdb_analytic_move_line" parent="menu_finance_mcdb" sequence="3"/>
414
<menuitem string="Analytic Selector - Saved queries" action="action_account_mcdb_analytic" id="menu_finance_mcdb_analytic_move_line_search" parent="menu_finance_mcdb" sequence="4"/>
416
<!-- Redefine MCDB to add instance -->
417
<record id="account_mcdb_form_instance_inherit" model="ir.ui.view">
418
<field name="name">account.mcdb.form.instance.inherit</field>
419
<field name="model">account.mcdb</field>
420
<field name="type">form</field>
421
<field name="priority" eval="18"/>
422
<field name='inherit_id' ref='account_mcdb.account_mcdb_form' />
423
<field name="arch" type="xml">
424
<xpath expr="/form//field[@name='journal_ids']/tree/field[@name='code']" position="before">
425
<field name="instance_id"/>
430
<record id="account_mcdb_analytic_form_instance_inherit" model="ir.ui.view">
431
<field name="name">account.mcdb.analytic.form.instance.inherit</field>
432
<field name="model">account.mcdb</field>
433
<field name="type">form</field>
434
<field name="priority" eval="18"/>
435
<field name='inherit_id' ref='account_mcdb.account_mcdb_analytic_form' />
436
<field name="arch" type="xml">
437
<xpath expr="/form//field[@name='analytic_journal_ids']/tree/field[@name='code']" position="before">
438
<field name="instance_id"/>