Commit 936b0814 by 孙亚楠

Merge branch 'laowubao' of gitlab.gongsibao.com:jiangyong/zhichan into laowubao

parents 7f60eb97 bc382b69
......@@ -747,22 +747,40 @@ class LaoActionApi extends APIBase {
temp = "" + cells[15];
if (temp){
data.phone_no = temp;
}
else{
data.phone_no = null;
//data.user_id = null;
}
temp = "" + cells[14];
if (temp){
var parm = {
phone_no: temp
user_name: temp,
find_type: 0,
real_status: "企业已认证"
}
var user_info = await this.usersSve.findUserInfoByPhone(parm);
var user_info = await this.usersSve.findUserInfo(parm);
if (user_info.status == -1) {
data.user_id = null;
}
else{
data.user_id = user_info.data.id;
if (user_info.count > 0){
data.user_id = user_info.rows[0].id;
}
else{
data.user_id = null;
}
}
}
else{
data.phone_no = null;
data.user_id = null;
}
data.counter_mark = null;
......
......@@ -8,7 +8,8 @@ class XbgApi extends apiBase {
this.restClient = system.getObject("util.restClient");
this.url = "https://bpohhr.gongsibao.com/api/xbgApi/";
this.testCompanyIds = 12;
this.ecompanyId = '1103817785420820481'
this.ecompanyId = '1103817785420820481';
this.recruitSve = system.getObject("service.operator.recruitSve");
}
async test(pobj, query) {
......@@ -112,8 +113,15 @@ class XbgApi extends apiBase {
return system.getResult("参数ecompany_id为空")
}
try {
var recruit_info = await this.recruitSve.findAllList(params);
var rs = await this.restClient.execPost(params, this.url+"dataOverview");
return JSON.parse(rs.stdout);
var resut = JSON.parse(rs.stdout);
var rcount = 0;
if (recruit_info.status == 0){
rcount = recruit_info.data.count;
}
resut.data["recruit_count"] = rcount;
return resut;
} catch (e) {
console.log(e);
return system.getResult("接口异常");
......@@ -158,4 +166,15 @@ class XbgApi extends apiBase {
}
module.exports = XbgApi;
\ No newline at end of file
module.exports = XbgApi;
// var tesk = new XbgApi();
// var parm = {
// ecompany_id:""
// };
// tesk.dataOverview(parm).then(function(result){
// console.log(result);
// //console.log(result.data.rows);
// }).catch(function(e){
// console.log(e);
// });
\ 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