mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-05 05:09:11 +00:00
fix(production_plan): Allow work orders to be cancelled (#15955)
This commit is contained in:
@@ -210,9 +210,10 @@ class ProductionPlan(Document):
|
|||||||
|
|
||||||
def set_status(self):
|
def set_status(self):
|
||||||
self.status = {
|
self.status = {
|
||||||
'0': 'Draft',
|
0: 'Draft',
|
||||||
'1': 'Submitted'
|
1: 'Submitted',
|
||||||
}[cstr(self.docstatus or 0)]
|
2: 'Cancelled'
|
||||||
|
}.get(self.docstatus)
|
||||||
|
|
||||||
if self.total_produced_qty > 0:
|
if self.total_produced_qty > 0:
|
||||||
self.status = "In Process"
|
self.status = "In Process"
|
||||||
|
|||||||
Reference in New Issue
Block a user