Browse Source

[IMP] - Adapt contract sale to contract new views

pull/207/head
sbejaoui 6 years ago
parent
commit
e9daa5b781
  1. 5
      contract_sale/__manifest__.py
  2. 18
      contract_sale/views/abstract_contract_line.xml
  3. 28
      contract_sale/views/account_analytic_account_view.xml
  4. 12
      contract_sale/views/contract.xml
  5. 18
      contract_sale/views/contract_line.xml
  6. 0
      contract_sale/views/contract_template.xml

5
contract_sale/__manifest__.py

@ -15,8 +15,9 @@
'data': [
'security/ir.model.access.csv',
'security/account_analytic_account_security.xml',
'views/account_analytic_account_view.xml',
'views/account_analytic_contract_view.xml',
'views/contract.xml',
'views/contract_line.xml',
'views/contract_template.xml',
],
'license': 'AGPL-3',
'installable': True,

18
contract_sale/views/abstract_contract_line.xml

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="account_abstract_analytic_contract_line_view_form"
model="ir.ui.view">
<field name="name">account.abstract.analytic.contract.line.form (in contract_sale)</field>
<field name="model">account.abstract.analytic.contract.line</field>
<field name="inherit_id"
ref="contract.account_abstract_analytic_contract_line_view_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='discount']" position="attributes">
<attribute name="groups">sale.group_discount_per_so_line
</attribute>
</xpath>
</field>
</record>
</odoo>

28
contract_sale/views/account_analytic_account_view.xml

@ -1,28 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="account_analytic_account_recurring_form_form"
model="ir.ui.view">
<field name="name">Contract form (in contract_sale)</field>
<field name="model">account.analytic.account</field>
<field name="inherit_id"
ref="contract.account_analytic_account_recurring_form_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='discount']" position="attributes">
<attribute name="groups">sale.group_discount_per_so_line
</attribute>
</xpath>
</field>
</record>
<menuitem
id="menu_contract_sale" name="Contracts"
parent="sale.sale_order_menu"
action="contract.action_account_analytic_sale_overdue_all"
sequence="2"
groups="sales_team.group_sale_salesman"
/>
</odoo>

12
contract_sale/views/contract.xml

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<menuitem
id="menu_contract_sale" name="Contracts"
parent="sale.sale_order_menu"
action="contract.action_account_analytic_sale_overdue_all"
sequence="2"
groups="sales_team.group_sale_salesman"
/>
</odoo>

18
contract_sale/views/contract_line.xml

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="account_analytic_invoice_line_view_tree"
model="ir.ui.view">
<field name="name">account.analytic.invoice.line.tree (in contract_sale)</field>
<field name="model">account.analytic.invoice.line</field>
<field name="inherit_id"
ref="contract.account_analytic_invoice_line_view_tree"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='discount']" position="attributes">
<attribute name="groups">sale.group_discount_per_so_line
</attribute>
</xpath>
</field>
</record>
</odoo>

0
contract_sale/views/account_analytic_contract_view.xml → contract_sale/views/contract_template.xml

Loading…
Cancel
Save