diff options
| author | Nicolas Martinelli <nim@odoo.com> | 2019-01-29 05:49:13 +0000 |
|---|---|---|
| committer | Nicolas Martinelli <nim@odoo.com> | 2019-01-29 07:13:08 +0000 |
| commit | ae88e50928b3fe58d8e7b3e75e2985d22282535d (patch) | |
| tree | 0ca3ffd18588c3c7dda706b9abf0536c08d50781 | |
| parent | c2d83973ea4556533efae593a10cba2fa6b32a56 (diff) | |
[FIX] stock: unreserve
- Create a SO with 2 stockable products: 1 is available, the other is
not.
- Validate, go to the picking
- Set the 'Shipping Policy' to 'When all products are ready'
The 'Unreserve' button disappears, while some products were reserved.
When changing the shipping policy, the state of the picking is
recomputed and set as `confirmed` ('Waiting').
We make the button visible in this state also, when 'Shipping Policy'
is set to 'When all products are ready'.
opw-1932658
closes odoo/odoo#30635
| -rw-r--r-- | addons/stock/views/stock_picking_views.xml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/stock/views/stock_picking_views.xml b/addons/stock/views/stock_picking_views.xml index a39c5794652..7bbdf7e4bbf 100644 --- a/addons/stock/views/stock_picking_views.xml +++ b/addons/stock/views/stock_picking_views.xml @@ -214,7 +214,7 @@ <button name="%(act_stock_return_picking)d" string="Return" attrs="{'invisible': ['|', ('state', '!=', 'done'), ('is_locked', '=', False)]}" type="action" groups="base.group_user"/> <button name="action_cancel" attrs="{'invisible': ['|', ('state', 'not in', ('assigned', 'confirmed', 'partially_available', 'draft', 'waiting')), ('is_locked', '=', False)]}" string="Cancel" groups="base.group_user" type="object"/> <field name="picking_type_code" invisible="1"/> - <button name="do_unreserve" string="Unreserve" groups="base.group_user" type="object" attrs="{'invisible': ['|', '|', ('picking_type_code', '=', 'incoming'), ('state', 'not in', ('assigned', 'partially_available')), ('is_locked', '=', False)]}"/> + <button name="do_unreserve" string="Unreserve" groups="base.group_user" type="object" attrs="{'invisible': ['|', '|', '|', ('picking_type_code', '=', 'incoming'), ('is_locked', '=', False), '&', ('state', 'not in', ('assigned', 'partially_available')), ('move_type', '!=', 'one'), '&', ('state', 'not in', ('assigned', 'partially_available', 'confirmed')), ('move_type', '=', 'one')]}"/> <field name="show_operations" invisible="1" readonly="1"/> <field name="move_line_exist" invisible="1"/> <field name="has_packages" invisible="1"/> |
