285 lines
12 KiB
XML
285 lines
12 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
© 2015-2016 Akretion (http://www.akretion.com/)
|
|
@author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
-->
|
|
|
|
<odoo>
|
|
|
|
|
|
<!-- product.price.history -->
|
|
<record id="product_price_history_form" model="ir.ui.view">
|
|
<field name="name">product.price.history.form</field>
|
|
<field name="model">product.price.history</field>
|
|
<field name="arch" type="xml">
|
|
<form string="Product Price History">
|
|
<group name="main">
|
|
<field name="product_id" invisible="not context.get('product_price_history_main_view')"/>
|
|
<field name="datetime"/>
|
|
<field name="cost" widget="monetary" options="{'currency_field': 'company_currency_id'}"/>
|
|
<field name="company_id" groups="base.group_multi_company"/>
|
|
<field name="company_currency_id" invisible="1"/>
|
|
</group>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_price_history_tree" model="ir.ui.view">
|
|
<field name="name">product.price.history.tree</field>
|
|
<field name="model">product.price.history</field>
|
|
<field name="arch" type="xml">
|
|
<tree string="Product Price History" editable="bottom">
|
|
<field name="product_id" invisible="not context.get('product_price_history_main_view')"/>
|
|
<field name="datetime"/>
|
|
<field name="cost" widget="monetary" options="{'currency_field': 'company_currency_id'}"/>
|
|
<field name="company_id" groups="base.group_multi_company"/>
|
|
<field name="company_currency_id" invisible="1"/>
|
|
</tree>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_price_history_search" model="ir.ui.view">
|
|
<field name="name">product.price.history.search</field>
|
|
<field name="model">product.price.history</field>
|
|
<field name="arch" type="xml">
|
|
<search string="Search Product Price History">
|
|
<field name="product_id"/>
|
|
<group string="Group By" name="groupby">
|
|
<filter name="product_groupby" string="Product" context="{'group_by': 'product_id'}"/>
|
|
<filter name="datetime_groupby" string="Date" context="{'group_by': 'datetime:month'}"/>
|
|
</group>
|
|
</search>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_price_history_action" model="ir.actions.act_window">
|
|
<field name="name">Product Price History</field>
|
|
<field name="res_model">product.price.history</field>
|
|
<field name="view_mode">tree,form</field>
|
|
<field name="context">{'product_price_history_main_view': True}</field>
|
|
</record>
|
|
|
|
<!--
|
|
<menuitem id="product_price_history_menu" action="product_price_history_action"
|
|
parent="product.prod_config_main" sequence="55"/> -->
|
|
|
|
<!-- product.template -->
|
|
<record id="product_template_form_view" model="ir.ui.view">
|
|
<field name="name">usability.product.template.form</field>
|
|
<field name="model">product.template</field>
|
|
<field name="inherit_id" ref="product.product_template_form_view" />
|
|
<field name="arch" type="xml">
|
|
<field name="standard_price" class="oe_inline" position="after">
|
|
<button name="show_product_price_history" class="oe_inline oe_link" type="object" string="Show History" context="{'active_id': active_id}"/>
|
|
</field>
|
|
<!-- Don't make it too big, othesize computers with small resolutions
|
|
will see the product name + image under the block of buttons -->
|
|
<div class="oe_title" position="attributes">
|
|
<attribute name="style">width: 650px;</attribute>
|
|
</div>
|
|
<!-- the 'description' field is defined in the native product modules
|
|
but never displayed in the view -->
|
|
<group name="description" position="inside">
|
|
<separator string="Internal notes" name="internal_description" colspan="4"/>
|
|
<field name="description" colspan="4" nolabel="1"
|
|
placeholder="Notes for internal use."/>
|
|
</group>
|
|
</field>
|
|
</record>
|
|
|
|
<!-- It also adds on product.product search view -->
|
|
<record id="product_template_search_view" model="ir.ui.view">
|
|
<field name="name">usability.product.template.search</field>
|
|
<field name="model">product.template</field>
|
|
<field name="inherit_id" ref="product.product_template_search_view" />
|
|
<field name="arch" type="xml">
|
|
<field name="categ_id" position="after">
|
|
<field name="seller_ids" string="Supplier" filter_domain="[('seller_ids.name', 'ilike', self)]"/>
|
|
</field>
|
|
<field name="pricelist_id" position="after">
|
|
<group string="Group By" name="groupby">
|
|
<filter name="categ_groupby" string="Internal Category" context="{'group_by': 'categ_id'}"/>
|
|
<filter name="type_groupby" string="Type" context="{'group_by': 'type'}"/>
|
|
</group>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_template_tree_view" model="ir.ui.view">
|
|
<field name="name">usability.product.template.tree</field>
|
|
<field name="model">product.template</field>
|
|
<field name="inherit_id" ref="product.product_template_tree_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="list_price" position="after">
|
|
<field name="currency_id" invisible="1"/>
|
|
</field>
|
|
<field name="list_price" position="attributes">
|
|
<attribute name="widget">monetary</attribute>
|
|
</field>
|
|
<field name="standard_price" position="attributes">
|
|
<attribute name="widget">monetary</attribute>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
|
|
<!-- product.product -->
|
|
<record id="product_product_tree_view" model="ir.ui.view">
|
|
<field name="name">usability.product.product.tree</field>
|
|
<field name="model">product.product</field>
|
|
<field name="inherit_id" ref="product.product_product_tree_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="lst_price" position="after">
|
|
<field name="currency_id" invisible="1"/>
|
|
</field>
|
|
<field name="lst_price" position="attributes">
|
|
<attribute name="widget">monetary</attribute>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
|
|
<!-- product.category -->
|
|
<record id="product_category_list_view" model="ir.ui.view">
|
|
<field name="name">usability.product.category.tree</field>
|
|
<field name="model">product.category</field>
|
|
<field name="inherit_id" ref="product.product_category_list_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="display_name" position="after">
|
|
<field name="type"/>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_category_search_view" model="ir.ui.view">
|
|
<field name="name">usability.product.category.search</field>
|
|
<field name="model">product.category</field>
|
|
<field name="inherit_id" ref="product.product_category_search_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="parent_id" position="after">
|
|
<filter name="view" string="View" domain="[('type', '=', 'view')]"/>
|
|
<filter name="normal" string="Normal" domain="[('type', '=', 'normal')]"/>
|
|
<group name="group_by" string="Group By">
|
|
<filter name="type_groupby" string="Type" context="{'group_by': 'type'}"/>
|
|
</group>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
<!-- product.pricelist -->
|
|
|
|
<record id="pricelist_item_fullscreen_action" model="ir.actions.act_window">
|
|
<field name="name">Pricelists Items</field>
|
|
<field name="res_model">product.pricelist.item</field>
|
|
<field name="view_mode">tree,form</field>
|
|
<field name="domain">[('pricelist_id', '=', active_id)]</field>
|
|
<field name="context">{'product_pricelist_item_main_view': True}</field>
|
|
</record>
|
|
|
|
<record id="product_pricelist_view" model="ir.ui.view">
|
|
<field name="name">usability.product.pricelist.form</field>
|
|
<field name="model">product.pricelist</field>
|
|
<field name="inherit_id" ref="product.product_pricelist_view"/>
|
|
<field name="arch" type="xml">
|
|
<div name="button_box" position="inside">
|
|
<button name="%(pricelist_item_fullscreen_action)d"
|
|
class="oe_stat_button"
|
|
icon="fa-building-o"
|
|
type="action"
|
|
help="List view of pricelist items">
|
|
<div class="o_form_field o_stat_info">
|
|
<span class="o_stat_text">Lines Fullscreen</span>
|
|
</div>
|
|
</button>
|
|
</div>
|
|
</field>
|
|
</record>
|
|
|
|
|
|
<record id="product_pricelist_view_tree" model="ir.ui.view">
|
|
<field name="name">usability.product.pricelist.tree</field>
|
|
<field name="model">product.pricelist</field>
|
|
<field name="inherit_id" ref="product.product_pricelist_view_tree"/>
|
|
<field name="arch" type="xml">
|
|
<field name="currency_id" position="after">
|
|
<field name="company_id" groups="base.group_multi_company"/>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
<!-- product.pricelist.item -->
|
|
<record id="product_pricelist_item_search" model="ir.ui.view">
|
|
<field name="name">usability.product.pricelist.item.search</field>
|
|
<field name="model">product.pricelist.item</field>
|
|
<field name="arch" type="xml">
|
|
<search string="Search Pricelist Items">
|
|
<field name="pricelist_id"/>
|
|
<field name="product_tmpl_id"/>
|
|
<field name="product_id"/>
|
|
<field name="categ_id"/>
|
|
<group string="Group By" name="groupby">
|
|
<filter name="pricelist_groupby" string="Pricelist" context="{'group_by': 'pricelist_id'}"/>
|
|
<filter name="applied_on_groupby" string="Apply On" context="{'group_by': 'applied_on'}"/>
|
|
<filter name="base_on_groupby" string="Based On" context="{'group_by': 'base'}"/>
|
|
<filter name="compute_price_groupby" string="Compute Price" context="{'group_by': 'compute_price'}"/>
|
|
<filter name="currency_groupby" string="Currency" context="{'group_by': 'currency_id'}"/>
|
|
</group>
|
|
</search>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_pricelist_item_form_view" model="ir.ui.view">
|
|
<field name="name">usability.product.pricelist.item.form</field>
|
|
<field name="model">product.pricelist.item</field>
|
|
<field name="inherit_id" ref="product.product_pricelist_item_form_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="applied_on" position="before">
|
|
<field name="pricelist_id" invisible="not context.get('product_pricelist_item_main_view')"/>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
|
|
|
|
<record id="product_pricelist_item_tree_view" model="ir.ui.view">
|
|
<field name="name">usability.product.pricelist.item.tree</field>
|
|
<field name="model">product.pricelist.item</field>
|
|
<field name="inherit_id" ref="product.product_pricelist_item_tree_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="name" position="before">
|
|
<field name="pricelist_id" invisible="not context.get('product_pricelist_item_main_view')"/>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
<!-- product.supplierinfo -->
|
|
<record id="product_supplierinfo_tree_view" model="ir.ui.view">
|
|
<field name="model">product.supplierinfo</field>
|
|
<field name="inherit_id" ref="product.product_supplierinfo_tree_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="product_tmpl_id" position="after">
|
|
<field name="product_name"/>
|
|
<field name="product_code" string="Supplier Code"/>
|
|
</field>
|
|
<field name="price" position="after">
|
|
<field name="currency_id" groups="base.group_multi_currency"/>
|
|
</field>
|
|
<field name="min_qty" position="after">
|
|
<field name="product_uom" groups="product.group_uom"/>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="product_supplierinfo_search_view" model="ir.ui.view">
|
|
<field name="model">product.supplierinfo</field>
|
|
<field name="inherit_id" ref="product.product_supplierinfo_search_view"/>
|
|
<field name="arch" type="xml">
|
|
<field name="product_tmpl_id" position="after">
|
|
<field name="product_code" string="Product Supplier Code"/>
|
|
</field>
|
|
</field>
|
|
</record>
|
|
|
|
</odoo>
|