Files
odoo_source/addons/mrp/views/stock_move_views.xml
T
William Henrotin 47e40e7f6a [FIX] mrp: usability fixes
- Default quantity on MO is 1.0
- Default quantity to consume on move is 1.0
- No open on the company_id from BoM form
- Optional=Hide for product, qty on BoM form
- Backorder button renamed to Validate
- Date deadline and origin to Miscellaneous tab
- Be able to remove stock_move when the MO is draft
- Some renaming in the menu and run scheduler under planning item

[FIX] mrp: fail to create stock.move after MO confirmation

Since the product_id on stock.move is readonly once it is set and the
MO is confirmed, it's not send to the server and the create crash
since product_id is NULL.

closes odoo/odoo#55270

Related: odoo/enterprise#12148
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2020-08-03 09:38:33 +00:00

62 lines
2.6 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record model="ir.actions.act_window" id="action_mrp_production_moves">
<field name="name">Inventory Moves</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">stock.move.line</field>
<field name="view_mode">tree,form</field>
<field name="domain">['|', ('move_id.raw_material_production_id', '=', active_id), ('move_id.production_id', '=', active_id)]</field>
</record>
<record id="view_stock_move_operations_raw" model="ir.ui.view">
<field name="name">stock.move.operations.raw.form</field>
<field name="model">stock.move</field>
<field name="priority">1</field>
<field name="mode">primary</field>
<field name="inherit_id" ref="stock.view_stock_move_operations" />
<field name="arch" type="xml">
<xpath expr="//label[@for='product_uom_qty']" position="attributes">
<attribute name="string">Total To Consume</attribute>
</xpath>
<xpath expr="//label[@for='quantity_done']" position="attributes">
<attribute name="string">Consumed</attribute>
</xpath>
</field>
</record>
<record id="view_stock_move_operations_finished" model="ir.ui.view">
<field name="name">stock.move.operations.finished.form</field>
<field name="model">stock.move</field>
<field name="priority">1</field>
<field name="mode">primary</field>
<field name="inherit_id" ref="stock.view_stock_move_operations" />
<field name="arch" type="xml">
<xpath expr="//label[@for='product_uom_qty']" position="attributes">
<attribute name="string">To Produce</attribute>
</xpath>
<xpath expr="//label[@for='quantity_done']" position="attributes">
<attribute name="string">Produced</attribute>
</xpath>
</field>
</record>
<menuitem id="menu_mrp_traceability"
name="Lots/Serial Numbers"
parent="menu_mrp_bom"
action="stock.action_production_lot_form"
groups="stock.group_production_lot"
sequence="15"/>
<menuitem id="menu_mrp_scrap"
name="Scrap"
parent="menu_mrp_manufacturing"
action="stock.action_stock_scrap"
sequence="25"/>
<menuitem id="menu_procurement_compute_mrp"
action="stock.action_procurement_compute"
parent="mrp_planning_menu_root"
sequence="135"/>
</odoo>