Commit 959f0fd1 by 孙亚楠

d

parent daf2234b
......@@ -24,7 +24,8 @@ class BpoSDPJApi {
this.EXCEPT_KEYS = ['sign'];
this.ccashinfoSve = system.getObject("service.ccashinfoSve");
this.ecompanybusiSve = system.getObject("service.ecompanybusiSve");
// this.ecompanybusiSve = system.getObject("service.ecompanybusiSve");
this.ecompanybusiDao = system.getObject("db.ecompanybusiDao");
this.qrClient = system.getObject("util.qrClient");
this.idcardClient = system.getObject("util.idcardClient");
this.esettleSve = system.getObject("service.esettleSve");
......@@ -89,13 +90,15 @@ class BpoSDPJApi {
return this.getCodeResult(1002001,null);
}
//2.检验所有参数是否完整 如果出现非法参数直接返回
if(!obj.ecid || !obj.appId ||!obj.idNo || !obj.idName || !obj.amt){
if(!obj.ecid || !obj.appId || !obj.amt){
return this.getCodeResult(1002001,null);
}
//3.获取签约类型
let _ecompanybusi = await this.ecompanybusiSve.findOneByAppidMchtId({
app_id: this.trim(obj.appId),
let _ecompanybusi = await this.ecompanybusiDao.model.findOne({
where:{
appId: this.trim(obj.appId),
mchtId: this.trim(obj.mchtId)
}
});
console.log("查看签约类型 _ecompanybusi=" + JSON.stringify(_ecompanybusi));
if(!_ecompanybusi || !_ecompanybusi.hasOwnProperty("app_type")){
......
......@@ -11,6 +11,7 @@ module.exports = (db, DataTypes) => {
key: DataTypes.STRING(64),
postwxurl: DataTypes.STRING(300),
postsignurl: DataTypes.STRING(300),
app_type: DataTypes.BIGINT,
}, {
paranoid: true, //假的删除
underscored: true,
......
const system=require("../../system");
const ServiceBase=require("../sve.base");
class CcashinfoSve extends ServiceBase {
class CcashinfoService extends ServiceBase {
constructor() {
super(ServiceBase.getDaoName(CcashinfoSve));
super(ServiceBase.getDaoName(CcashinfoService));
}
......@@ -91,7 +91,7 @@ class CcashinfoSve extends ServiceBase {
properties.contract_id=this.trim(params.contract_id)
}
await this.dao.update(properties)
return {code:0,null}
return {code:0,data:null}
}catch (e) {
console.log(e);
return null;
......@@ -103,4 +103,4 @@ class CcashinfoSve extends ServiceBase {
}
module.exports=CcashinfoSve;
module.exports=CcashinfoService;
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