1 <?xml version="1.0" encoding="utf-8"?>
5 <record id="view_account_analytic_account_list" model="ir.ui.view">
6 <field name="name">account.analytic.account.list</field>
7 <field name="model">account.analytic.account</field>
8 <field name="type">tree</field>
9 <field eval="8" name="priority"/>
10 <field name="arch" type="xml">
11 <tree toolbar="1" colors="red:state=='pending';grey:state in ('cancelled','close');blue:type=='view'" string="Analytic Accounts">
12 <field name="complete_name"/>
13 <field name="code" groups="base.group_extended"/>
14 <field name="quantity"/>
16 <field name="user_id" invisible="1"/>
17 <field name="parent_id" invisible="1"/>
18 <field name="partner_id" invisible="1"/>
19 <field name="state" invisible="1"/>
20 <field name="type" invisible="1"/>
25 <record id="view_account_analytic_account_search" model="ir.ui.view">
26 <field name="name">account.analytic.account.search</field>
27 <field name="model">account.analytic.account</field>
28 <field name="type">search</field>
29 <field name="arch" type="xml">
30 <search string="Analytic Account">
32 <filter icon="terp-gtk-media-pause" string="Pending" domain="[('state','=','pending')]" help="Pending Accounts"/>
33 <filter icon="terp-camera_test" string="Current" domain="[('state','=','open')]" help="Current Accounts"/>
34 <separator orientation="vertical"/>
35 <filter icon="terp-go-today" string="Overdue Account" domain="[('date','<',time.strftime('%%Y-%%m-%%d'))]" help="Analytic Accounts with a past deadline."/>
36 <separator orientation="vertical"/>
39 <field name="partner_id"/>
40 <field name="user_id" widget="selection"/>
43 <group expand="0" string="Group By...">
44 <filter string="Manager" icon="terp-personal" domain="[]" context="{'group_by':'user_id'}"/>
45 <filter string="Associated Partner" icon="terp-partner" domain="[]" context="{'group_by':'partner_id'}"/>
46 <separator orientation="vertical"/>
47 <filter string="Parent Account" icon="terp-folder-green" domain="[]" context="{'group_by':'parent_id'}"/>
48 <filter string="State" icon="terp-stock_effects-object-colorize" domain="[]" context="{'group_by':'state'}" groups="base.group_no_one"/>
54 <record id="view_account_analytic_account_tree" model="ir.ui.view">
55 <field name="name">account.analytic.account.tree</field>
56 <field name="model">account.analytic.account</field>
57 <field name="type">tree</field>
58 <field name="field_parent">child_complete_ids</field>
59 <field name="arch" type="xml">
60 <tree colors="blue:state=='pending';grey:state in ('close','cancelled');blue:type=='view'" string="Analytic account" toolbar="1">
62 <field name="code" groups="base.group_extended"/>
64 <field name="credit"/>
65 <field name="balance"/>
66 <field name="state" invisible="1"/>
67 <field name="currency_id" groups="base.group_extended"/>
68 <field name="date" invisible="1"/>
69 <field name="user_id" invisible="1"/>
70 <field name="partner_id" invisible="1"/>
71 <field name="parent_id" invisible="1"/>
77 <record id="view_account_analytic_account_form" model="ir.ui.view">
78 <field name="name">account.analytic.account.form</field>
79 <field name="model">account.analytic.account</field>
80 <field name="type">form</field>
81 <field name="arch" type="xml">
82 <form string="Analytic account">
83 <group colspan="4" col="6">
84 <field name="name" colspan="4"/>
85 <field name="code" groups="base.group_extended"/>
86 <field name="parent_id" on_change="on_change_parent(parent_id)" groups="base.group_extended"/>
87 <field name="company_id" on_change="on_change_company(company_id)" select="2" widget="selection" groups="base.group_multi_company" attrs="{'required': [('type','<>','view')]}"/>
88 <field name="type" select="2"/>
90 <notebook colspan="4">
91 <page string="Account Data">
92 <group colspan="2" col="2">
93 <separator colspan="2" string="Contacts"/>
94 <field name="partner_id" on_change="on_change_partner_id(partner_id)"/>
95 <field name="contact_id"/>
96 <field name="user_id"/>
98 <group colspan="2" col="2" name="contract">
99 <separator colspan="2" string="Contract Data"/>
100 <field name="date_start"/>
102 <field name="quantity_max"/>
105 <page string="Description">
106 <field colspan="4" name="description" nolabel="1"/>
113 <record id="action_account_analytic_account_form" model="ir.actions.act_window">
114 <field name="name">Analytic Accounts</field>
115 <field name="type">ir.actions.act_window</field>
116 <field name="res_model">account.analytic.account</field>
117 <field name="view_type">form</field>
118 <field name="view_mode">tree,graph,form</field>
119 <field name="view_id" ref="view_account_analytic_account_tree"/>
120 <field name="search_view_id" ref="account.view_account_analytic_account_search"/>
122 <menuitem action="action_account_analytic_account_form" id="account_analytic_def_account"
123 parent="menu_analytic_accounting"
124 groups="analytic.group_analytic_accounting"/>
126 <record id="act_account_renew_view" model="ir.actions.act_window">
127 <field name="name">Accounts to Renew</field>
128 <field name="type">ir.actions.act_window</field>
129 <field name="res_model">account.analytic.account</field>
130 <field name="view_type">form</field>
131 <field name="view_mode">tree,form</field>
132 <field name="domain">[('date','<',time.strftime('%Y-%m-%d %H:%M:%S'))]</field>
133 <field name="filter" eval="True"/>
136 <record id="action_account_analytic_account_tree2" model="ir.actions.act_window">
137 <field name="name">Chart of Analytic Accounts</field>
138 <field name="res_model">account.analytic.account</field>
139 <field name="view_type">tree</field>
140 <field name="view_id" ref="view_account_analytic_account_tree"/>
141 <field name="domain">[('parent_id','=',False)]</field>
142 <field name="help">The normal chart of accounts has a structure defined by the legal requirement of the country. The analytic chart of accounts structure should reflect your own business needs in term of costs/revenues reporting. They are usually structured by contracts, projects, products or departements. Most of the OpenERP operations (invoices, timesheets, expenses, etc) generate analytic entries on the related account.</field>
145 <menuitem groups="analytic.group_analytic_accounting" id="next_id_40"
146 name="Analytic" parent="account.menu_finance_generic_reporting"
149 <record id="view_account_analytic_line_form" model="ir.ui.view">
150 <field name="name">account.analytic.line.form</field>
151 <field name="model">account.analytic.line</field>
152 <field name="type">form</field>
153 <field name="arch" type="xml">
154 <form string="Analytic Entry">
155 <group colspan="4" col="6">
158 <field name="account_id"/>
159 <field name="journal_id"/>
161 <field name="company_id" groups="base.group_multi_company"/>
163 <group colspan="2" col="4">
164 <separator string="Amount" colspan="4"/>
165 <field name="amount" colspan="4"/>
166 <field name="amount_currency" colspan="2"/>
167 <field name="currency_id" colspan="2" nolabel="1"/>
169 <group colspan="2" col="4">
170 <separator string="Product Information" colspan="4"/>
171 <field name="product_id" colspan="4"/>
172 <field name="unit_amount" colspan="2"/>
173 <field name="product_uom_id" colspan="2" nolabel="1"/>
175 <group colspan="2" col="2" groups="base.group_extended">
176 <separator string="General Accounting" colspan="2"/>
177 <field name="general_account_id"/>
178 <field name="move_id" readonly="1"/>
183 <record id="view_account_analytic_line_tree" model="ir.ui.view">
184 <field name="name">account.analytic.line.tree</field>
185 <field name="model">account.analytic.line</field>
186 <field name="type">tree</field>
187 <field name="arch" type="xml">
188 <tree editable="top" string="Analytic Entries">
190 <field name="ref" invisible="context.get('to_invoice', False)"/>
192 <field name="journal_id" invisible="context.get('to_invoice', False)"/>
193 <field name="amount" sum="Total" invisible="context.get('to_invoice', False)"/>
194 <field name="product_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id, journal_id)" invisible="not context.get('to_invoice', False)"/>
195 <field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" sum="Total Quantity"/>
196 <field name="product_uom_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" invisible="not context.get('to_invoice', False)"/>
197 <field domain="[('type','=','normal')]" name="account_id"/>
198 <field name="general_account_id" invisible="context.get('to_invoice', False)"/>
199 <field name="user_id" invisible="1" />
203 <record id="view_account_analytic_line_filter" model="ir.ui.view">
204 <field name="name">account.analytic.line.select</field>
205 <field name="model">account.analytic.line</field>
206 <field name="type">search</field>
207 <field name="arch" type="xml">
208 <search string="Search Analytic Lines">
210 <filter name="sales" string="Sales" domain="[('journal_id.type','=','sale')]" icon="terp-camera_test" help="Analytic Journal Items related to a sale journal."/>
211 <filter name="purchases" string="Purchases" domain="[('journal_id.type','=','purchase')]" icon="terp-purchase" help="Analytic Journal Items related to a purchase journal."/>
212 <filter name="others" string="Others" domain="[('journal_id.type','in',('cash','general','situation'))]" icon="terp-folder-orange"/>
213 <separator orientation="vertical"/>
216 <field name="account_id"/>
217 <field name="user_id">
218 <filter string="My Entries" domain="[('user_id','=',uid)]" icon="terp-personal"/>
222 <group string="Group By..." expand="0">
223 <filter string="Account" context="{'group_by':'account_id'}" groups="base.group_extended" icon="terp-folder-green"/>
224 <filter string="Journal" context="{'group_by':'journal_id'}" icon="terp-folder-orange"/>
225 <filter string="User" context="{'group_by':'user_id'}" icon="terp-personal"/>
226 <separator orientation="vertical"/>
227 <filter string="Fin.Account" context="{'group_by':'general_account_id'}" icon="terp-folder-green"/>
228 <separator orientation="vertical"/>
229 <filter string="Product" context="{'group_by':'product_id'}" icon="terp-accessories-archiver"/>
234 <record id="action_account_analytic_line_form" model="ir.actions.act_window">
235 <field name="name">Analytic Entries</field>
236 <field name="type">ir.actions.act_window</field>
237 <field name="res_model">account.analytic.line</field>
238 <field name="view_type">form</field>
239 <field name="context">{"search_default_user_id":uid}</field>
240 <field name="view_id" ref="view_account_analytic_line_tree"/>
243 <!-- Entries by Line -->
245 <record id="action_account_tree1" model="ir.actions.act_window">
246 <field name="name">Analytic Items</field>
247 <field name="res_model">account.analytic.line</field>
248 <field name="view_type">form</field>
249 <field name="view_mode">tree,form</field>
250 <field name="domain">[('account_id','child_of',[active_id])]</field>
251 <field name="context">{'account_id':active_id}</field>
252 <field name="search_view_id" ref="view_account_analytic_line_filter"/>
254 <record id="ir_open_account_analytic_account" model="ir.values">
255 <field eval="'tree_but_open'" name="key2"/>
256 <field eval="'account.analytic.account'" name="model"/>
257 <field name="name">Open Account Tree</field>
258 <field eval="'ir.actions.act_window,%d'%action_account_tree1" name="value"/>
261 <record id="account_analytic_line_extended_form" model="ir.ui.view">
262 <field name="name">account.analytic.line.extended_form</field>
263 <field name="model">account.analytic.line</field>
264 <field name="type">form</field>
265 <field name="arch" type="xml">
266 <form string="Project line">
268 <field name="account_id" groups="base.group_extended"/>
269 <field name="date" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)"/>
270 <field name="journal_id"/>
271 <field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)"/>
272 <field name="product_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id, journal_id)"/>
273 <field name="product_uom_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)"/>
274 <field invisible="True" name="general_account_id"/>
275 <field name="amount"/>
276 <field name="currency_id" />
277 <field name="amount_currency" />
278 <field name="company_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)"/>
282 <record id="action_account_analytic_account_line_extended_form" model="ir.actions.act_window">
283 <field name="name">account.analytic.line.extended</field>
284 <field name="type">ir.actions.act_window</field>
285 <field name="res_model">account.analytic.line</field>
286 <field name="view_type">form</field>
287 <field name="view_id" ref="account_analytic_line_extended_form"/>
294 <record id="view_account_analytic_journal_tree" model="ir.ui.view">
295 <field name="name">account.analytic.journal.tree</field>
296 <field name="model">account.analytic.journal</field>
297 <field name="type">tree</field>
298 <field name="arch" type="xml">
299 <tree string="Analytic Journal">
307 <record id="view_analytic_journal_search" model="ir.ui.view">
308 <field name="name">account.analytic.journal.search</field>
309 <field name="model">account.analytic.journal</field>
310 <field name="type">search</field>
311 <field name="arch" type="xml">
312 <search string="Analytic Journals">
319 <group expand="0" string="Group By...">
320 <filter string="Type" icon="terp-stock_symbol-selection" domain="[]" context="{'group_by':'type'}"/>
326 <record id="view_account_analytic_journal_form" model="ir.ui.view">
327 <field name="name">account.analytic.journal.form</field>
328 <field name="model">account.analytic.journal</field>
329 <field name="type">form</field>
330 <field name="arch" type="xml">
331 <form string="Analytic Journal">
332 <field name="name" select="1"/>
333 <field name="code" select="1"/>
334 <field name="type" select="2"/>
335 <field name="active" select="2"/>
336 <field name="company_id" groups="base.group_multi_company" widget="selection"/>
340 <record id="action_account_analytic_journal_form" model="ir.actions.act_window">
341 <field name="name">Analytic Journals</field>
342 <field name="res_model">account.analytic.journal</field>
343 <field name="view_type">form</field>
344 <field name="view_mode">tree,form</field>
345 <field name="search_view_id" ref="view_analytic_journal_search" />
347 <menuitem groups="analytic.group_analytic_accounting" action="action_account_analytic_journal_form" id="account_def_analytic_journal" parent="menu_analytic_accounting" sequence="5"/>
350 # Open journal entries
353 <record id="action_account_analytic_journal_open_form" model="ir.actions.act_window">
354 <field name="name">Analytic Journal Items</field>
355 <field name="res_model">account.analytic.line</field>
356 <field name="view_type">form</field>
357 <field name="view_mode">tree,form</field>
359 <menuitem groups="analytic.group_analytic_accounting"
360 action="action_account_analytic_journal_open_form"
361 id="account_analytic_journal_entries"
362 parent="menu_finance_entries"/>
368 <record id="action_account_analytic_journal_tree" model="ir.actions.act_window">
369 <field name="name">Print Analytic Journals</field>
370 <field name="res_model">account.analytic.journal</field>
371 <field name="view_type">tree</field>
372 <field name="help">To print an analytics (or costs) journal for a given period. The report give code, move name, account number, general amount and analytic amount.</field>
374 <menuitem groups="analytic.group_analytic_accounting"
375 action="action_account_analytic_journal_tree"
376 id="account_analytic_journal_print" parent="account.next_id_40"/>
382 <record id="report_hr_timesheet_invoice_journal_form" model="ir.ui.view">
383 <field name="name">report.hr.timesheet.invoice.journal.form</field>
384 <field name="model">report.hr.timesheet.invoice.journal</field>
385 <field name="type">form</field>
386 <field name="arch" type="xml">
387 <form string="Analytic Entries Stats">
388 <field name="name" select="1"/>
389 <field name="account_id" select="1"/>
390 <field name="journal_id" select="2"/>
396 <record id="report_hr_timesheet_invoice_journal_tree" model="ir.ui.view">
397 <field name="name">report.hr.timesheet.invoice.journal.tree</field>
398 <field name="model">report.hr.timesheet.invoice.journal</field>
399 <field name="type">tree</field>
400 <field name="arch" type="xml">
401 <tree string="Analytic Entries Stats">
403 <field name="month"/>
404 <field name="account_id"/>
405 <field name="journal_id"/>
406 <field name="quantity"/>
407 <field name="revenue"/>
413 <record id="report_hr_timesheet_invoice_journal_graph" model="ir.ui.view">
414 <field name="name">report.hr.timesheet.invoice.journal.graph</field>
415 <field name="model">report.hr.timesheet.invoice.journal</field>
416 <field name="type">graph</field>
417 <field name="arch" type="xml">
418 <graph string="Analytic Entries Stats" type="bar">
420 <field name="month"/>
421 <field name="cost" operator="+"/>
422 <field name="revenue" operator="+"/>
423 <field group="True" name="journal_id"/>
428 <record id="report_hr_timesheet_invoice_journal_search" model="ir.ui.view">
429 <field name="name">report.hr.timesheet.invoice.journal.search</field>
430 <field name="model">report.hr.timesheet.invoice.journal</field>
431 <field name="type">search</field>
432 <field name="arch" type="xml">
433 <search string="Analytic Entries Stats">
435 <filter icon="terp-go-year" string="This Year" domain="[('name','=',time.strftime('%%Y'))]" help="Sale journal in this year"/>
436 <filter icon="terp-go-month" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Sale journal in this month"/>
437 <separator orientation="vertical"/>
439 <field name="month"/>
440 <field name="account_id"/>
447 context="{'search_default_account_id': [active_id], 'search_default_user_id': False, 'default_account_id': active_id}"
448 id="act_acc_analytic_acc_5_report_hr_timesheet_invoice_journal"
449 name="All Analytic Entries"
450 res_model="account.analytic.line"
451 src_model="account.analytic.account"
452 view_mode="tree,form"
455 <record id="view_account_journal_1" model="ir.ui.view">
456 <field name="name">account.journal.form.1</field>
457 <field name="model">account.journal</field>
458 <field name="inherit_id" ref="account.view_account_journal_form"/>
459 <field name="type">form</field>
460 <field name="arch" type="xml">
461 <field name="currency" position="after">
462 <field name="analytic_journal_id"/>
467 <record id="analytic_accounts_graph" model="ir.ui.view">
468 <field name="name">analytic.accounts.graph</field>
469 <field name="model">account.analytic.account</field>
470 <field name="type">graph</field>
471 <field name="arch" type="xml">
472 <graph string="Analytic Account Statistics" type="bar">
473 <field name="complete_name"/>
474 <field name="balance" operator="+"/>