[FIX] stock_secondary_unit: Allow use secondary units in form view for mobile views

TT30538
This commit is contained in:
sergio-teruel
2021-06-22 15:29:34 +02:00
committed by Jesús Alan Ramos Rodríguez
parent ccbd79b719
commit 7c81ca3828

View File

@@ -23,6 +23,21 @@
attrs="{'column_invisible': [('parent.immediate_transfer', '=', True)], 'readonly': ['|', ('is_initial_demand_editable', '=', False), '&', '&', ('show_operations', '=', True), ('is_locked', '=', True), ('is_initial_demand_editable', '=', False)]}"
/>
</xpath>
<xpath
expr="//field[@name='move_ids_without_package']/form//field[@name='product_uom_qty']"
position="before"
>
<field
name="secondary_uom_qty"
attrs="{'invisible': [('parent.immediate_transfer', '=', True)], 'readonly': [('is_initial_demand_editable', '=', False)]}"
/>
<field
name="secondary_uom_id"
domain="[('product_tmpl_id.product_variant_ids', 'in', [product_id])]"
options="{'no_create': True}"
attrs="{'invisible': [('parent.immediate_transfer', '=', True)], 'readonly': [('is_initial_demand_editable', '=', False)]}"
/>
</xpath>
</field>
</record>
</odoo>