mirror of
https://github.com/OCA/contract.git
synced 2025-02-13 17:57:24 +02:00
[ADD] product_contract: Create module
* Add contract functionality to `product.templates` * Add logic to create contracts from `sale.order` that contains contract products.
This commit is contained in:
29
product_contract/views/product_template_view.xml
Normal file
29
product_contract/views/product_template_view.xml
Normal file
@@ -0,0 +1,29 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<!--
|
||||
Copyright 2017 LasLabs Inc.
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||
-->
|
||||
|
||||
<odoo>
|
||||
|
||||
<record id="product_template_form_contract_view" model="ir.ui.view">
|
||||
<field name="name">account.invoice.select.contract</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="product.product_template_form_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//div[@name='options']" position="inside">
|
||||
<div>
|
||||
<field name="is_contract" />
|
||||
<label for="is_contract" />
|
||||
</div>
|
||||
</xpath>
|
||||
<xpath expr="//group[@name='group_standard_price']" position="inside">
|
||||
<field name="contract_template_id"
|
||||
attrs="{'invisible': [('is_contract', '=', False)],
|
||||
'required':[('is_contract', '=', True)]}" />
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user