Commit d344d995 by 宋毅

tj

parent 5b6a02a2
......@@ -136,7 +136,7 @@ class TmOrderAPI extends APIBase {
}
break;
case "getTmOrderList"://商标交付列表
opResult = await this.ordertmproductSve.getTmOrderList(action_body, req);
opResult = await this.ordertmproductSve.getTmOrderList(action_body, pobj, req);
break;
case "getTmOrderInfo"://商标交付信息
opResult = await this.ordertmproductSve.getTmOrder(action_body);
......
......@@ -538,7 +538,7 @@ class OrderTmProductService extends ServiceBase {
* 商标交付列表
* @param {*} params 格式:{channelServiceNo:XX, app:{ appId:XX}}
*/
async getTmOrderList(params, req) {//商标交付列表
async getTmOrderList(params, pobj, req) {//商标交付列表
var pageSize = Number(params.pageSize || 20);
var pageInde = Number(params.pageInde || 1);
var from = pageInde == 1 ? 0 : Number((pageInde - 1) * pageSize);
......@@ -553,6 +553,11 @@ class OrderTmProductService extends ServiceBase {
var sqlCount = "SELECT count(1) as dataCount FROM `b_order_tm_product` AS tm LEFT JOIN `b_order` AS o ON tm.`sourceOrderNo`=o.`orderNo` LEFT JOIN" +
" `b_customerinfo` AS c ON tm.`deliveryOrderNo`=c.`deliveryOrderNo` where tm.deleted_at is null ";
var paramWhere = {};
if (["1688", "jd"].indexOf(pobj.actionProcess) >= 0) {
sql += " and o.orderPayStatus=:orderPayStatus";
sqlCount += " and o.orderPayStatus=:orderPayStatus";;
paramWhere.orderPayStatus = "yfk";
}
if (req.user) {
sql += " and tm.createuser_id=:createuser_id";
sqlCount += " and tm.createuser_id=:createuser_id";
......@@ -902,7 +907,7 @@ class OrderTmProductService extends ServiceBase {
// where: { id: beforeOtp.id },
// raw: true
// });
orderTm=orderProductObj;
orderTm = orderProductObj;
} else {//创建服务单
orderTm = await self.dao.create(orderProductObj, t);//创建商标订单
}
......@@ -947,7 +952,7 @@ class OrderTmProductService extends ServiceBase {
nclSmallPrice = Number(nclSmallPrice.toFixed(2));
var self = this;
var returnTm = [];
await this.trademarkDao.bulkDeleteByWhere({ where: { deliveryOrderNo: orderTm.deliveryOrderNo} }, t);
await this.trademarkDao.bulkDeleteByWhere({ where: { deliveryOrderNo: orderTm.deliveryOrderNo } }, t);
for (var i = 0; i < nclones.length; i++) {
var tbcode = await self.getBusUid("tb");
var nclone = nclones[i];
......
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