diff --git a/src/router/index.js b/src/router/index.js
index d61ca47..b5f13e5 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -9,6 +9,7 @@ import config from "../config/config";
import {refreshAccessToken} from "../api/common/common";
import dataV from "@/views/datav/dataV";
import copyV from "@/views/datav/copyV";
+import taskdetail from "@/views/datav/taskdetail";
let HOME_PAGE = config.HOME_PAGE;
const currentOrganization = getStore('currentOrganization', true);
@@ -78,7 +79,13 @@ const router = new Router({
{
name: 'copysv',
path: '/copysv',
- component: copyV
+ component: copyV,
+ children: [{
+ name: 'copytaskdetail',
+ path: '/detail/:taskCode',
+ component: taskdetail,
+ meta: {model: 122, info: {show_slider: false, is_inner: true}},
+ }]
},
// {
// name: 'login',
@@ -170,8 +177,7 @@ router.beforeEach((to, from, next) => {
}
}
- if (to.name === 'datasv' || to.path === '/datasv' || to.name === 'copysv' || to.path === '/copysv') {
- console.log('跳转', to);
+ if (to.name === 'datasv' || to.path === '/datasv' || to.name === 'copysv' || to.path.includes('/copysv') ) {
next();
return false;
}
diff --git a/src/views/datav/copyV.vue b/src/views/datav/copyV.vue
index cbcd0b5..2dc8c20 100644
--- a/src/views/datav/copyV.vue
+++ b/src/views/datav/copyV.vue
@@ -22,7 +22,7 @@
>
+
+
+
+
+
+
+
+
+
+
+
+
{{ item.title }}
+
{{ item.create_time }}
+
+
任务: {{ item.content }}
+
+
+ 查看更多
+ 没有更多了
+
+
+
+
+
+
`,
@@ -144,9 +164,7 @@ export default {
});
},
initList() {
- if(!this.now_user.member_code||!this.now_date) return;
- this.map.remove(this.markers);
- if(this.polyline)this.polyline.setMap(null);
+ if(this.markers) this.map.remove(this.markers);
positioningMember({
code: this.now_user.member_code,
date: this.formatDate(new Date(this.now_date||Date.now())),
@@ -154,7 +172,7 @@ export default {
let path = res.data.map((item) => {
return item.split(",");
})||[];
-
+ if(this.polyline) this.polyline.setMap(null);
if(path.length==0) return notice({title: '该成员当日无轨迹信息'}, 'error', 3000);
// 绘制轨迹
this.polyline = new AMap.Polyline({
@@ -175,7 +193,7 @@ export default {
};
-
diff --git a/src/views/index.vue b/src/views/index.vue
index c19b44c..7855cc9 100644
--- a/src/views/index.vue
+++ b/src/views/index.vue
@@ -327,35 +327,35 @@
menuModelClick(event) {
//点击顶部导航跳转页面
console.log('event', event);
- // if(event.key==175){ // 跳转大屏
- // return this.$router.push('/datasv');
- // }
- // if(event.key==180){ // 跳转大屏
- // return this.$router.push('/copysv');
- // }
- let that = this;
- that.menus = that.menu.find(v=>v.id == event.key).children;
- let turnPath = '/';
- if (!that.menus) {
- turnPath += v.fullUrl;
- } else if (!that.menus[0].children) {
- turnPath += that.menus[0].fullUrl;
- } else {
- turnPath += that.menus[0].children[0].fullUrl;
- }
- if(turnPath.includes('datasv')){
- return that.$router.push('/datasv');
- }
- if(turnPath.includes('copysv')){
- return that.$router.push('/copysv');
- }
- if (turnPath == '/home') {
- that.toHome();
- return false;
- }
- if (turnPath != '/#') {
- that.$router.push(turnPath);
- }
+
+ //点击顶部导航跳转页面
+ let that = this;
+ that.menu.forEach(function (v, k) {
+ if (v.id == event.key) {
+ that.menus = v.children;
+ let turnPath = '/';
+ if (!v.children) {
+ turnPath += v.fullUrl;
+ } else if (!v.children[0].children) {
+ turnPath += v.children[0].fullUrl;
+ } else {
+ turnPath += v.children[0].children[0].fullUrl;
+ }
+ if(turnPath.includes('datasv')){
+ return that.$router.push('/datasv');
+ }
+ if(turnPath.includes('copysv')){
+ return that.$router.push('/copysv');
+ }
+ if (turnPath == '/home') {
+ that.toHome();
+ return false;
+ }
+ if (turnPath != '/#') {
+ that.$router.push(turnPath);
+ }
+ }
+ });
},
onModelOpenChange(openKeys) {
},