~openerp-spain-team/openerp-spain/6.0-git

« back to all changes in this revision

Viewing changes to l10n_es_cierre_ejercicio/fyc_view.xml

  • Committer: Borja L.S.
  • Date: 2010-10-18 10:04:25 UTC
  • Revision ID: git-v1:271c47a993616dbba60585d48b8b98d603199d93
[REF] *: Refactorización para portar a 6.0 - Paso 1.

- Se han renombrado los módulos para usar la nomenclatura propuesta
  por OpenERP: l10n_es para el módulo base de localización (plan de 
  cuentas), l10n_es_* para el resto de módulos.

- Se eliminan los módulos extra_addons/* que deberían moverse a 
  los extra-addons genéricos (no son específicos de España).

- Se renombran los __terp__.py por __openerp__.py

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0"?>
 
2
<!--
 
3
#
 
4
#    OpenERP - Spanish Fiscal Year Closing
 
5
#    Copyright (C) 2009 Pexego Sistemas Informáticos. All Rights Reserved
 
6
#    $Id$
 
7
#
 
8
#    This program is free software: you can redistribute it and/or modify
 
9
#    it under the terms of the GNU General Public License as published by
 
10
#    the Free Software Foundation, either version 3 of the License, or
 
11
#    (at your option) any later version.
 
12
#
 
13
#    This program is distributed in the hope that it will be useful,
 
14
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
15
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
16
#    GNU General Public License for more details.
 
17
#
 
18
#    You should have received a copy of the GNU General Public License
 
19
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
20
#
 
21
-->
 
22
<!--
 
23
Authors: Borja López Soilán (Pexego) - borjals@pexego.es
 
24
-->
 
25
<openerp>
 
26
    <data>
 
27
 
 
28
        <!-- Wizard tree view -->
 
29
        <record model="ir.ui.view" id="view_fyc_tree">
 
30
            <field name="name">l10n_es_cierre_ejercicio.fyc.tree</field>
 
31
            <field name="model">l10n_es_cierre_ejercicio.fyc</field>
 
32
            <field name="type">tree</field>
 
33
            <field name="arch" type="xml">
 
34
                <tree string="Spanish Fiscal Year Closings" colors="red:state=='new';blue:state=='draft';green:state=='in_progress'">
 
35
                    <field name="company_id" select="1"/>
 
36
                    <field name="name" select="2"/>
 
37
                    <field name="closing_fiscalyear_id" select="1"/>
 
38
                    <field name="opening_fiscalyear_id" select="1"/>
 
39
                    <field name="state"/>
 
40
                </tree>
 
41
            </field>
 
42
        </record>
 
43
 
 
44
        <!-- Wizard form view -->
 
45
        <record model="ir.ui.view" id="view_fyc_form">
 
46
            <field name="name">l10n_es_cierre_ejercicio.fyc.form</field>
 
47
            <field name="model">l10n_es_cierre_ejercicio.fyc</field>
 
48
            <field name="type">form</field>
 
49
            <field name="arch" type="xml">
 
50
                <form string="Spanish Fiscal Year Closing">
 
51
                    <group attrs="{'invisible':[('state','!=','new')]}" colspan="4">
 
52
                        <label string="Please, select the company, fiscal year to close and fiscal year to open." colspan="4"/>
 
53
                    </group>
 
54
                    <group colspan="4">
 
55
                        <field name="company_id" required="1" select="1" attrs="{'readonly':[('state','!=','new')]}"/>
 
56
                        <field name="name" select="2" attrs="{'readonly':[('state','!=','new')]}"/>
 
57
                    </group>
 
58
                    <group string="Fiscal Years" colspan="4">
 
59
                        <field name="closing_fiscalyear_id" attrs="{'readonly':[('state','!=','new')]}"/>
 
60
                        <field name="opening_fiscalyear_id" attrs="{'readonly':[('state','!=','new')]}"/>
 
61
                    </group>
 
62
                    <group attrs="{'invisible':[('state','!=','new')]}" colspan="4">
 
63
                        <button name="draft" string="Continue" states="new" icon="gtk-apply" colspan="4"/>
 
64
                    </group>
 
65
                    <group attrs="{'invisible':[('state','=','new')]}" colspan="4">
 
66
                        <notebook colspan="4">
 
67
                            <page string="General">
 
68
                                <group string="Operations" colspan="4">
 
69
                                    <group colspan="4">
 
70
                                        <separator string="Operation to perform" colspan="2"/>
 
71
                                        <separator string="Move created by the operation" colspan="2"/>
 
72
                                        <field name="create_loss_and_profit" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
73
                                        <field name="loss_and_profit_move_id"/>
 
74
                                        <field name="create_net_loss_and_profit" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
75
                                        <field name="net_loss_and_profit_move_id"/>
 
76
                                        <field name="create_closing" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
77
                                        <field name="closing_move_id"/>
 
78
                                        <field name="create_opening" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
79
                                        <field name="opening_move_id"/>
 
80
                                    </group>
 
81
                                    <separator string="Checks"/>
 
82
                                    <group colspan="4">
 
83
                                        <field name="check_invalid_period_moves" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
84
                                        <field name="check_draft_moves" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
85
                                        <field name="check_unbalanced_moves" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
86
                                    </group>
 
87
                                </group>
 
88
                                <group colspan="4" col="10">
 
89
                                    <field name="state" select="2" readonly="1"/>
 
90
                                    <button name="%(wiz_l10n_es_cierre_ejercicio_run)d"
 
91
                                        type="action"
 
92
                                        string="Perform the operations"
 
93
                                        icon="gtk-execute"
 
94
                                        states="draft,in_progress"/>
 
95
                                    <button name="confirm" string="Confirm" states="in_progress" icon="gtk-apply"/>
 
96
                                    <button name="%(wiz_l10n_es_cierre_ejercicio_cancel)d"
 
97
                                        type="action"
 
98
                                        string="Cancel"
 
99
                                        icon="gtk-cancel"
 
100
                                        states="in_progress,done"/>
 
101
                                    <button name="action_recover" string="Draft" type="object" states="canceled" icon="gtk-undo"/>
 
102
                                </group>
 
103
                            </page>
 
104
                            <page string="Configuration" attrs="{'invisible':[('state','=','new')]}">
 
105
                                <notebook colspan="4">
 
106
                                    <page string="Loss and Profit">
 
107
                                        <field name="lp_description" colspan="4" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
108
                                        <field name="lp_journal_id" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
109
                                        <field name="lp_period_id" domain="[('special','=',True)]" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
110
                                        <field name="lp_date" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
111
                                        <field name="lp_account_mapping_ids" colspan="4" nolabel="1" attrs="{'readonly':[('state','in',('done','cancel'))]}">
 
112
                                            <tree string="Account mappings" editable="top">
 
113
                                                <field name="source_account_id"/>
 
114
                                                <field name="dest_account_id" required="1"/>
 
115
                                            </tree>
 
116
                                            <form string="Account mapping">
 
117
                                                <field name="source_account_id"/>
 
118
                                                <field name="dest_account_id" required="1"/>
 
119
                                                <field name="name"/>
 
120
                                            </form>
 
121
                                        </field>
 
122
                                    </page>
 
123
                                    <page string="Net Loss and Profit">
 
124
                                        <field name="nlp_description" colspan="4" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
125
                                        <field name="nlp_journal_id" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
126
                                        <field name="nlp_period_id" domain="[('special','=',True)]" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
127
                                        <field name="nlp_date" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
128
                                        <field name="nlp_account_mapping_ids" colspan="4" nolabel="1" attrs="{'readonly':[('state','in',('done','cancel'))]}">
 
129
                                            <tree string="Account mappings" editable="top">
 
130
                                                <field name="source_account_id"/>
 
131
                                                <field name="dest_account_id" required="1"/>
 
132
                                            </tree>
 
133
                                            <form string="Account mapping">
 
134
                                                <field name="source_account_id"/>
 
135
                                                <field name="dest_account_id" required="1"/>
 
136
                                                <field name="name"/>
 
137
                                            </form>
 
138
                                        </field>
 
139
                                    </page>
 
140
                                    <page string="Closing">
 
141
                                        <field name="c_description" colspan="4" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
142
                                        <field name="c_journal_id" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
143
                                        <field name="c_period_id" domain="[('special','=',True)]" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
144
                                        <field name="c_date" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
145
                                        <field name="c_account_mapping_ids" colspan="4" nolabel="1" attrs="{'readonly':[('state','in',('done','cancel'))]}">
 
146
                                            <tree string="Accounts to close" editable="top">
 
147
                                                <field name="source_account_id"/>
 
148
                                            </tree>
 
149
                                            <form string="Account to close">
 
150
                                                <field name="source_account_id"/>
 
151
                                                <field name="name"/>
 
152
                                            </form>
 
153
                                        </field>
 
154
                                    </page>
 
155
                                    <page string="Opening">
 
156
                                        <field name="o_description" colspan="4" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
157
                                        <field name="o_journal_id" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
158
                                        <field name="o_period_id" domain="[('special','=',True)]" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
159
                                        <field name="o_date" attrs="{'readonly':[('state','in',('done','cancel'))]}"/>
 
160
                                    </page>
 
161
                                </notebook>
 
162
                            </page>
 
163
                        </notebook>
 
164
                    </group>
 
165
                </form>
 
166
            </field>
 
167
        </record>
 
168
 
 
169
        <!-- Menus and windows -->
 
170
 
 
171
        <record model="ir.actions.act_window" id="action_view_fyc_form">
 
172
            <field name="name">Close Fiscal Year</field>
 
173
            <field name="type">ir.actions.act_window</field>
 
174
            <field name="res_model">l10n_es_cierre_ejercicio.fyc</field>
 
175
            <field name="view_type">form</field>
 
176
            <field name="view_mode">form,tree</field>
 
177
            <field name="view_id" ref="view_fyc_form"/>
 
178
        </record>
 
179
 
 
180
        <menuitem id="menu_fyc_new"
 
181
                    parent="account.menu_account_end_year_treatments"
 
182
                    name="Close Fiscal Year"
 
183
                    action="action_view_fyc_form"
 
184
                    sequence="10"/>
 
185
 
 
186
        <record model="ir.actions.act_window" id="action_view_fyc_tree">
 
187
            <field name="name">Fiscal Years Closings</field>
 
188
            <field name="type">ir.actions.act_window</field>
 
189
            <field name="res_model">l10n_es_cierre_ejercicio.fyc</field>
 
190
            <field name="view_type">form</field>
 
191
            <field name="view_mode">tree,form</field>
 
192
            <field name="view_id" ref="view_fyc_tree"/>
 
193
        </record>
 
194
 
 
195
        <menuitem id="menu_fyc_list"
 
196
                    parent="account.menu_account_end_year_treatments"
 
197
                    name="Fiscal Years Closings"
 
198
                    action="action_view_fyc_tree"
 
199
                    sequence="11"/>
 
200
 
 
201
    </data>
 
202
</openerp>