This repository has been archived by the owner on Feb 26, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
account_asset.xml
291 lines (256 loc) · 14.4 KB
/
account_asset.xml
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<record model="ir.sequence.type" id="seq_type_asset">
<field name="name">Asset Code</field>
<field name="code">account.asset.asset</field>
</record>
<record model="ir.sequence" id="seq_asset">
<field name="name">Asset</field>
<field name="code">account.asset.asset</field>
<field eval="6" name="padding"/>
<field name="prefix">AS/</field>
</record>
<record model="ir.ui.view" id="view_account_asset_category_formit">
<field name="name">view.account_asset_category_formit</field>
<field name="model">account.asset.category</field>
<field name="inherit_id" ref="account_asset.view_account_asset_category_form"/>
<field name="arch" type="xml">
<field name="name" position="after">
<field name="code"/>
<field name="asset_type"/>
</field>
<field name="journal_id" position="replace" />
<field name="account_asset_id" position="replace"/>
<field name="account_depreciation_id" position="replace" />
<field name="account_expense_depreciation_id" position="replace" />
<separator string="Notes" position="replace"></separator>
<field name="note" position="replace">
<notebook colspan="4" >
<page string="Percentuali" autofocus="autofocus">
<group>
<field name="ordinary_amortization"/>
<field name="deductibility"/>
<field name="amortization_reduced"/>
<field name="reduction_first_year"/>
<field name="early_ammortization"/>
<field name="nmax_advanced_amortize"/>
<field name="maintenance_from_amortize"/>
</group>
</page>
<page string="Contabili">
<group>
<field name="journal_id" />
<field name="account_asset_id" on_change="onchange_account_asset(account_asset_id)"/>
<field name="account_depreciation_id"/>
<field name="account_expense_depreciation_id"/>
<field name="maintenance_account_id"/>
<field name="gains_account_id"/>
<field name="losses_account_id"/>
</group>
</page>
<page string="Notes">
<field name="note" />
</page>
</notebook>
</field>
</field>
</record>
<record model="ir.ui.view" id="view_account_asset_category_treeit">
<field name="name">view.account_asset_category_treeit</field>
<field name="model">account.asset.category</field>
<field name="inherit_id" ref="account_asset.view_account_asset_category_tree"/>
<field name="arch" type="xml">
<field name="journal_id" position="replace" />
<field name="method" position="replace" />
<field name="name" position="before" >
<field name="code" />
</field>
</field>
</record>
<record model="ir.ui.view" id="view_account_asset_category_searchit">
<field name="name">view.account_asset_category_searchit</field>
<field name="model">account.asset.category</field>
<field name="inherit_id" ref="account_asset.view_account_asset_category_search"/>
<field name="arch" type="xml">
<field name="name" position="before">
<field name="code"/>
</field>
</field>
</record>
<record model="ir.ui.view" id="view_account_asset_asset_formit">
<field name="name">view.account_asset_asset_formit</field>
<field name="model">account.asset.asset</field>
<field name="inherit_id" ref="account_asset.view_account_asset_asset_form"/>
<field name="arch" type="xml">
<field name="purchase_date" position="replace"></field>
<xpath expr="//page[@string='General']/group/group" position="replace" >
<group string="Acquisto">
<field name="purchase_value" widget="monetary" options="{'currency_field': 'currency_id'}" on_change="onchange_purchase_salvage_value(purchase_value, salvage_value,incremental_value,decremental_value,deductibility)"/>
<field name="partner_id" string="Fornitore"/>
<field name="invoice_purchase_number" />
<field name="purchase_date" />
</group>
<group string="Valori">
<group>
<field name="deductibility" on_change="onchange_deductibility(purchase_value, deductibility,incremental_value,decremental_value)"
string="Perc.Deducibilità"/>
<field name="salvage_value" string="Importo indeducibile" widget="monetary" options="{'currency_field': 'currency_id'}" on_change="onchange_purchase_salvage_value(purchase_value, salvage_value,incremental_value,decremental_value,deductibility)"/>
<field name="value_residual" string="Valore da Ammortizzare" widget="monetary" options="{'currency_field': 'currency_id'}"/>
<field name="accumulated_depreciation" string="Fondo Ammortamento" widget="monetary" options="{'currency_field': 'currency_id'}"/>
<field name="last_use_year" string="Ultimo Ammortamento" />
<field name="remaining_value" string="Residuo" widget="monetary" options="{'currency_field': 'currency_id'}"/>
</group>
<group>
<field name="gains" string="Plusvalenze" widget="monetary" options="{'currency_field': 'currency_id'}"/>
<field name="losses" string="Minusvalenze" widget="monetary" options="{'currency_field': 'currency_id'}"/>
<field name="incremental_value" string="Incrementi" widget="monetary" options="{'currency_field': 'currency_id'}" on_change="onchange_purchase_salvage_value(purchase_value, salvage_value,incremental_value,decremental_value,deductibility)"/>
<field name="decremental_value" string="Decrementi" widget="monetary" options="{'currency_field': 'currency_id'}" on_change="onchange_purchase_salvage_value(purchase_value, salvage_value,incremental_value,decremental_value,deductibility)"/>
</group>
</group>
<group string="Vendita">
<field name="customer_id" string="Cliente"/>
<field name="invoice_sale_number" string="Num.Fattura"/>
<field name="sale_date" string="Data Fattura"/>
<field name="sale_value" string="Valore Vendita"/>
</group>
</xpath>
<notebook position="inside">
<page string="Percentuali">
<group>
<field name="ordinary_amortization" string="Ammortamento Ordinario"/>
<field name="amortization_reduced" string="Ammortamento Ridotto"/>
<field name="early_ammortization" string="Ammortamento Anticipato"/>
<field name="personal_ammortization" string="Ammortamento Personalizzato"/>
</group>
<group string="Parametri generazione Ammortamenti" >
<field name="next_use_year" string="Ammortamento Prossimo"/>
<field name="type_amortization" string="Tipo Ammortamento"/>
</group>
<group string="Altri">
<field name="minor_use" string="Minor Uso"/>
<field name="maintenance_accrued" string="Ammortamento Manutenzioni"/>
<field name="used_asset" string="Bene Usato"/>
<field name="date_deactivate_maintenance" string="Data Disattivazione Manutenzioni"/>
<field name="first_use_year" string="Anno Primo Ammortamento"/>
<field name="deact_use_year" string="Anno disattivazione Bene"/>
</group>
</page>
</notebook>
<field name="history_ids" position="replace">
<field name="invoice_line_ids" mode="tree">
<tree string="Invoice Lines" >
<field name="type" string="Tipo"/>
<field name="date_invoice" string="Data Fattura"/>
<field name="supplier_invoice_number" string="Num.Fattura" />
<field name="partner_id" string="Fornitore"/>
<field name="new_asset" string="Primo Doc." />
<field name="name" />
<field name="account_id"/>
<field name="price_subtotal"/>
</tree>
</field>
</field>
<xpath expr="//page[@string='Depreciation Board']" position="replace" >
<page string="Depreciation Board">
<field name="depreciation_line_ids" mode="tree">
<tree string="Depreciation Lines" colors="blue:(move_check == False);black:(move_check == True)">
<field name="fiscal_year" string="Anno"/>
<field name="depreciation_date"/>
<field name="sequence" invisible="1"/>
<field name="type_amortization" string="Tipo"/>
<field name="value_residual" />
<field name="perc_ammortization" string="Perc." />
<field name="depreciated_value" />
<field name="amount"/>
<field name="remaining_value" string="Residuo da Ammortizzare"/>
<field name="move_check"/>
<field name="parent_state" invisible="1"/>
</tree>
<form string="Depreciation Lines">
<group>
<group>
<field name="name"/>
<field name="amount"/>
<field name="move_id"/>
<field name="move_check"/>
</group>
<group>
<field name="sequence"/>
<field name="fiscal_year" string="Anno" />
<field name="depreciation_date"/>
<field name="type_amortization" string="Tipo" />
<field name="perc_ammortization" string="Perc."/>
<field name="depreciated_value"/>
<field name="value_residual"/>
<field name="remaining_value" string="Residuo da Ammortizzare" />
</group>
</group>
</form>
</field>
</page>
</xpath>
</field>
</record>
<!-- Supplier invoice -->
<record model="ir.ui.view" id="view_account_invoice_asset_form_it">
<field name="name">account.invoice.line.form_it</field>
<field name="model">account.invoice.line</field>
<field name="inherit_id" ref="account_asset.view_account_invoice_asset_form"/>
<field name="arch" type="xml">
<field name="asset_category_id" position="replace">
<field name="asset_category_id" on_change="onchange_category_id(asset_category_id)" />
<field name="asset_id" on_change="onchange_asset_id(asset_id)"/>
<field name="new_asset" />
</field>
</field>
</record>
<record model="ir.ui.view" id="view_invoice_asset_category_it">
<field name="name">account.invoice.supplier.form_it</field>
<field name="model">account.invoice</field>
<field name="inherit_id" ref="account_asset.view_invoice_asset_category"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='invoice_line']/tree/field[@name='asset_category_id']" position="replace">
<field name="asset_category_id" on_change="onchange_category_id(asset_category_id)" />
<field name="asset_id" on_change="onchange_asset_id(asset_id)" />
<field name="new_asset" />
</xpath>
</field>
</record>
<!-- Customers invoice -->
<!--
<record model="ir.ui.view" id="view_account_invoice_cust_asset_form_it">
<field name="name">account.invoice.cust.line.form_it</field>
<field name="model">account.invoice.line</field>
<field name="inherit_id" ref="account.invoice_form"/>
<field name="arch" type="xml">
<field name="account_id" position="after">
<field name="asset_id"/>
</field>
</field>
</record>
-->
<record model="ir.ui.view" id="view_invoice_cust_asset_it">
<field name="name">account.invoice.cust.form_it</field>
<field name="model">account.invoice</field>
<field name="inherit_id" ref="account.invoice_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='invoice_line']/tree/field[@name='account_id']" position="after">
<field name="asset_id" on_change="onchange_asset_id(asset_id)" />
<field name="total_sale"/>
</xpath>
</field>
</record>
<!-- Account Move Line -->
<record model="ir.ui.view" id="view_asset_on_move_line form_it">
<field name="name">asset_on_move_line form_it</field>
<field name="model">account.move</field>
<field name="inherit_id" ref="account.view_move_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='line_id']/tree/field[@name='date_maturity']" position="after">
<field name="asset_id" />
</xpath>
</field>
</record>
</data>
</openerp>