Skip to content
Snippets Groups Projects
Commit 8a12883c authored by Hubert Van de Walle (huvw)'s avatar Hubert Van de Walle (huvw)
Browse files

[FIX] mrp: use the correct state identifier


The Scheduled Date field is in readonly depending on the MO state, but
the `close` state does not exist, use the `done` state instead to match
the decoration-* attributes

closes odoo/odoo#119372

X-original-commit: a12ba467
Signed-off-by: default avatarAdrien Widart <awt@odoo.com>
Signed-off-by: default avatarHubert Van De Walle <huvw@odoo.com>
parent 7ff8c563
No related branches found
No related tags found
No related merge requests found
......@@ -232,7 +232,7 @@
<label for="date_planned_start"/>
<div class="o_row">
<field name="date_planned_start"
attrs="{'readonly': [('state', 'in', ['close', 'cancel'])]}"
attrs="{'readonly': [('state', 'in', ['done', 'cancel'])]}"
decoration-warning="state not in ('done', 'cancel') and date_planned_start &lt; now"
decoration-danger="state not in ('done', 'cancel') and date_planned_start &lt; current_date"
decoration-bf="state not in ('done', 'cancel') and (date_planned_start &lt; current_date or date_planned_start &lt; now)"/>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment