1 <?xml version="1.0" encoding="utf-8"?>
4 <record id="account_analytic_account_form_form" model="ir.ui.view">
5 <field name="name">account.analytic.account.invoice.form</field>
6 <field name="model">account.analytic.account</field>
7 <field name="priority">30</field>
8 <field name="inherit_id" ref="analytic.view_account_analytic_account_form"/>
9 <field name="arch" type="xml">
10 <xpath expr='//separator[@name="description"]' position='before'>
11 <group string="Invoice on Timesheets Options" name="invoice_on_timesheets" col="4">
12 <field name="pricelist_id" />
13 <field name="to_invoice" widget="selection"/>
16 <xpath expr="//field[@name='use_timesheets']" position="replace">
17 <field name="use_timesheets" on_change="on_change_use_timesheets(use_timesheets, context)"/>
19 <xpath expr="/form/sheet" position='before'>
21 <button name="set_pending" string="Pending" type="object" states="open" />
22 <button name="set_close" string="Close" type="object" states="open,pending" />
23 <button name="set_open" string="Re-open project" type="object" states="pending,close" />
24 <button name="set_open" string="Re-open project" type="object" states="cancelled,draft"/>
25 <button name="set_cancel" string="Cancel" type="object" states="open,pending"/>
26 <field name="state" readonly="1" widget="statusbar"
27 statusbar_visible="open,pending,close" statusbar_colors='{"pending":"red", "template":"blue"}'/>
33 <record id="hr_timesheet_line_form" model="ir.ui.view">
34 <field name="name">hr.analytic.timesheet.form</field>
35 <field name="model">hr.analytic.timesheet</field>
36 <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_form"/>
37 <field name="arch" type="xml">
38 <xpath expr="//group[@string='Accounting']" position='after'>
39 <group string="Invoicing">
40 <field name="to_invoice"/>
41 <field name="invoice_id"/>
47 <record id="hr_timesheet_line_form2" model="ir.ui.view">
48 <field name="name">hr.analytic.timesheet.form2</field>
49 <field name="model">hr.analytic.timesheet</field>
50 <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_form"/>
51 <field name="arch" type="xml">
52 <field name="account_id" position="replace">
53 <field domain="[('type','in',['normal','contract']),('state', '<>', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id)" context="{'default_use_timesheets': 1}"/>
58 <record id="hr_timesheet_line_tree" model="ir.ui.view">
59 <field name="name">hr.analytic.timesheet.tree</field>
60 <field name="model">hr.analytic.timesheet</field>
61 <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_tree"/>
62 <field name="arch" type="xml">
63 <field name="amount" position="after">
64 <field name="to_invoice"/>
69 <record id="hr_timesheet_line_tree2" model="ir.ui.view">
70 <field name="name">hr.analytic.timesheet.tree2</field>
71 <field name="model">hr.analytic.timesheet</field>
72 <field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_tree"/>
73 <field name="arch" type="xml">
74 <field name="account_id" position="replace">
75 <field domain="[('type','in',['normal','contract']),('state', '<>', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id)" context="{'default_use_timesheets': 1}"/>
80 <!-- Inherits for account analytic lines -->
81 <record id="view_account_analytic_line_search_inherit" model="ir.ui.view">
82 <field name="name">account.analytic.line.search.to_invoice</field>
83 <field name="model">account.analytic.line</field>
84 <field name="inherit_id" ref="account.view_account_analytic_line_filter"/>
85 <field name="arch" type="xml">
86 <xpath expr="//filter[@name='others']" position="after">
88 <filter name="to_invoice" string="To Invoice" context="{'to_invoice': 1}" domain="[('invoice_id','=',False), ('to_invoice','<>',False)]" icon="terp-dolar"/>
89 <filter name="invoiced" string="Invoiced" domain="[('invoice_id','!=',False), ('to_invoice','<>',False)]" icon="terp-dolar"/>
94 <record id="view_account_analytic_line_tree_inherit" model="ir.ui.view">
95 <field name="name">account.analytic.line.tree.to_invoice</field>
96 <field name="model">account.analytic.line</field>
97 <field name="inherit_id" ref="account.view_account_analytic_line_tree"/>
98 <field name="arch" type="xml">
99 <field name="account_id" position="after">
100 <field name="to_invoice"/>
104 <record id="view_account_analytic_line_form_inherit" model="ir.ui.view">
105 <field name="name">account.analytic.line.form.to_invoice</field>
106 <field name="model">account.analytic.line</field>
107 <field name="inherit_id" ref="account.view_account_analytic_line_form"/>
108 <field name="arch" type="xml">
109 <field name="amount" position="before">
110 <field name="to_invoice"/>
111 <field name="invoice_id"/>
117 <record id="action_hr_analytic_timesheet_open_tree" model="ir.actions.act_window">
118 <field name="name">Invoice Tasks Work</field>
119 <field name="res_model">account.analytic.line</field>
120 <field name="view_type">form</field>
121 <field name="view_mode">tree,form</field>
122 <field name="domain">[]</field>
123 <field name="context">{'search_default_to_invoice': 1}</field>
124 <field name="search_view_id" ref="account.view_account_analytic_line_filter"/>
125 <field name="help" type="html">
126 <p class="oe_view_nocontent_create">
127 Click to add some tasks work to be invoiced.
129 This list shows every task you can invoice to the customer.
130 Select the lines and invoice from the '<i>more...</i>' contextual
131 menu to generate invoices automatically.
136 action="action_hr_analytic_timesheet_open_tree"
137 id="menu_hr_analytic_timesheet_tree"
138 parent="account.menu_finance_periodical_processing_billing"
141 <record id="view_hr_timesheet_invoice_factor_search" model="ir.ui.view">
142 <field name="name">hr_timesheet_invoice.factor.search</field>
143 <field name="model">hr_timesheet_invoice.factor</field>
144 <field name="arch" type="xml">
145 <search string="Type of invoicing">
146 <field name="name" string="Type of invoicing"/>
150 <record id="view_hr_timesheet_invoice_factor_form" model="ir.ui.view">
151 <field name="name">hr_timesheet_invoice.factor.form</field>
152 <field name="model">hr_timesheet_invoice.factor</field>
153 <field name="arch" type="xml">
154 <form string="Type of invoicing" version="7.0">
157 <field name="customer_name"/>
158 <field name="factor"/>
163 <record id="view_hr_timesheet_invoice_factor_tree" model="ir.ui.view">
164 <field name="name">hr_timesheet_invoice.factor.tree</field>
165 <field name="model">hr_timesheet_invoice.factor</field>
166 <field name="arch" type="xml">
167 <tree string="Types of invoicing">
169 <field name="customer_name"/>
170 <field name="factor"/>
174 <record id="action_hr_timesheet_invoice_factor_form" model="ir.actions.act_window">
175 <field name="name">Types of Invoicing</field>
176 <field name="type">ir.actions.act_window</field>
177 <field name="res_model">hr_timesheet_invoice.factor</field>
178 <field name="view_type">form</field>
179 <field name="view_id" ref="view_hr_timesheet_invoice_factor_tree"/>
180 <field name="search_view_id" ref="view_hr_timesheet_invoice_factor_search"/>
181 <field name="help" type="html">
182 <p class="oe_view_nocontent_create">
183 Click to add a new type of invoicing.
185 OpenERP allows you to create default invoicing types. You might
186 have to regularly assign discounts because of a specific
187 contract or agreement with a customer. From this menu, you can
188 create additional types of invoicing to speed up your
194 action="action_hr_timesheet_invoice_factor_form"
195 id="hr_timesheet_invoice_factor_view"
196 parent="account.menu_configuration_misc" sequence="25" groups="base.group_no_one"/>