优化坯料的制造订单
This commit is contained in:
@@ -794,7 +794,7 @@ class ResMrpWorkOrder(models.Model):
|
||||
'operation_id': False,
|
||||
'name': route.name if hasattr(route, 'routing_type') else route.route_id.name,
|
||||
'processing_panel': False if hasattr(route, 'routing_type') else route.panel,
|
||||
'sequence': 1 if hasattr(route, 'routing_type') else route.sequence,
|
||||
'sequence': route.sequence,
|
||||
'quality_point_ids': False if hasattr(route, 'routing_type') else route.route_id.quality_point_ids,
|
||||
'routing_type': route.routing_type if hasattr(route, 'routing_type') else route.route_id.routing_type,
|
||||
'workcenter_id': False if hasattr(route, 'routing_type') else self.env[
|
||||
@@ -1993,7 +1993,7 @@ class CMMprogram(models.Model):
|
||||
}))
|
||||
return cmm_program
|
||||
|
||||
def update_work_start_end(self,date_planned_start,date_planned_end):
|
||||
def update_work_start_end(self, date_planned_start, date_planned_end):
|
||||
self.leave_id.write({
|
||||
'date_from': date_planned_start,
|
||||
'date_to': date_planned_end,
|
||||
@@ -2031,7 +2031,8 @@ class CMMprogram(models.Model):
|
||||
date_planned_end = date_planned_start + duration_expected
|
||||
last_time = date_planned_end
|
||||
return date_planned_start, date_planned_end, last_time
|
||||
def manual_offline_process(self,last_time,is_first):
|
||||
|
||||
def manual_offline_process(self, last_time, is_first):
|
||||
date_planned_end = None
|
||||
date_planned_start = None
|
||||
duration_expected = datetime.timedelta(minutes=self.duration_expected)
|
||||
@@ -2043,4 +2044,4 @@ class CMMprogram(models.Model):
|
||||
else:
|
||||
date_planned_start = last_time + reserve_time
|
||||
date_planned_end = date_planned_start + duration_expected
|
||||
return date_planned_start, date_planned_end,last_time
|
||||
return date_planned_start, date_planned_end, last_time
|
||||
|
||||
Reference in New Issue
Block a user