5 files modified
14 files added
| | |
| | | <template> |
| | | <view class="content"> |
| | | <!-- <u-top-tips ref="uTips"></u-top-tips> --> |
| | | <u-top-tips ref="uTips"></u-top-tips> |
| | | <!-- <u-button type="info" @click="acc">测试</u-button> --> |
| | | <!-- <web-view :src="urls" @message="message"></web-view> --> |
| | | <!-- <map :scale='18' id="myMap" style="width: 100%" :style="{height: mapHeight + 'px'}" :markers="markersCom" |
| | |
| | | </span> |
| | | <span class="once-right"> |
| | | <span>{{ourData.fname}}</span> |
| | | </span> |
| | | </view> |
| | | <view class="once"> |
| | | <span class="once-left"> |
| | | 联系方式 |
| | | </span> |
| | | <span class="once-right"> |
| | | <span>{{ourData.phone}}</span> |
| | | </span> |
| | | </view> |
| | | <view class="once"> |
| | |
| | | }); |
| | | setTimeout(function() { |
| | | uni.redirectTo({ |
| | | url: "/pages/grabOrders/grabOrders?in=true" |
| | | url: "/pages/grabOrders/grabOrdersZAFFPX/grabOrders?in=true" |
| | | }) |
| | | }, 2200) |
| | | } |
| | |
| | | serid: serid, |
| | | type: type, |
| | | // data: JSON.stringify(item), |
| | | goto: "grabOrdersZAFFPX", |
| | | that: that, |
| | | fn: () => { |
| | | // that.getGrabOrders(that.current); //重获取数据 |
| | |
| | | <template> |
| | | <view class="content"> |
| | | <!-- <u-top-tips ref="uTips"></u-top-tips> --> |
| | | <u-top-tips ref="uTips"></u-top-tips> |
| | | <!-- <u-button type="info" @click="acc">测试</u-button> --> |
| | | <!-- <web-view :src="urls" @message="message"></web-view> --> |
| | | <map :scale='18' id="myMap" style="width: 100%" :style="{height: mapHeight + 'px'}" :markers="markersCom" |
| | | :longitude="longitude" :latitude="latitude" :circles="circlesCom" :polyline="mypolylines" |
| | | show-location="true"> |
| | | <map :scale='18' id="myMap" style="width: 100%" :style="{height: mapHeight + 'px'}" :markers="markers" |
| | | :longitude="longitude" :latitude="latitude" :circles="circles" :polyline="mypolylines" show-location="true"> |
| | | <cover-view class="dingwBut" @click="mapControlsBack"> |
| | | <cover-image src="./map/img/dingwei.png" @click="mapControlsBack"> |
| | | </cover-image> |
| | |
| | | </span> |
| | | <span class="once-right"> |
| | | <span>{{ourData.fname}}</span> |
| | | </span> |
| | | </view> |
| | | <view class="once"> |
| | | <span class="once-left"> |
| | | 联系方式 |
| | | </span> |
| | | <span class="once-right"> |
| | | <span>{{ourData.phone}}</span> |
| | | </span> |
| | | </view> |
| | | <view class="once"> |
| | |
| | | mapHeight: 0, |
| | | latitude: 28.687205773173343, |
| | | longitude: 115.8995839881188, |
| | | circles: [], //圆 |
| | | markers: [], //标记点 |
| | | circles: [{ |
| | | latitude: '', |
| | | longitude: '', |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 50, //半径 |
| | | strokeWidth: 2, //描边的宽度 |
| | | }, { |
| | | latitude: '', |
| | | longitude: '', |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 10, //半径 |
| | | strokeWidth: 2, //描边的宽度 |
| | | }], //圆 |
| | | markers: [{ |
| | | width: 40, |
| | | height: 40, |
| | | id: 1, |
| | | latitude: '', |
| | | longitude: '', |
| | | iconPath: 'http://223.82.109.183:2081/zhba/upload/20220225/f0aecffbaf0a2ce80f7938569da20de7.png', |
| | | }, { |
| | | width: 40, |
| | | height: 40, |
| | | id: 2, |
| | | latitude: '', |
| | | longitude: '', |
| | | iconPath: 'http://223.82.109.183:2081/zhba/upload/20220225/7b486f647a15e708aca662dbd496dcd3.png', |
| | | }], //标记点 |
| | | jihecircles: [], //集合点 |
| | | jihemarkers: [], //集合点 |
| | | mypolylines: [{ //指定一系列坐标点,从数组第一项连线至最后一项 |
| | |
| | | iconPath: "/static/tabbar/addSelectedIcon.png", |
| | | clickable: true, |
| | | }], //地图控件 |
| | | inThere: true, |
| | | } |
| | | }, |
| | | methods: { |
| | |
| | | serid: serid, |
| | | type: type, |
| | | // data: JSON.stringify(item), |
| | | goto: "grabOrdersZAXC", |
| | | that: that, |
| | | fn: () => { |
| | | // that.getGrabOrders(that.current); //重获取数据 |
| | |
| | | that.longitude = res.longitude |
| | | // console.log(that.latitude) |
| | | // console.log(that.longitude) |
| | | that.map.moveToLocation({ |
| | | latitude: res.latitude, |
| | | longitude: res.longitude |
| | | }); |
| | | if (that.inThere) { |
| | | that.inThere = false; |
| | | that.map.moveToLocation({ |
| | | latitude: res.latitude, |
| | | longitude: res.longitude |
| | | }); |
| | | } |
| | | // that.mover(res.longitude, res.latitude); //移动 |
| | | // that.$store.commit("setMsg",d) |
| | | //标记点 |
| | | that.markers = [{ |
| | | id: 1, |
| | | latitude: res.latitude, |
| | | longitude: res.longitude, |
| | | iconPath: './map/img/dinw/dinw1.png', |
| | | }] |
| | | that.circles = [{ //在地图上显示圆 |
| | | latitude: res.latitude, |
| | | longitude: res.longitude, |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 10, //半径 |
| | | strokeWidth: 2 //描边的宽度 |
| | | }] |
| | | that.markers[1].latitude = res.latitude; |
| | | that.markers[1].longitude = res.longitude; |
| | | that.circles[1].latitude = res.latitude; |
| | | that.circles[1].longitude = res.longitude; |
| | | // that.markers = [{ |
| | | // id: 1, |
| | | // latitude: res.latitude, |
| | | // longitude: res.longitude, |
| | | // iconPath: './map/img/dinw/dinw1.png', |
| | | // }] |
| | | // that.circles = [{ //在地图上显示圆 |
| | | // latitude: res.latitude, |
| | | // longitude: res.longitude, |
| | | // fillColor: "#D9E6EF", //填充颜色 |
| | | // color: "#A7B6CB", //描边的颜色 |
| | | // radius: 10, //半径 |
| | | // strokeWidth: 2 //描边的宽度 |
| | | // }] |
| | | if (val != "notSet") { |
| | | let d = { |
| | | id: that.ourData.id, |
| | |
| | | return this.$store.state.isOnTaskValue; |
| | | } |
| | | }, |
| | | circlesCom() { |
| | | return [...this.circles.slice(0), ...this.jihecircles.slice(0)]; |
| | | }, |
| | | markersCom() { |
| | | return [...this.markers.slice(0), ...this.jihemarkers.slice(0)]; |
| | | }, |
| | | // circlesCom() { |
| | | // // let d = [...this.circles, ...this.jihecircles]; |
| | | // let d = [{ |
| | | // id: 1, |
| | | // latitude: +data.latlong[0], |
| | | // longitude: +data.latlong[1], |
| | | // iconPath: './map/img/dinw/dinw6.png', |
| | | // }, { |
| | | // id: 2, |
| | | // latitude: +data.latlong[0], |
| | | // longitude: +data.latlong[1], |
| | | // iconPath: './map/img/dinw/dinw6.png', |
| | | // }]; |
| | | |
| | | // return d; |
| | | // }, |
| | | // markersCom() { |
| | | // let d = [...this.markers, ...this.jihemarkers]; |
| | | // console.log(d, 6666) |
| | | // return d; |
| | | // }, |
| | | // mypolylinesCom() { |
| | | // // console.log(this.mypolylines,"333333333333333333333") |
| | | // return this.mypolylines.slice(0); |
| | |
| | | data["latlong"] = data.gather.split(","); |
| | | } |
| | | that.ourData = data; |
| | | this.latitude = data.latlong[0]; |
| | | this.longitude = data.latlong[1]; |
| | | |
| | | this.latitude = +data.latlong[0]; |
| | | this.longitude = +data.latlong[1]; |
| | | that.markers[0].latitude = data.latlong[0]; |
| | | that.markers[0].longitude = data.latlong[1]; |
| | | that.circles[0].latitude = data.latlong[0]; |
| | | that.circles[0].longitude = data.latlong[1]; |
| | | //集合标记点 |
| | | that.markers = [{ |
| | | id: 1, |
| | | latitude: data.latlong[0], |
| | | longitude: data.latlong[1], |
| | | iconPath: './map/img/dinw/dinw6.png', |
| | | }] |
| | | that.circles = [{ //在地图上显示圆 |
| | | latitude: data.latlong[0], |
| | | longitude: data.latlong[1], |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 20, //半径 |
| | | strokeWidth: 2 //描边的宽度 |
| | | }] |
| | | // that.jihecircles = [{ |
| | | // id: 444, |
| | | // latitude: +data.latlong[0], |
| | | // longitude: +data.latlong[1], |
| | | // iconPath: './map/img/dinw/dinw6.png', |
| | | // }] |
| | | // that.jihemarkers = [{ //在地图上显示圆 |
| | | // latitude: +data.latlong[0], |
| | | // longitude: +data.latlong[1], |
| | | // fillColor: "#D9E6EF", //填充颜色 |
| | | // color: "#A7B6CB", //描边的颜色 |
| | | // radius: 20, //半径 |
| | | // strokeWidth: 2 //描边的宽度 |
| | | // }] |
| | | |
| | | uni.getSystemInfo({ //初始化地图高度 |
| | | success(res) { |
| | |
| | | <template> |
| | | <view class="content"> |
| | | <!-- <u-top-tips ref="uTips"></u-top-tips> --> |
| | | <u-top-tips ref="uTips"></u-top-tips> |
| | | <!-- <u-button type="info" @click="acc">测试</u-button> --> |
| | | <!-- <web-view :src="urls" @message="message"></web-view> --> |
| | | <map :scale='18' id="myMap" style="width: 100%" :style="{height: mapHeight + 'px'}" :markers="markersCom" |
| | | :longitude="longitude" :latitude="latitude" :circles="circlesCom" :polyline="mypolylines" |
| | | show-location="true"> |
| | | <map :scale='18' id="myMap" style="width: 100%" :style="{height: mapHeight + 'px'}" :markers="markers" |
| | | :longitude="longitude" :latitude="latitude" :circles="circles" :polyline="mypolylines" show-location="true"> |
| | | <cover-view class="dingwBut" @click="mapControlsBack"> |
| | | <cover-image src="./map/img/dingwei.png" @click="mapControlsBack"> |
| | | </cover-image> |
| | |
| | | </span> |
| | | <span class="once-right"> |
| | | <span>{{ourData.fname}}</span> |
| | | </span> |
| | | </view> |
| | | <view class="once"> |
| | | <span class="once-left"> |
| | | 联系方式 |
| | | </span> |
| | | <span class="once-right"> |
| | | <span>{{ourData.phone}}</span> |
| | | </span> |
| | | </view> |
| | | <view class="once"> |
| | |
| | | mapHeight: 0, |
| | | latitude: 28.687205773173343, |
| | | longitude: 115.8995839881188, |
| | | circles: [], //圆 |
| | | markers: [], //标记点 |
| | | circles: [{ |
| | | latitude: '', |
| | | longitude: '', |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 50, //半径 |
| | | strokeWidth: 2, //描边的宽度 |
| | | }, { |
| | | latitude: '', |
| | | longitude: '', |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 10, //半径 |
| | | strokeWidth: 2, //描边的宽度 |
| | | }], //圆 |
| | | markers: [{ |
| | | width: 40, |
| | | height: 40, |
| | | id: 1, |
| | | latitude: '', |
| | | longitude: '', |
| | | iconPath: 'http://223.82.109.183:2081/zhba/upload/20220225/f0aecffbaf0a2ce80f7938569da20de7.png', |
| | | }, { |
| | | width: 40, |
| | | height: 40, |
| | | id: 2, |
| | | latitude: '', |
| | | longitude: '', |
| | | iconPath: 'http://223.82.109.183:2081/zhba/upload/20220225/7b486f647a15e708aca662dbd496dcd3.png', |
| | | }], //标记点 |
| | | jihecircles: [], //集合点 |
| | | jihemarkers: [], //集合点 |
| | | mypolylines: [{ //指定一系列坐标点,从数组第一项连线至最后一项 |
| | |
| | | iconPath: "/static/tabbar/addSelectedIcon.png", |
| | | clickable: true, |
| | | }], //地图控件 |
| | | inThere: true, |
| | | } |
| | | }, |
| | | methods: { |
| | |
| | | this.bye = true; |
| | | uni.redirectTo({ |
| | | url: '/pages/grabOrders/grabOrdersZAYWXC/feedback?data=' + JSON.stringify(this |
| | | .ourData) + |
| | | .ourData) + |
| | | '&other="11111"' |
| | | }); |
| | | } else if (that.ourData.butCT == "begin") { |
| | |
| | | rid: rid, |
| | | serid: serid, |
| | | type: type, |
| | | goto: "grabOrdersZAYWXC", |
| | | // data: JSON.stringify(item), |
| | | that: that, |
| | | fn: () => { |
| | |
| | | that.longitude = res.longitude |
| | | // console.log(that.latitude) |
| | | // console.log(that.longitude) |
| | | that.map.moveToLocation({ |
| | | latitude: res.latitude, |
| | | longitude: res.longitude |
| | | }); |
| | | if (that.inThere) { |
| | | that.inThere = false; |
| | | that.map.moveToLocation({ |
| | | latitude: res.latitude, |
| | | longitude: res.longitude |
| | | }); |
| | | } |
| | | // that.mover(res.longitude, res.latitude); //移动 |
| | | // that.$store.commit("setMsg",d) |
| | | //标记点 |
| | | that.markers = [{ |
| | | id: 1, |
| | | latitude: res.latitude, |
| | | longitude: res.longitude, |
| | | iconPath: './map/img/dinw/dinw1.png', |
| | | }] |
| | | that.circles = [{ //在地图上显示圆 |
| | | latitude: res.latitude, |
| | | longitude: res.longitude, |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 10, //半径 |
| | | strokeWidth: 2 //描边的宽度 |
| | | }] |
| | | that.markers[1].latitude = res.latitude; |
| | | that.markers[1].longitude = res.longitude; |
| | | that.circles[1].latitude = res.latitude; |
| | | that.circles[1].longitude = res.longitude; |
| | | // that.markers = [{ |
| | | // id: 1, |
| | | // latitude: res.latitude, |
| | | // longitude: res.longitude, |
| | | // iconPath: './map/img/dinw/dinw1.png', |
| | | // }] |
| | | // that.circles = [{ //在地图上显示圆 |
| | | // latitude: res.latitude, |
| | | // longitude: res.longitude, |
| | | // fillColor: "#D9E6EF", //填充颜色 |
| | | // color: "#A7B6CB", //描边的颜色 |
| | | // radius: 10, //半径 |
| | | // strokeWidth: 2 //描边的宽度 |
| | | // }] |
| | | if (val != "notSet") { |
| | | let d = { |
| | | id: that.ourData.id, |
| | |
| | | this.longitude = data.latlong[1]; |
| | | |
| | | //集合标记点 |
| | | that.markers = [{ |
| | | id: 1, |
| | | latitude: data.latlong[0], |
| | | longitude: data.latlong[1], |
| | | iconPath: './map/img/dinw/dinw6.png', |
| | | }] |
| | | that.circles = [{ //在地图上显示圆 |
| | | latitude: data.latlong[0], |
| | | longitude: data.latlong[1], |
| | | fillColor: "#D9E6EF", //填充颜色 |
| | | color: "#A7B6CB", //描边的颜色 |
| | | radius: 20, //半径 |
| | | strokeWidth: 2 //描边的宽度 |
| | | }] |
| | | that.markers[0].latitude = data.latlong[0]; |
| | | that.markers[0].longitude = data.latlong[1]; |
| | | that.circles[0].latitude = data.latlong[0]; |
| | | that.circles[0].longitude = data.latlong[1]; |
| | | // that.jihecircles = [{ |
| | | // id: 444, |
| | | // latitude: data.latlong[0], |
| | | // longitude: data.latlong[1], |
| | | // iconPath: './map/img/dinw/dinw6.png', |
| | | // }] |
| | | // that.jihemarkers = [{ //在地图上显示圆 |
| | | // latitude: data.latlong[0], |
| | | // longitude: data.latlong[1], |
| | | // fillColor: "#D9E6EF", //填充颜色 |
| | | // color: "#A7B6CB", //描边的颜色 |
| | | // radius: 20, //半径 |
| | | // strokeWidth: 2 //描边的宽度 |
| | | // }] |
| | | |
| | | uni.getSystemInfo({ //初始化地图高度 |
| | | success(res) { |
| | |
| | | serid = val.serid, |
| | | type = val.type, |
| | | that = val.that, |
| | | goto1 = val.goto, |
| | | // data = val.data, |
| | | tips = (type, title) => { |
| | | that.$refs.uTips.show({ |
| | | title: title, |
| | | type: type, |
| | | duration: '2300' |
| | | }) |
| | | if (that.$refs.uTips) { |
| | | that.$refs.uTips.show({ |
| | | title: title, |
| | | type: type, |
| | | duration: '2300' |
| | | }) |
| | | } |
| | | // that.getGrabOrders(that.current); //重获取数据 |
| | | } |
| | | if (type == "start") { |
| | | type = goto1 + ',' + type |
| | | } |
| | | uni.request({ |
| | | url: $store.state.piAPI + "taskqd/startTask?" + |
| | | `rid=${rid}&serid=${serid}&type=${type}`, |
| | |
| | | state.socket = value; |
| | | }, |
| | | setSocketValue(state, value) { |
| | | // console.log(value) |
| | | console.log(value, 222222222222) |
| | | // if (value.router) { //正常数据返回 |
| | | // //去除心跳数据 |
| | | // if (value.router == 'share/heartbeat') { |
| | |
| | | // } else { //异常数据返回 |
| | | // console.log(value, '异常') |
| | | // } |
| | | if (state.socketValue.type === "start") { |
| | | let route; |
| | | let type; |
| | | let types111 = state.socketValue.type.split(","); |
| | | if (types111.length > 1) { |
| | | route = types111[0]; |
| | | type = types111[1]; |
| | | |
| | | } else { |
| | | type = types111[0]; |
| | | } |
| | | console.log() |
| | | if (type === "start") { |
| | | let types = uni.getSystemInfoSync().platform; |
| | | let |
| | | d = { |
| | | serid: uni.getStorageSync("ids") || $store.state.puserID, |
| | | type: 0, |
| | | tasktype: route == "grabOrdersZAXC" ? 0 : (route == "grabOrdersZAYWXC" ? 1 : 2) |
| | | }; |
| | | let routes = getCurrentPages(); //获取当前页面栈 |
| | | let curRoute = routes[routes.length - 1].route; //获取当前页面的路由 |
| | |
| | | isOn: true |
| | | }); |
| | | console.log(val) |
| | | |
| | | let url = "/pages/grabOrders/map?data=" + JSON.stringify(val); |
| | | if (route) { |
| | | url = "/pages/grabOrders/" + route + "/map?data=" + JSON.stringify(val); |
| | | } |
| | | console.log(url) |
| | | // if (types == "android", curRoute != "pages/grabOrders/map") { |
| | | if (curRoute != "pages/grabOrders/map") { |
| | | uni.navigateTo({ |
| | | url: "/pages/grabOrders/map?data=" + JSON.stringify( |
| | | val), |
| | | url: url, |
| | | }); |
| | | return |
| | | } |
| | | uni.redirectTo({ |
| | | url: "/pages/grabOrders/map?data=" + JSON.stringify(val), |
| | | url: url, |
| | | }); |
| | | } else { |
| | | continue; |