1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- Journal Items Lines for correction wizard -->
<record model="ir.ui.view" id="wizard_journal_items_corrections_lines_tree">
<field name="name">wizard.journal.items.corrections.lines.tree</field>
<field name="model">wizard.journal.items.corrections.lines</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree hide_new_button="1" hide_delete_button="1" editable="bottom" colors="blue:analytic_distribution_state in ('valid');red:analytic_distribution_state in ('invalid');black:analytic_distribution_state in ('none')">
<field name="move_id"/>
<field name="ref"/>
<field name="date"/>
<field name="account_id" domain="[('restricted_area', '=', 'correction_wizard')]" />
<button name="button_analytic_distribution" type="object"
icon="terp-stock_symbol-selection" string="Ana. Distri."
attrs="{'invisible': [('is_analytic_target', '=', False)]}" />
<field name="analytic_distribution_state"/>
<field name="debit_currency"/>
<field name="credit_currency"/>
<field name="currency_id"/>
<field name="analytic_distribution_id" invisible="1"/>
<field name="is_analytic_target" invisible="1"/>
</tree>
</field>
</record>
<!-- Correction wizard -->
<record model="ir.ui.view" id="wizard_journal_items_corrections_form">
<field name="name">wizard.journal.items.corrections.form</field>
<field name="model">wizard.journal.items.corrections</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Journal items corrections Wizard">
<separator string="Correction"/>
<field name="date" on_change="onchange_date(date)" colspan="2"/>
<label string="" colspan="2"/>
<field name="from_donation" invisible="1"/>
<newline/>
<field name="to_be_corrected_ids" colspan="6" context="{'from_donation_account': from_donation}" nolabel="1"/>
<newline/>
<group colspan="4" col="6">
<label string ="" colspan="1"/>
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
<button icon="gtk-redo" string="Correct" name="action_confirm" type="object"/>
</group>
<field name="from_register" invisible="1"/>
<field name="state" invisible="1"/>
</form>
</field>
</record>
<!-- Analytic Distribution Wizard -->
<record model="ir.ui.view" id="inherit_analytic_distribution_wizard">
<field name="name">inherit.analytic.distribution.wizard</field>
<field name="model">analytic.distribution.wizard</field>
<field name="type">form</field>
<field name='inherit_id' ref='analytic_distribution.analytic_distribution_wizard_view'/>
<field name="arch" type="xml">
<data>
<xpath expr="/form/field[@name='amount']" position="before">
<field name="date" context="context"
attrs="{'invisible': [('state', '!=', 'correction')], 'required': [('state', '=', 'correction')]}"/>
<newline/>
</xpath>
<xpath expr="/form//field[@name='state']" position="before">
<group colspan="4" attrs="{'invisible': [('state', '!=', 'correction')]}">
<label string="" colspan="2"/>
<button name="button_cancel" string='Cancel' type='object' icon='gtk-cancel' colspan="1"/>
<button name="button_confirm" string="Correct it" type="object" icon="gtk-edit" colspan="1" attrs="{'readonly': [('is_writable', '=', False)]}"/>
</group>
</xpath>
</data>
</field>
</record>
</data>
</openerp>
|