diff --git a/sf_manufacturing/controllers/controllers.py b/sf_manufacturing/controllers/controllers.py index ac7f77b3..0a1f4cb6 100644 --- a/sf_manufacturing/controllers/controllers.py +++ b/sf_manufacturing/controllers/controllers.py @@ -466,7 +466,6 @@ class Manufacturing_Connect(http.Controller): order='id asc') if workpiece_delivery: for wd in workpiece_delivery: - logging.info('wd.production_id:%s' % wd.production_id.name) if wd.workorder_id.state == 'done' and wd.production_id.production_line_state == '待上产线': logging.info( 'wd.production_line_state:%s' % wd.production_id.production_line_state) @@ -519,7 +518,6 @@ class Manufacturing_Connect(http.Controller): order='id asc') if workpiece_delivery: for wd in workpiece_delivery: - logging.info('wd.production_id:%s' % wd.production_id.name) if wd.workorder_id.state == 'done' and wd.production_id.production_line_state == '已上产线': logging.info( 'wd.production_line_state:%s' % wd.production_id.production_line_state) diff --git a/sf_manufacturing/models/mrp_workorder.py b/sf_manufacturing/models/mrp_workorder.py index 09defd8e..a0973d0a 100644 --- a/sf_manufacturing/models/mrp_workorder.py +++ b/sf_manufacturing/models/mrp_workorder.py @@ -1332,6 +1332,8 @@ class WorkPieceDelivery(models.Model): def create(self, vals): if vals.get('name', '/') == '/' or vals.get('name', '/') is False: vals['name'] = self.env['ir.sequence'].next_by_code('sf.workpiece.delivery') or '/' + else: + vals['type'] = '运送空料架' obj = super(WorkPieceDelivery, self).create(vals) return obj diff --git a/sf_manufacturing/views/agv_setting_views.xml b/sf_manufacturing/views/agv_setting_views.xml index 42662e2c..9a4bf25e 100644 --- a/sf_manufacturing/views/agv_setting_views.xml +++ b/sf_manufacturing/views/agv_setting_views.xml @@ -36,7 +36,7 @@ - + diff --git a/sf_manufacturing/views/mrp_workorder_view.xml b/sf_manufacturing/views/mrp_workorder_view.xml index 30801086..5976915b 100644 --- a/sf_manufacturing/views/mrp_workorder_view.xml +++ b/sf_manufacturing/views/mrp_workorder_view.xml @@ -618,7 +618,6 @@ - @@ -668,14 +667,18 @@ 空料架配送 sf.workpiece.delivery - +
- - - - + + + + +