huxinglu pirms 4 gadiem
vecāks
revīzija
56d959d80a
5 mainītis faili ar 22 papildinājumiem un 12 dzēšanām
  1. +7
    -0
      src/api/main/index.js
  2. +14
    -11
      src/views/command/index.vue
  3. +1
    -0
      src/views/main/index.vue
  4. +0
    -1
      static/driver.json
  5. Binārs
      static/video-js.swf

+ 7
- 0
src/api/main/index.js Parādīt failu

@@ -26,5 +26,12 @@ export default {
type
}
})
},
getWaterDriver(){
return axios({
url: '/api/index/water/driver',
method: 'GET',
params:{}
})
}
}

+ 14
- 11
src/views/command/index.vue Parādīt failu

@@ -105,7 +105,6 @@
import askLeft from './ask/askLeft'
import {mapGetters} from "vuex";
import api from '@/api/main/index'
import driver from 'static/driver.json'
import problemDetailWin from './problem/problemDetailWin'
import hpDetailWin from './ask/hpDetailWin'
import qualityLeft from './quality/qualityLeft'
@@ -125,6 +124,7 @@
map: {},
center: {},
barHeight: document.body.clientHeight > 1050 ? 2.42 : 2.06,
driverDataList:[],
nameMarkList: [],
routersMarker:[],
polygonList: [],
@@ -192,8 +192,7 @@
routesClick(driverId) {
this.clearRoutersMarker()
this.checkDriver(driverId)
const {data} = driver
let child = data.find(item => item.id == driverId)
let child = this.driverDataList.find(item => item.id == driverId)
if (child&&child.mapInfo&&child.mapInfo.length>0) {
this.initRouters(child)
} else {
@@ -396,18 +395,21 @@
this.checkDriver(marker.childData.dirverId)
},
getDriver() {
const {data} = driver
data.map(item => {
let polygons = this.returnDriver(item)
if (polygons) {
this.driverList.push(polygons)
}
})
api.getWaterDriver({}).then(res => {
this.driverDataList=res.data?res.data:[]
res.data.map(item => {
let polygons = this.returnDriver(item)
if (polygons) {
this.driverList.push(polygons)
}
})
}).catch(e => {
});
},
returnDriver(item) {
let me = this
let polygons = null;
var bounds = item.mapInfo;
var bounds = item.pointList;
if (bounds && bounds.length > 0) {
let path = []
for (let i = 0, l = bounds.length; i < l; i++) {
@@ -428,6 +430,7 @@
});
polygons.name = item.name
polygons.id = item.id
polygons.driverArea=item.driverArea
polygons.on('click', function () {
me.driverId = this.id
me.checkDriver(this.id)

+ 1
- 0
src/views/main/index.vue Parādīt failu

@@ -305,6 +305,7 @@ export default {
position: absolute;
top: 0rem;
width: 100%;
height: 1.04rem;
}

.box-header-title {

+ 0
- 1
static/driver.json
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


Binārs
static/video-js.swf Parādīt failu


Notiek ielāde…
Atcelt
Saglabāt