|
@@ -509,6 +509,7 @@ export default {
|
|
if (res.data.data == "-1") {
|
|
if (res.data.data == "-1") {
|
|
this.$message.error("运输订单未关闭,自提车辆无权查看!");
|
|
this.$message.error("运输订单未关闭,自提车辆无权查看!");
|
|
} else if (res.data.data.startAndEndRoutes) {
|
|
} else if (res.data.data.startAndEndRoutes) {
|
|
|
|
+ console.log("res.data.data:",res.data.data);
|
|
that.listPath = res.data.data.startAndEndRoutes;
|
|
that.listPath = res.data.data.startAndEndRoutes;
|
|
that.initMap([105.602725, 37.076636]);
|
|
that.initMap([105.602725, 37.076636]);
|
|
} else {
|
|
} else {
|
|
@@ -534,7 +535,7 @@ export default {
|
|
that.initThreeMarker();
|
|
that.initThreeMarker();
|
|
//初始化当前点标记
|
|
//初始化当前点标记
|
|
//that.initCustomMarkes(that.carNumber+"("+that.listPath[0].miled+")",that.listPath[0].currentPointName,that.listPath[0].currentPoint.lon,that.listPath[0].currentPoint.lat)
|
|
//that.initCustomMarkes(that.carNumber+"("+that.listPath[0].miled+")",that.listPath[0].currentPointName,that.listPath[0].currentPoint.lon,that.listPath[0].currentPoint.lat)
|
|
- //that.initEndline();
|
|
|
|
|
|
+ that.initEndline();
|
|
});
|
|
});
|
|
},
|
|
},
|
|
//结束点
|
|
//结束点
|
|
@@ -569,11 +570,11 @@ export default {
|
|
element.endPoint != "" &&
|
|
element.endPoint != "" &&
|
|
element.endPoint != null
|
|
element.endPoint != null
|
|
) {
|
|
) {
|
|
- // that.initMarkes(20,35,require('@/assets/img/end.png'),element.endPoint.lon,element.endPoint.lat,'终点');
|
|
|
|
|
|
+ that.initMarkes(20,35,require('@/assets/img/end.png'),element.endPoint.lon,element.endPoint.lat,'终点');
|
|
//终点名称
|
|
//终点名称
|
|
that.getEndPointName([element.endPoint.lon, element.endPoint.lat]);
|
|
that.getEndPointName([element.endPoint.lon, element.endPoint.lat]);
|
|
} else {
|
|
} else {
|
|
- // that.initMarkes(20,35,require('@/assets/img/end.png'),element.runRoute[element.runRoute.length-1].lon,element.runRoute[element.runRoute.length-1].lat,'终点');
|
|
|
|
|
|
+ that.initMarkes(20,35,require('@/assets/img/end.png'),element.runRoute[element.runRoute.length-1].lon,element.runRoute[element.runRoute.length-1].lat,'终点');
|
|
//终点名称
|
|
//终点名称
|
|
that.getEndPointName([
|
|
that.getEndPointName([
|
|
element.runRoute[element.runRoute.length - 1].lon,
|
|
element.runRoute[element.runRoute.length - 1].lon,
|
|
@@ -604,6 +605,7 @@ export default {
|
|
//初始化预计轨迹
|
|
//初始化预计轨迹
|
|
initPolyline(path, color) {
|
|
initPolyline(path, color) {
|
|
let that = this;
|
|
let that = this;
|
|
|
|
+ console.log("path:",path);
|
|
//预计轨迹
|
|
//预计轨迹
|
|
var endLine = new AMap.Polyline({
|
|
var endLine = new AMap.Polyline({
|
|
map: that.map, //地图组件
|
|
map: that.map, //地图组件
|