[MERGE] By default, If contract is installed, the group for (group_analytic_account_for_sales) should be assigned

lp:~openerp-dev/openobject-addons/trunk-addons9-contract-apa-group-tpa

bzr revid: jam@tinyerp.com-20120914094221-ul7fvnedigl3rlvz
This commit is contained in:
Jigar Amin - OpenERP 2012-09-14 15:12:21 +05:30
commit 2e47edfbb4
4 changed files with 42 additions and 2 deletions

View File

@ -36,6 +36,7 @@ Adds menu to show relevant information to each manager.You can also view the rep
'depends': ['hr_timesheet_invoice', 'sale'], #although sale is technically not required to install this module, all menuitems are located under 'Sales' application
'data': [
'security/ir.model.access.csv',
'security/account_analytic_analysis_security.xml',
'account_analytic_analysis_view.xml',
'account_analytic_analysis_menu.xml',
'account_analytic_analysis_cron.xml',

View File

@ -73,9 +73,18 @@
<field name="res_model">account.analytic.account</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form,graph</field>
<field name="context">{'default_type':'contract'}</field>
<field name="context">{'default_type':'contract', 'search_default_draft':1, 'search_default_pending':1, 'search_default_open':1, 'search_default_renew':1}</field>
<field name="domain">[('type','=','contract')]</field>
<field name="search_view_id" ref="view_account_analytic_account_overdue_search"/>
<field name="help" type="html">
<p class="oe_view_nocontent_create">
Click to create a new contract.
</p><p>
You can use the way you invoice each contract (timesheet, fixed price, charge employees expenses).
</p><p>
A template can be used to set automatically all invoicing information.
</p>
</field>
</record>
<menuitem id="base.menu_sales" name="Sales"
parent="base.menu_base_partner"

View File

@ -18,8 +18,18 @@
<field name="inherit_id" ref="analytic.view_account_analytic_account_form"/>
<field eval="40" name="priority"/>
<field name="arch" type="xml">
<xpath expr='//field[@name="name"]' position="after" version="7.0">
<h4>
<label for="date_start" string="Start Date"/>
</h4>
<div>
<h1>
<field name="date_start" class="oe_inline"/>
</h1>
</div>
</xpath>
<xpath expr='//div[@name="duration"]' position="after" version="7.0">
<label for="quantity_max"/>
<label for="quantity_max" string="Prepaid Time Unit"/>
<div>
<field name="quantity_max" class="oe_inline"/>
</div>
@ -140,6 +150,16 @@
<field name="view_mode">tree,form</field>
<field name="domain">[('type','=','template')]</field>
<field name="context">{'search_default_type':'template','default_type' : 'template'}</field>
<field name="help" type="html">
<p class="oe_view_nocontent_create">
Click here to create a Template of contract.
</p><p>
Templates are used to prefigure contract/project that
can be selected by the salespeople to create their customer
contract/project from the menu Sales/Contracts.
</p>
</field>
</record>
<menuitem action="template_of_contract_action" id="menu_template_of_contract_action" parent="base.menu_base_config"/>
</data>

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<record model="res.users" id="base.user_root">
<field eval="[(4,ref('sale.group_analytic_accounting'))]" name="groups_id"/>
</record>
</data>
</openerp>