Commit 8c3b0aa3 by zhaoxiqing

gsb

parent 69db1e3d
...@@ -587,44 +587,44 @@ class EntcontractService extends ServiceBase { ...@@ -587,44 +587,44 @@ class EntcontractService extends ServiceBase {
//---------------- //----------------
let ecompany = await this.ecompanyDao.findOne({ // let ecompany = await this.ecompanyDao.findOne({
"name": params.merchantName, // "name": params.merchantName,
}) // })
if (!ecompany) { // if (!ecompany) {
// 创建ecompany // // 创建ecompany
ecompany = await this.ecompanyDao.create({ // ecompany = await this.ecompanyDao.create({
"name": params.merchantName, // "name": params.merchantName,
"nameA": '', // "nameA": '',
"isEnabled": true, // "isEnabled": true,
"isQuiet": true, // "isQuiet": true,
"sealurl": "", // "sealurl": "",
"encryptkey": "", // "encryptkey": "",
"posturl": "" // "posturl": ""
}); // });
} // }
//
let busi = await this.ecompanybusiDao.findOne({ // let busi = await this.ecompanybusiDao.findOne({
ecompany_id: ecompany.id, // ecompany_id: ecompany.id,
etemplate_id: 10287, // etemplate_id: 10287,
}); // });
if (!busi) { // if (!busi) {
await this.ecompanybusiDao.create({ // await this.ecompanybusiDao.create({
ecompany_id: ecompany.id, // ecompany_id: ecompany.id,
etemplate_id: 10287, // etemplate_id: 10287,
postwxurl: "", // postwxurl: "",
postsignurl: "", // postsignurl: "",
appId: reso.data.appId, // appId: reso.data.appId,
mchtId: reso.data.mchtId, // mchtId: reso.data.mchtId,
mainId: reso.data.mainId, // mainId: reso.data.mainId,
key: reso.data.secret, // key: reso.data.secret,
}); // });
} else { // } else {
busi.appId = reso.data.appId; // busi.appId = reso.data.appId;
busi.mchtId = reso.data.mchtId; // busi.mchtId = reso.data.mchtId;
busi.mainId = reso.data.mainId; // busi.mainId = reso.data.mainId;
busi.key = reso.data.secret; // busi.key = reso.data.secret;
await busi.save(); // await busi.save();
} // }
//---------------- //----------------
return reso; return reso;
......
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