| | |
| | | }, |
| | | watch: { |
| | | socketValue() { |
| | | // console.log(this.socketValue); |
| | | console.log(this.socketValue); |
| | | let that = this; |
| | | if (that.socketValue.type === "start") { |
| | | // console.log("任务开启vuevueveu") |
| | |
| | | // }, |
| | | // success(res) { |
| | | // let vals = res.data.data.records[0]; |
| | | let types = uni.getSystemInfoSync().platform; |
| | | let that = this, |
| | | d = { |
| | | serid: uni.getStorageSync("ids") || that.$store.state.puserID, |
| | |
| | | appenUrl: that.$store.state.piAPI, |
| | | isOn: true |
| | | }); |
| | | if(types == "android"){ |
| | | uni.navigateTo({ |
| | | url: "/pages/grabOrders/map?data=" + JSON.stringify(val), |
| | | }); |
| | | return |
| | | } |
| | | uni.redirectTo({ |
| | | url: "/pages/grabOrders/map?data=" + JSON.stringify(val), |
| | | }); |
| | |
| | | } else if (that.socketValue.type === "stop") { |
| | | // console.log("任务结束vuevueveu") |
| | | // this.$store.commit("stopTask", this.socketValue.rid); |
| | | // uni.reLaunch({ |
| | | // url: "/pages/home/home" |
| | | // }); |
| | | } |
| | | } |
| | | }, |