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

« back to all changes in this revision

Viewing changes to msf_accrual/msf_accrual_view.xml

UF-358 [ADD] Initial creation : backup of this day

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<?xml version="1.0"?>
2
 
<openerp>
3
 
      <data>
4
 
            
5
 
            <record id="view_msf_accrual_line_form" model="ir.ui.view">
6
 
                <field name="name">msf.accrual.line.form</field>
7
 
                <field name="model">msf.accrual.line</field>
8
 
                <field name="type">form</field>
9
 
                <field name="arch" type="xml">
10
 
                    <form string="Accrual Line">
11
 
                        <group colspan="2" col="4">
12
 
                            <field name="document_date"/>
13
 
                            <field name="date" colspan="2" readonly="1"/>
14
 
                            <field name="period_id" colspan="2" on_change="onchange_period(period_id)"/>
15
 
                            <newline/>
16
 
                            <field name="description" colspan="2"/>
17
 
                            <field name="reference" colspan="2"/>
18
 
                            <newline/>
19
 
                            <field name="third_party_type"/>
20
 
                            <field name="partner_id" nolabel="1" 
21
 
                                attrs="{'required': [('third_party_type', '=', 'res.partner')], 'invisible': [('third_party_type', '!=', 'res.partner')]}"/>
22
 
                            <field name="employee_id" nolabel="1" context="{'search_default_active': True}"
23
 
                                attrs="{'required': [('third_party_type', '=', 'hr.employee')], 'invisible': [('third_party_type', '!=', 'hr.employee')]}"/>
24
 
                            <newline/>
25
 
                            <field name="expense_account_id" colspan="2"/>
26
 
                            <field name="accrual_account_id" colspan="2" domain="[('accrual_account', '=', True)]"/>
27
 
                            <newline/>
28
 
                            <field name="journal_id" domain="[('is_current_instance','=',True)]" colspan="2" readonly="1"/>
29
 
                            <newline/>
30
 
                            <field name="accrual_amount" colspan="2"/>
31
 
                            <field name="currency_id" colspan="2"/>
32
 
                            <newline/>
33
 
                            <field name="state" colspan="2" readonly="1"/>
34
 
                            <button name="button_cancel" string="Cancel" states="posted" type="object" icon="gtk-cancel"/>
35
 
                        </group>
36
 
                    </form>
37
 
                </field>
38
 
            </record>
39
 
            
40
 
            <record id="view_msf_accrual_line_tree" model="ir.ui.view">
41
 
                <field name="name">msf.accrual.line.tree</field>
42
 
                <field name="model">msf.accrual.line</field>
43
 
                <field name="type">tree</field>
44
 
                <field name="arch" type="xml">
45
 
                    <tree string="Accruals Management" 
46
 
                        colors="red:not analytic_distribution_id; blue:analytic_distribution_id and state != 'posted'; black: state == 'posted'">
47
 
                        <button name="button_duplicate" string="Duplicate" type="object" icon="gtk-copy" />
48
 
                        <field name="document_date"/>
49
 
                        <field name="date"/>
50
 
                        <field name="period_id"/>
51
 
                        <field name="description"/>
52
 
                        <field name="reference"/>
53
 
                        <field name="third_party_name"/>
54
 
                        <field name="analytic_distribution_id" invisible="1"/>
55
 
                        <button name="button_analytic_distribution" string="Analytical Distribution" type="object" 
56
 
                            icon="terp-stock_symbol-selection" context="context"/>
57
 
                        <field name="expense_account_id"/>
58
 
                        <field name="accrual_account_id"/>
59
 
                        <field name="accrual_amount"/>
60
 
                        <field name="currency_id"/>
61
 
                        <field name="functional_amount"/>
62
 
                        <field name="functional_currency_id"/>
63
 
                        <field name="state"/>
64
 
                    </tree>
65
 
                </field>
66
 
            </record>
67
 
            
68
 
            <record id="view_msf_accrual_line_search" model="ir.ui.view">
69
 
                <field name="name">msf.accrual.line.search</field>
70
 
                <field name="model">msf.accrual.line</field>
71
 
                <field name="type">search</field>
72
 
                <field name="arch" type="xml">
73
 
                    <search string="Accruals Management">
74
 
                        <group>
75
 
                            <filter name="draft" icon="terp-check" string="Draft"
76
 
                                    domain="[('state', '=', 'draft')]"/>
77
 
                            <separator orientation="vertical"/>
78
 
                            <field name="period_id"/>
79
 
                            <field name="expense_account_id"/>
80
 
                            <field name="accrual_account_id"/>
81
 
                        </group>
82
 
                    </search>
83
 
                </field>
84
 
            </record>
85
 
 
86
 
            <record id="action_msf_accrual_line_tree" model="ir.actions.act_window">
87
 
                <field name="name">Accruals Management</field>
88
 
                <field name="res_model">msf.accrual.line</field>
89
 
                <field name="view_type">form</field>
90
 
                <field name="view_mode">tree,form</field>
91
 
                <field name="context">{'search_default_draft':1}</field>
92
 
            </record>
93
 
 
94
 
            <menuitem action="action_msf_accrual_line_tree" id="menu_action_msf_accrual_line_tree" parent="account.menu_finance_periodical_processing" sequence="1"/>
95
 
 
96
 
       </data>
97
 
</openerp>