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 eval="8" name="priority"/>
9 <field name="arch" type="xml">
10 <tree toolbar="1" colors="red:state=='pending';grey:state in ('cancelled','close');blue:type=='view'" string="Analytic Accounts">
11 <field name="complete_name"/>
13 <field name="quantity"/>
15 <field name="date_start" invisible="1"/>
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"/>
21 <field name="company_id" groups="base.group_multi_company"/>
26 <record id="view_account_analytic_account_search" model="ir.ui.view">
27 <field name="name">account.analytic.account.search</field>
28 <field name="model">account.analytic.account</field>
29 <field name="arch" type="xml">
30 <search string="Analytic Account">
31 <field name="name" filter_domain="['|', ('name','ilike',self), ('code','ilike',self)]" string="Analytic Account"/>
33 <filter icon="terp-gtk-media-pause" string="Pending" domain="[('state','=','pending')]" help="Pending Accounts"/>
34 <filter icon="terp-camera_test" string="Current" domain="[('state','=','open')]" help="Current Accounts"/>
35 <field name="partner_id"/>
36 <field name="user_id"/>
37 <group expand="0" string="Group By...">
38 <filter string="Manager" icon="terp-personal" domain="[]" context="{'group_by':'user_id'}"/>
39 <filter string="Associated Partner" icon="terp-partner" domain="[]" context="{'group_by':'partner_id'}"/>
40 <filter string="Parent Account" icon="terp-folder-green" domain="[]" context="{'group_by':'parent_id'}"/>
41 <filter string="Status" icon="terp-stock_effects-object-colorize" domain="[]" context="{'group_by':'state'}" groups="base.group_no_one"/>
47 <record id="view_account_analytic_account_tree" model="ir.ui.view">
48 <field name="name">account.analytic.account.tree</field>
49 <field name="model">account.analytic.account</field>
50 <field name="field_parent">child_complete_ids</field>
51 <field name="arch" type="xml">
52 <tree colors="blue:state=='pending';grey:state in ('close','cancelled');blue:type=='view'" string="Analytic account" toolbar="1">
53 <field name="complete_name"/>
56 <field name="credit"/>
57 <field name="balance"/>
58 <field name="state" invisible="1"/>
59 <field name="currency_id" groups="base.group_multi_currency"/>
60 <field name="date" invisible="1"/>
61 <field name="user_id" invisible="1"/>
62 <field name="partner_id" invisible="1"/>
63 <field name="parent_id" invisible="1"/>
65 <field name="company_id" groups="base.group_multi_company"/>
71 <record id="action_account_analytic_account_form" model="ir.actions.act_window">
72 <field name="name">Analytic Accounts</field>
73 <field name="type">ir.actions.act_window</field>
74 <field name="res_model">account.analytic.account</field>
75 <field name="view_type">form</field>
76 <field name="view_mode">tree,form</field>
77 <field name="view_id" ref="view_account_analytic_account_tree"/>
78 <field name="search_view_id" ref="account.view_account_analytic_account_search"/>
80 <menuitem action="action_account_analytic_account_form" id="account_analytic_def_account"
81 parent="menu_analytic_accounting"
82 groups="analytic.group_analytic_accounting"/>
84 <record id="act_account_renew_view" model="ir.actions.act_window">
85 <field name="name">Accounts to Renew</field>
86 <field name="type">ir.actions.act_window</field>
87 <field name="res_model">account.analytic.account</field>
88 <field name="view_type">form</field>
89 <field name="view_mode">tree,form</field>
90 <field name="domain">[('date','<',time.strftime('%Y-%m-%d %H:%M:%S'))]</field>
91 <field name="filter" eval="True"/>
94 <record id="action_account_analytic_account_tree2" model="ir.actions.act_window">
95 <field name="name">Chart of Analytic Accounts</field>
96 <field name="res_model">account.analytic.account</field>
97 <field name="view_type">tree</field>
98 <field name="view_id" ref="view_account_analytic_account_tree"/>
99 <field name="domain">[('parent_id','=',False)]</field>
100 <field name="help" type="html">
102 Click to add a new analytic account.
104 The normal chart of accounts has a structure defined by the
105 legal requirement of the country. The analytic chart of
106 accounts structure should reflect your own business needs in
107 term of costs/revenues reporting.
109 They are usually structured by contracts, projects, products or
110 departements. Most of the OpenERP operations (invoices,
111 timesheets, expenses, etc) generate analytic entries on the
118 <record id="view_account_analytic_line_form" model="ir.ui.view">
119 <field name="name">account.analytic.line.form</field>
120 <field name="model">account.analytic.line</field>
121 <field name="priority">1</field>
122 <field name="arch" type="xml">
123 <form string="Analytic Entry" version="7.0">
127 <field name="account_id"/>
128 <field name="journal_id"/>
133 <field name="company_id" groups="base.group_multi_company"/>
135 <group string="Amount">
136 <field name="amount"/>
137 <label for="amount_currency" groups="base.group_multi_currency"/>
138 <div groups="base.group_multi_currency">
139 <field name="amount_currency" class="oe_inline"/>
140 <field name="currency_id" class="oe_inline"/>
143 <group string="Product Information">
144 <field name="product_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id, journal_id)"/>
145 <label for="unit_amount"/>
147 <field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" class="oe_inline"/>
148 <field name="product_uom_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" class="oe_inline"/>
151 <group string="General Accounting">
152 <field name="general_account_id"/>
153 <field name="move_id" readonly="1"/>
159 <record id="view_account_analytic_line_tree" model="ir.ui.view">
160 <field name="name">account.analytic.line.tree</field>
161 <field name="model">account.analytic.line</field>
162 <field name="arch" type="xml">
163 <tree string="Analytic Entries">
165 <field name="ref" invisible="context.get('to_invoice', False)"/>
167 <field name="journal_id" invisible="context.get('to_invoice', False)"/>
168 <field name="amount" sum="Total" invisible="context.get('to_invoice', False)"/>
169 <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)"/>
170 <field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" sum="Total Quantity"/>
171 <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)"/>
172 <field domain="[('type','=','normal')]" name="account_id"/>
173 <field name="general_account_id" invisible="context.get('to_invoice', False)"/>
174 <field name="user_id" invisible="1" />
175 <field name="company_id" groups="base.group_multi_company"/>
179 <record id="view_account_analytic_line_filter" model="ir.ui.view">
180 <field name="name">account.analytic.line.select</field>
181 <field name="model">account.analytic.line</field>
182 <field name="arch" type="xml">
183 <search string="Search Analytic Lines">
184 <field name="name" string="Analytic Line"/>
186 <filter name="sales" string="Sales" domain="[('journal_id.type','=','sale')]" help="Analytic Journal Items related to a sale journal."/>
187 <filter name="purchases" string="Purchases" domain="[('journal_id.type','=','purchase')]" help="Analytic Journal Items related to a purchase journal."/>
188 <filter name="others" string="Others" domain="[('journal_id.type','in',('cash','general','situation'))]"/>
190 <filter string="My Entries" domain="[('user_id','=',uid)]"/>
191 <field name="account_id"/>
192 <field name="user_id"/>
193 <group string="Group By..." expand="0">
194 <filter string="Analytic Account" context="{'group_by':'account_id'}"/>
195 <filter string="Fin. Account" context="{'group_by':'general_account_id'}"/>
196 <filter string="Journal" context="{'group_by':'journal_id'}" name="group_journal"/>
198 <filter string="Product" context="{'group_by':'product_id'}"/>
199 <filter string="User" context="{'group_by':'user_id'}"/>
201 <filter string="Date" context="{'group_by':'date'}" name="group_date"/>
207 <record id="action_account_analytic_line_form" model="ir.actions.act_window">
208 <field name="name">Analytic Entries</field>
209 <field name="type">ir.actions.act_window</field>
210 <field name="res_model">account.analytic.line</field>
211 <field name="view_type">form</field>
212 <field name="context">{"search_default_user_id":uid}</field>
213 <field name="view_id" ref="view_account_analytic_line_tree"/>
216 <!-- Entries by Line -->
218 <record id="action_account_tree1" model="ir.actions.act_window">
219 <field name="name">Analytic Items</field>
220 <field name="res_model">account.analytic.line</field>
221 <field name="view_type">form</field>
222 <field name="view_mode">tree,form</field>
223 <field name="domain">[('account_id','child_of',[active_id])]</field>
224 <field name="context">{'account_id':active_id}</field>
225 <field name="search_view_id" ref="view_account_analytic_line_filter"/>
227 <record id="ir_open_account_analytic_account" model="ir.values">
228 <field eval="'tree_but_open'" name="key2"/>
229 <field eval="'account.analytic.account'" name="model"/>
230 <field name="name">Open Account Tree</field>
231 <field eval="'ir.actions.act_window,%d'%action_account_tree1" name="value"/>
234 <record id="account_analytic_line_extended_form" model="ir.ui.view">
235 <field name="name">account.analytic.line.extended_form</field>
236 <field name="model">account.analytic.line</field>
237 <field name="arch" type="xml">
238 <form string="Project line" version="7.0">
242 <field name="account_id"/>
243 <field name="journal_id"/>
246 <field name="date" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)"/>
247 <field name="company_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)"/>
249 <group string="Amount">
250 <field name="amount"/>
251 <label for="amount_currency" groups="base.group_multi_currency"/>
252 <div groups="base.group_multi_currency">
253 <field name="amount_currency" class="oe_inline"/>
254 <field name="currency_id" class="oe_inline"/>
256 <field invisible="1" name="general_account_id"/>
258 <group string="Product Information">
259 <field name="product_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id, journal_id)"/>
260 <label for="unit_amount"/>
262 <field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" class="oe_inline"/>
263 <field name="product_uom_id" on_change="on_change_unit_amount(product_id, unit_amount, company_id, product_uom_id)" class="oe_inline"/>
270 <record id="action_account_analytic_account_line_extended_form" model="ir.actions.act_window">
271 <field name="name">account.analytic.line.extended</field>
272 <field name="type">ir.actions.act_window</field>
273 <field name="res_model">account.analytic.line</field>
274 <field name="view_type">form</field>
275 <field name="view_id" ref="account_analytic_line_extended_form"/>
282 <record id="view_account_analytic_journal_tree" model="ir.ui.view">
283 <field name="name">account.analytic.journal.tree</field>
284 <field name="model">account.analytic.journal</field>
285 <field name="arch" type="xml">
286 <tree string="Analytic Journal">
294 <record id="view_analytic_journal_search" model="ir.ui.view">
295 <field name="name">account.analytic.journal.search</field>
296 <field name="model">account.analytic.journal</field>
297 <field name="arch" type="xml">
298 <search string="Analytic Journals">
299 <field name="name" filter_domain="['|', ('name','ilike',self), ('code','ilike',self)]" string="Analytic Journal"/>
301 <group expand="0" string="Group By...">
302 <filter string="Type" icon="terp-stock_symbol-selection" domain="[]" context="{'group_by':'type'}"/>
308 <record id="view_account_analytic_journal_form" model="ir.ui.view">
309 <field name="name">account.analytic.journal.form</field>
310 <field name="model">account.analytic.journal</field>
311 <field name="arch" type="xml">
312 <form string="Analytic Journal" version="7.0">
317 <field name="active"/>
318 <field name="company_id" groups="base.group_multi_company"/>
323 <record id="action_account_analytic_journal_form" model="ir.actions.act_window">
324 <field name="name">Analytic Journals</field>
325 <field name="res_model">account.analytic.journal</field>
326 <field name="view_type">form</field>
327 <field name="view_mode">tree,form</field>
328 <field name="search_view_id" ref="view_analytic_journal_search" />
330 <menuitem groups="analytic.group_analytic_accounting" action="action_account_analytic_journal_form" id="account_def_analytic_journal" parent="menu_analytic_accounting" sequence="5"/>
333 # Open journal entries
336 <record id="action_account_analytic_journal_open_form" model="ir.actions.act_window">
337 <field name="name">Analytic Journal Items</field>
338 <field name="res_model">account.analytic.line</field>
339 <field name="view_type">form</field>
340 <field name="view_mode">tree,form</field>
342 <menuitem groups="analytic.group_analytic_accounting"
343 action="action_account_analytic_journal_open_form"
344 id="account_analytic_journal_entries"
345 parent="menu_finance_entries"/>
352 <record id="view_account_journal_1" model="ir.ui.view">
353 <field name="name">account.journal.form.1</field>
354 <field name="model">account.journal</field>
355 <field name="inherit_id" ref="account.view_account_journal_form"/>
356 <field name="arch" type="xml">
357 <field name="type" position="after">
358 <field name="analytic_journal_id"/>