| | |
| | | }; |
| | | }, |
| | | created() { |
| | | this.websocketStart(); |
| | | //this.websocketStart(); |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["website", "keyCollapse"]), |
| | |
| | | } |
| | | if (window.WebSocket) { |
| | | // https |
| | | window.socket = new WebSocket("wss://web.byisf.com/wss/websocket/"); |
| | | //window.socket = new WebSocket("wss://web.byisf.com/wss/websocket/"); |
| | | |
| | | //http |
| | | //window.socket = new WebSocket("ws://localhost:9034/websocket"); |
| | | window.socket = new WebSocket("ws://localhost:9034/websocket"); |
| | | |
| | | window.socket.onmessage = function (event) { |
| | | // alert(event.data) |
| | |
| | | }, |
| | | onSubmit() { |
| | | var that = this; |
| | | if (typeof that.form.securityArr != "string"){ |
| | | var security = ""; |
| | | that.form.securityArr.forEach((item) => { |
| | | security = security + item + ","; |
| | | }); |
| | | that.form.securityArr = security.substring(0, security.length - 1); |
| | | } |
| | | |
| | | axios({ |
| | | url: '/api/blade-jfpts/alarm/alarm/submit', |
| | | method: 'post', |
| | |
| | | ); |
| | | }, |
| | | rowUpdate(row, index, done, loading) { |
| | | if (typeof row.securityArr != "string") { |
| | | var security = ""; |
| | | row.securityArr.forEach((item) => { |
| | | security = security + item + ","; |
| | | }); |
| | | row.securityArr = security.substring(0, security.length - 1); |
| | | } |
| | | |
| | | row.coordinate = ""; |
| | | update(row).then( |
| | | () => { |
| | |
| | | this.onLoad(this.page, params); |
| | | }, |
| | | getQBdata(e) { |
| | | debugger; |
| | | this.search.releaseTimeRange = ["", ""]; |
| | | this.activeClass = e; |
| | | var params = {}; |