[FIX] sale_timesheet: hide 'create SO' on project

This button requires the rights to handle SO (create and update), so we now
only display this button if current user can do such action. Otherwise, when
submitting the wizard, the user gets an access error.
This commit is contained in:
jem-odoo
2018-09-07 14:06:49 +02:00
parent c31cebfe27
commit aee642939c
@@ -7,7 +7,7 @@
<field name="inherit_id" ref="project.edit_project"/>
<field name="arch" type="xml">
<xpath expr="//header" position="inside">
<button name="action_make_billable" string="Create Sales Order" type="object" attrs="{'invisible': [('billable_type', '!=', 'no')]}"/>
<button name="action_make_billable" string="Create Sales Order" type="object" attrs="{'invisible': [('billable_type', '!=', 'no')]}" group="sale.group_sale_salesman"/>
</xpath>
<xpath expr="//page[@name='emails']" position="after">
<page name="billing_employee_rate" string="Invoicing" attrs="{'invisible': [('billable_type', '=', 'no')]}">