Skip to content

Commit

Permalink
[FIX] mrp: don't copy locked state
Browse files Browse the repository at this point in the history
When copying a done MO that is unlocked, the new MO is also unlocked and
the buttons to produce/check availability aren't displayed and it is
confusing to the user.

Fixes odoo#20119
  • Loading branch information
sle-odoo committed Dec 28, 2017
1 parent 7862ce4 commit 0126823
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion addons/mrp/models/mrp_production.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ def _get_default_location_dest_id(self):
scrap_count = fields.Integer(compute='_compute_scrap_move_count', string='Scrap Move')
priority = fields.Selection([('0', 'Not urgent'), ('1', 'Normal'), ('2', 'Urgent'), ('3', 'Very Urgent')], 'Priority',
readonly=True, states={'confirmed': [('readonly', False)]}, default='1')
is_locked = fields.Boolean('Is Locked', default=True)
is_locked = fields.Boolean('Is Locked', default=True, copy=False)
show_final_lots = fields.Boolean('Show Final Lots', compute='_compute_show_lots')
production_location_id = fields.Many2one('stock.location', "Production Location", related='product_id.property_stock_production')

Expand Down

0 comments on commit 0126823

Please sign in to comment.