diff --git a/src/controllers/server.js b/src/controllers/server.js index 6ef4891..a66814d 100644 --- a/src/controllers/server.js +++ b/src/controllers/server.js @@ -124,7 +124,10 @@ const server = { let msg = pako.gzip(encodeURIComponent(JSON.stringify(d)), { to: "string" }); - _this.websocket.send(msg); + if(_this.websocket!=null){ + _this.websocket.send(msg); + } + }, websocket: null, wxErrorCount: 0, diff --git a/src/index.html b/src/index.html index 205e4b8..9d07bf7 100644 --- a/src/index.html +++ b/src/index.html @@ -37,6 +37,8 @@ allowEdit:true, forceCalculation:false, plugins: ['chart'], + allowUpdate:true, + updateUrl:"www.baidu.com", data: [sheetCell,sheetFormula,sheetConditionFormat,sheetTable,sheetSparkline,sheetComment,sheetPivotTableData,sheetPivotTable,sheetChart] })