mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-29 18:04:46 +00:00
Merge pull request #51136 from mihir-kandoi/gh42070
This commit is contained in:
@@ -919,7 +919,7 @@ class JobCard(Document):
|
|||||||
wo.calculate_operating_cost()
|
wo.calculate_operating_cost()
|
||||||
wo.set_actual_dates()
|
wo.set_actual_dates()
|
||||||
|
|
||||||
if wo.track_semi_finished_goods and time_data:
|
if time_data:
|
||||||
wo.status = "In Process"
|
wo.status = "In Process"
|
||||||
|
|
||||||
wo.save()
|
wo.save()
|
||||||
|
|||||||
@@ -572,9 +572,9 @@ class WorkOrder(Document):
|
|||||||
):
|
):
|
||||||
status = "In Process"
|
status = "In Process"
|
||||||
|
|
||||||
if self.track_semi_finished_goods and status != "Completed":
|
if status != "Completed":
|
||||||
if op_status := self.get_status_based_on_operation():
|
if not all(d.status == "Pending" for d in self.operations):
|
||||||
status = op_status
|
status = "In Process"
|
||||||
|
|
||||||
if status == "Not Started" and self.reserve_stock:
|
if status == "Not Started" and self.reserve_stock:
|
||||||
for row in self.required_items:
|
for row in self.required_items:
|
||||||
@@ -589,11 +589,6 @@ class WorkOrder(Document):
|
|||||||
|
|
||||||
return status
|
return status
|
||||||
|
|
||||||
def get_status_based_on_operation(self):
|
|
||||||
for row in self.operations:
|
|
||||||
if row.status != "Completed":
|
|
||||||
return "In Process"
|
|
||||||
|
|
||||||
def update_work_order_qty(self):
|
def update_work_order_qty(self):
|
||||||
"""Update **Manufactured Qty** and **Material Transferred for Qty** in Work Order
|
"""Update **Manufactured Qty** and **Material Transferred for Qty** in Work Order
|
||||||
based on Stock Entry"""
|
based on Stock Entry"""
|
||||||
|
|||||||
Reference in New Issue
Block a user