Initialize v18 branch
Rename *_usability modules to *_usability_akretion
This commit is contained in:
48
mrp_usability_akretion/views/mrp_production.xml
Normal file
48
mrp_usability_akretion/views/mrp_production.xml
Normal file
@@ -0,0 +1,48 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
Copyright 2016-2022 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>
|
||||
|
||||
|
||||
<record id="mrp_production_form_view" model="ir.ui.view">
|
||||
<field name="name">usability.mrp.production.form</field>
|
||||
<field name="model">mrp.production</field>
|
||||
<field name="inherit_id" ref="mrp.mrp_production_form_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="user_id" position="before">
|
||||
<!-- I can't use position="move" because it would match another field in an embedded tree view -->
|
||||
<field name="location_src_id" groups="stock.group_stock_multi_locations" options="{'no_create': True}" attrs="{'readonly': [('state', '!=', 'draft')]}"/>
|
||||
<field name="location_dest_id" groups="stock.group_stock_multi_locations" options="{'no_create': True}" attrs="{'readonly': [('state', 'in', ('done', 'cancel'))]}"/>
|
||||
</field>
|
||||
<!-- It is important to remove the original field location_dest_id
|
||||
and not just set it as invisible because it cancels the changes -->
|
||||
<xpath expr="//page[@name='miscellaneous']/group/group/field[@name='location_dest_id']" position="replace"/>
|
||||
<xpath expr="//page[@name='miscellaneous']/group/group/field[@name='location_src_id']" position="attributes">
|
||||
<attribute name="invisible">1</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//page[@name='miscellaneous']/group/group/field[@name='date_deadline']" position="after">
|
||||
<field name="date_start"/>
|
||||
<field name="date_finished"/>
|
||||
</xpath>
|
||||
<button name="action_cancel" type="object" attrs="{'invisible': ['|', '|', ('id', '=', False), ('state', 'in', ('done', 'cancel')), ('confirm_cancel', '=', True)]}" position="attributes">
|
||||
<attribute name="confirm">Are you sure you want to cancel this manufacturing order?</attribute>
|
||||
</button>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="mrp_production_tree_view" model="ir.ui.view">
|
||||
<field name="model">mrp.production</field>
|
||||
<field name="inherit_id" ref="mrp.mrp_production_tree_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="reservation_state" position="after">
|
||||
<field name="location_src_id" optional="hide" groups="stock.group_stock_multi_locations"/>
|
||||
<field name="location_dest_id" optional="hide" groups="stock.group_stock_multi_locations"/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
16
mrp_usability_akretion/views/product_template.xml
Normal file
16
mrp_usability_akretion/views/product_template.xml
Normal file
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0"?>
|
||||
<odoo>
|
||||
|
||||
<record id="product_template_form_view_bom_button" model="ir.ui.view">
|
||||
<field name="name">product.template.procurement</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="mrp.product_template_form_view_bom_button" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='bom_count']/.." position="attributes">
|
||||
<attribute name="type">object</attribute>
|
||||
<attribute name="name">action_view_bom</attribute>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
21
mrp_usability_akretion/views/stock_move.xml
Normal file
21
mrp_usability_akretion/views/stock_move.xml
Normal file
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
Copyright 2016-2022 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>
|
||||
|
||||
<record id="view_move_form" model="ir.ui.view">
|
||||
<field name="model">stock.move</field>
|
||||
<field name="inherit_id" ref="stock.view_move_form" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="origin" position="after">
|
||||
<field name="production_id"/>
|
||||
<field name="raw_material_production_id"/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user