修改单元测试

This commit is contained in:
胡尧
2024-10-21 11:37:01 +08:00
parent 54abb7a9f7
commit 2af21bc4ee
2 changed files with 54 additions and 3 deletions

View File

@@ -21,7 +21,7 @@ class WorkorderExceptionConroller(http.Controller):
try:
res = {'Succeed': True, 'ErrorCode': 0, 'Error': ''}
datas = request.httprequest.data
ret = json.loads(datas)['Datas']
ret = json.loads(datas)
if not ret.get('RfidCode') or not ret.get('ErrorType'):
res = {'Succeed': False, 'ErrorCode': 400, 'Error': '参数错误'}
return json.JSONEncoder().encode(res)