Commit ade317d5 by 孙亚楠

Merge branch 'xggsve-order' of gitlab.gongsibao.com:jiangyong/zhichan into xggsve-order

parents c1fc1c00 76001e21
......@@ -201,11 +201,14 @@ class OorderDao extends Dao {
sql.push("AND t1.created_at <= :createdEnd");
}
if (params.delier_user_id) {
sql.push("AND t2.deliver_user_id = :deliver_user_id");
sql.push("AND t2.operator_id = :delier_user_id");
}
if (params.deliver_user_id) {
sql.push("AND t2.operator_id = :deliver_user_id");
}
if (params.deliver_user_path) {
params.deliver_user_path_like = params.deliver_user_path + "%";
sql.push("AND t2.deliver_user_path like :deliver_user_path_like");
sql.push("AND t2.operator_path LIKE :deliver_user_path_like");
}
if (params.saas_id) {
sql.push("AND t1.saas_id = :saas_id");
......
......@@ -920,7 +920,7 @@ class OorderService extends ServiceBase {
if(params.isMain){ //如果是主管 则可以看到自己和下属的所有的订单
where.deliver_user_path = params.deliver_user_path
}else{ //否则可以看到自己的订单
where.delier_user_id = params.delier_user_id
where.deliver_user_id = params.deliver_user_id
}
}
return await this.aliOrderPageAll(where);
......
......@@ -523,7 +523,7 @@ class SaasOrderService extends ServiceBase {
_bminfo.business_scope = this.trim(params.business_scope);
}
let self = this;
this.db.transaction(async t => {
await this.db.transaction(async t => {
await self.dao.update(_order, t);
if (_bminfo) {
await self.saasorderbminfoDao.update(_bminfo, t);
......
......@@ -51,15 +51,15 @@ class SaasorderbusinessmenService extends ServiceBase {
for (let item of res) {
this.handleDate(item, ["created_at", "reg_date", "service_begin_time", "service_end_time", "sign_time", "tax_reg_day"], "YYYY-MM-DD HH:mm:ss");
item.is_bank_name = item.is_bank ? "已开户" : "未开户";
item.common_tax_ladder = JSON.parse(item.common_tax_ladder);
item.common_other_ladder = JSON.parse(item.common_other_ladder);
item.special_tax_ladder = JSON.parse(item.special_tax_ladder);
item.special_other_ladder = JSON.parse(item.special_other_ladder);
item.common_tax_ladder = JSON.parse(item.common_tax_ladder || "[]");
item.common_other_ladder = JSON.parse(item.common_other_ladder || "[]");
item.special_tax_ladder = JSON.parse(item.special_tax_ladder || "[]");
item.special_other_ladder = JSON.parse(item.special_other_ladder || "[]");
}
return system.getResult({count: countRes.count, rows: res});
} catch (e) {
console.log(e);
return system.getResult(nul, `系统错误`);
return system.getResult(null, `系统错误`);
}
}
......
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