Commit 4c409c10 by zhaoxiqing

gsb

parent cffe9c82
...@@ -63,6 +63,26 @@ class BusistatDao extends Dao { ...@@ -63,6 +63,26 @@ class BusistatDao extends Dao {
return await this.customQuery(sql.join(" "), params); return await this.customQuery(sql.join(" "), params);
} }
async gettomonthList(param){
let sql = [];
sql.push("SELECT");
sql.push("*");
sql.push("FROM `c_busi_stat`");
sql.push("WHERE 1 = 1");
if(param.busiId){
sql.push("AND busi_id IN (:busiId)");
}
if(param.begin) {
sql.push("AND stat_day >= :begin");
}
if(param.end) {
sql.push("AND stat_day <= :end");
}
return await this.customQuery(sql.join(" "), param);
}
async setCondition(sql, params) { async setCondition(sql, params) {
if (!sql || !params) { if (!sql || !params) {
return; return;
......
...@@ -50,6 +50,12 @@ class BusistatService extends ServiceBase { ...@@ -50,6 +50,12 @@ class BusistatService extends ServiceBase {
item.added_value_tax = system.f2y(item.added_value_tax); item.added_value_tax = system.f2y(item.added_value_tax);
} }
} }
async gettomonthList(busiId, begin, end) {
return await this.dao.gettomonthList({busiId: busiId, begin: begin, end: end});
}
} }
module.exports = BusistatService; module.exports = BusistatService;
...@@ -39,7 +39,10 @@ class ChannelService extends microService { ...@@ -39,7 +39,10 @@ class ChannelService extends microService {
} }
async bindPlatform(params){ async bindPlatform(params){
return await this.callms("channel" , "bindPlatform", params);
}
async getchannelIds(params){
return await this.callms("channel" , "channelIds", params);
} }
async pushbindingchannel(params){ async pushbindingchannel(params){
...@@ -50,6 +53,9 @@ class ChannelService extends microService { ...@@ -50,6 +53,9 @@ class ChannelService extends microService {
async merchantInfo(params) { async merchantInfo(params) {
return await this.callms("channel", "merchantInfo", params); return await this.callms("channel", "merchantInfo", params);
} }
async getchannelmerchantIds(params) {
return await this.callms("channel", "getchannelmerchantIds", params);
}
async merchantSave(params) { async merchantSave(params) {
return await this.callms("channel", "merchantSave", params); return await this.callms("channel", "merchantSave", params);
} }
...@@ -63,5 +69,7 @@ class ChannelService extends microService { ...@@ -63,5 +69,7 @@ class ChannelService extends microService {
async getPushMerchantIds(params){ async getPushMerchantIds(params){
return await this.callms("channel" , "getPushMerchantIds", params); return await this.callms("channel" , "getPushMerchantIds", params);
} }
} }
module.exports = ChannelService; module.exports = ChannelService;
...@@ -9,7 +9,7 @@ var settings = { ...@@ -9,7 +9,7 @@ var settings = {
// dbname : "bpo", // dbname : "bpo",
// user : "write", // user : "write",
// password : "write", // password : "write",
dbname: "bpo2", dbname: "bpo",
user: "write", user: "write",
password: "write", password: "write",
config: { config: {
......
...@@ -36,6 +36,7 @@ var settings = { ...@@ -36,6 +36,7 @@ var settings = {
v: "crkyej0xlmqa6bmvqijun6ltxparllyn", v: "crkyej0xlmqa6bmvqijun6ltxparllyn",
productId: "5e6b02cc3290c3000a3a63dc",// 云服产品id productId: "5e6b02cc3290c3000a3a63dc",// 云服产品id
pushOrderApi: "http://yunfuapi-dev.gongsibao.com/crm/order/submit",// 云服产品id pushOrderApi: "http://yunfuapi-dev.gongsibao.com/crm/order/submit",// 云服产品id
pushOrderSum : "http://yunfuapi-dev.gongsibao.com/cloudapi/bpo/pushBill",
}; };
} else { } else {
return { return {
...@@ -43,6 +44,7 @@ var settings = { ...@@ -43,6 +44,7 @@ var settings = {
v: "e5e2ytnn6nrkr9qnqk4w5e6z0xlhkznu", v: "e5e2ytnn6nrkr9qnqk4w5e6z0xlhkznu",
productId: "5e6c89d54c52bf000a750bc5",// 云服产品id (生产环境) productId: "5e6c89d54c52bf000a750bc5",// 云服产品id (生产环境)
pushOrderApi: "http://yunfuapi.gongsibao.com/crm/order/submit",// 云服产品id (生产环境) pushOrderApi: "http://yunfuapi.gongsibao.com/crm/order/submit",// 云服产品id (生产环境)
pushOrderSum :"http://yunfuapi.gongsibao.com/cloudapi/bpo/pushBill",
}; };
} }
}, },
...@@ -187,4 +189,4 @@ var settings = { ...@@ -187,4 +189,4 @@ var settings = {
} }
}; };
settings.ENVINPUT = ENVINPUT; settings.ENVINPUT = ENVINPUT;
module.exports = settings; module.exports = settings;
\ No newline at end of file
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