Merge branch 'develop' of https://e.coding.net/jikimo-hn/jikimo_sfs/jikimo_sf into feature/sf物流方面缺陷与优化
This commit is contained in:
@@ -162,7 +162,8 @@ class Manufacturing_Connect(http.Controller):
|
|||||||
routing_type = ret['CraftId']
|
routing_type = ret['CraftId']
|
||||||
equipment_id = ret["DeviceId"]
|
equipment_id = ret["DeviceId"]
|
||||||
workorder = request.env['mrp.workorder'].sudo().search(
|
workorder = request.env['mrp.workorder'].sudo().search(
|
||||||
[('production_id', '=', production_id), ('routing_type', '=', routing_type)], limit=1)
|
[('production_id', '=', production_id), ('routing_type', '=', routing_type),
|
||||||
|
('rfid_code', '!=', False)], limit=1)
|
||||||
if not workorder:
|
if not workorder:
|
||||||
res = {'Succeed': False, 'ErrorCode': 202, 'Error': '该工单不存在'}
|
res = {'Succeed': False, 'ErrorCode': 202, 'Error': '该工单不存在'}
|
||||||
return json.JSONEncoder().encode(res)
|
return json.JSONEncoder().encode(res)
|
||||||
@@ -209,7 +210,8 @@ class Manufacturing_Connect(http.Controller):
|
|||||||
production_id = ret['BillId']
|
production_id = ret['BillId']
|
||||||
routing_type = ret['CraftId']
|
routing_type = ret['CraftId']
|
||||||
workorder = request.env['mrp.workorder'].sudo().search(
|
workorder = request.env['mrp.workorder'].sudo().search(
|
||||||
[('production_id', '=', production_id), ('routing_type', '=', routing_type)], limit=1)
|
[('production_id', '=', production_id), ('routing_type', '=', routing_type),
|
||||||
|
('rfid_code', '!=', False)], limit=1)
|
||||||
if not workorder:
|
if not workorder:
|
||||||
res = {'Succeed': False, 'ErrorCode': 202, 'Error': '该工单不存在'}
|
res = {'Succeed': False, 'ErrorCode': 202, 'Error': '该工单不存在'}
|
||||||
return json.JSONEncoder().encode(res)
|
return json.JSONEncoder().encode(res)
|
||||||
|
|||||||
Reference in New Issue
Block a user