This commit is contained in:
aqu415
2022-02-24 21:58:30 +08:00
parent 695870527f
commit a343794b3f
+6 -7
View File
@@ -101,6 +101,7 @@
fetch_log: function () {
Jm.util.ajax.get(`${this.coop_api_url}?coop_mind_id=${this.coop_mind_id}&cooperation_mind_log_id=${this.coop_mind_log_id}`, function (resp) {
console.log(resp)
// _handle_msg_inner
})
},
// 清理定时任务
@@ -131,6 +132,11 @@
// 调用jsmind接口
_handle_jsmind_with_ws_message: function (message) {
const msg_json = JSON.parse(message)
this._handle_msg_inner(msg_json)
},
// 处理消息广告方法
_handle_msg_inner(msg_json) {
const client_id = msg_json.client_id
const log_id = msg_json.log_id
if (log_id > this.coop_mind_log_id) {
@@ -199,13 +205,6 @@
console.error('web_socket is not ready!')
}
},
/**
* 定时向db获取
*/
timerFetch: function () {
// 根据最大的日志Id 获取
},
/**
* 每隔n秒钟同步一次数据到db
*/