Commit 9e9345f8 by 庄冰

orderdetail

parent 24b49c10
...@@ -65,6 +65,9 @@ class TmOrderAPI extends APIBase { ...@@ -65,6 +65,9 @@ class TmOrderAPI extends APIBase {
case "getOrderList"://获取订单列表(分页) case "getOrderList"://获取订单列表(分页)
opResult = await this.orderinfoSve.findAndCountAll(action_body,req); opResult = await this.orderinfoSve.findAndCountAll(action_body,req);
break; break;
case "getOrderDetailByOrderNo"://获取订单详情
opResult = await this.orderinfoSve.getOrderDetailByOrderNo(action_body,req);
break;
case "decryptStr":// case "decryptStr"://
opResult = await this.toolSve.decryptStr(req.app, action_body.opStr); opResult = await this.toolSve.decryptStr(req.app, action_body.opStr);
break; break;
......
...@@ -270,10 +270,10 @@ class OrderInfoService extends ServiceBase { ...@@ -270,10 +270,10 @@ class OrderInfoService extends ServiceBase {
} }
obj["search"]["uapp_id"]=app.uAppId; obj["search"]["uapp_id"]=app.uAppId;
const result = await this.dao.findAndCountAll(obj); const result = await this.dao.findAndCountAll(obj);
return result; return system.getResultSuccess(result);
} }
async getOrderDetailByOrderNo(obj){ async getOrderDetailByOrderNo(obj,req){
var orderNo = obj.orderNo; var orderNo = obj.orderNo;
if(!orderNo){ if(!orderNo){
return system.getResult(null, "订单编号不能为空"); return system.getResult(null, "订单编号不能为空");
...@@ -286,7 +286,7 @@ class OrderInfoService extends ServiceBase { ...@@ -286,7 +286,7 @@ class OrderInfoService extends ServiceBase {
where:{orderNo:orderNo,uapp_id:app.uAppId}, where:{orderNo:orderNo,uapp_id:app.uAppId},
raw:true raw:true
}); });
return order; return system.getResultSuccess(order);
} }
} }
module.exports = OrderInfoService; module.exports = OrderInfoService;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment