提交 37cd4f1a authored 作者: blu's avatar blu

dingbot

上级 bccb84a9
......@@ -130,6 +130,7 @@ class DingBot:
issues += "[{}]连接失败: {}".format(idx, msg[pos+2:])
else:
issues += "[{}] {}".format(idx, msg)
idx+=1
if issues:
body = "摄像头{} 故障: ".format(ipcSn) + issues
......
......@@ -1477,6 +1477,7 @@ public:
ret["data"] = json();
json detail, summary;
string sn = req.get_param_value("sn");
string withSummery = req.get_param_value("summery");
try {
if(!sn.empty() && sn != "all") {
lock_guard<recursive_mutex> lg(mutIpcStatus);
......@@ -1500,6 +1501,7 @@ public:
ret["data"]["detail"] = detail;
if(withSummery == "true"){
// get a copy to build summary
lock_guard<recursive_mutex> lg(mutIpcStatus);
json ipcsData = this->peerData["ipcStatus"];
......@@ -1516,6 +1518,7 @@ public:
ret["data"]["summary"] = summary;
ret["data"]["termNoCfg"] = this->peerData["info"]["nocfg"];
}
}
catch(exception &e) {
ret["code"] = -1;
ret["msg"] = string("evcloudsvc exception: ") + e.what();
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论