Commit 7d7b1524 by 王悦

fix 批量推fq单条错误

parent 91d985d6
......@@ -21,6 +21,7 @@ class GatewaypushlogService extends ServiceBase {
}
var self = this;
for (var i = 0; i < count; i++) {
try {
var icloginfo = icloginfos[i];
var requestdata = null;
if (icloginfo && icloginfo.requestjson) {
......@@ -29,11 +30,7 @@ class GatewaypushlogService extends ServiceBase {
var url = settings.gatewayUrl() + "action/intentionapi/springBoard";
var rtn = await self.execClient.execPost(requestdata, url);
var data = rtn
try {
data = JSON.parse(rtn.stdout);
}catch (e) {
console.error(e)
}
if (data.success) {
icloginfo.pushStatus = "yts";
} else {
......@@ -45,6 +42,9 @@ class GatewaypushlogService extends ServiceBase {
icloginfo.pushtimes += 1;
}
await this.update(icloginfo);
}catch (e) {
console.error(e)
}
}
}
return system.getResultSuccess();
......
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