gaosp
2024-01-17 478bad2360d4b4e379385270f7a52ea895f19807
update
已修改4个文件
18 ■■■■■ 文件已修改
src/container/home/index.vue 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/container/mapPreview/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/container/workshop/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/ajax.js 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/container/home/index.vue
@@ -199,7 +199,7 @@
            })
        },
        goTo (item) {
            if (!item.pathName) {
            if (item.children && item.children.length > 0) { // 有子菜单
                if (item.label === this.activeId) {
                    this.showSub = !this.showSub
                } else {
@@ -209,7 +209,10 @@
                // if(item.pathName) {
                //     this.$router.push({name: item.pathName,params: item.params,query: item.query})
                // }
            } else if(item.pathName){//二级菜单
            } else if (item.pathName && item.children && item.children.length === 0) {
                this.activeId = item.label || this.activeId
                this.$router.push({name: item.pathName,params: item.params,query: item.query})
            } else if(item.pathName){ //二级菜单
                this.$router.push({name: item.pathName,params: item.params,query: item.query})
            } else if(item.href) {
                window.open(item.href)
src/container/mapPreview/index.vue
@@ -1,7 +1,7 @@
<!--
 * @Date: 2024-01-05 22:26:22
 * @LastEditors: Sneed
 * @LastEditTime: 2024-01-16 22:50:48
 * @LastEditTime: 2024-01-17 23:29:15
 * @FilePath: /belleson-frontend/Users/mache/Documents/demo/mdc/src/container/mapPreview/index.vue
-->
<template>
@@ -18,7 +18,7 @@
            <div class="right">
                <Status v-show="id" :info="info" />
                <div class="preview-map">
                    <Map v-if="id" :id="id" :status="2" :currentMap="currentMap" @out="out" />
                    <Map v-if="id" :id="id" :status="2" :currentMap="currentMap" />
                </div>
            </div>
        </div>
src/container/workshop/index.vue
@@ -1,7 +1,7 @@
<!--
 * @Date: 2024-01-06 17:40:19
 * @LastEditors: Sneed
 * @LastEditTime: 2024-01-14 13:24:19
 * @LastEditTime: 2024-01-17 23:30:14
 * @FilePath: /belleson-frontend/Users/mache/Documents/demo/mdc/src/container/workshop/index.vue
-->
<template>
@@ -79,7 +79,7 @@
                this.concernFlag = flag
            }
            getRequest('machineList', {
                plantId: this.$route.params.id,
                workshopId: this.$route.params.id,
                concernFlag: this.concernFlag,
            }).then(res => {
                console.log(res)
src/utils/ajax.js
@@ -1,7 +1,7 @@
/*
 * @Date: 2022-11-09 12:37:25
 * @LastEditors: Sneed
 * @LastEditTime: 2024-01-17 23:18:49
 * @LastEditTime: 2024-01-17 23:20:35
 * @FilePath: /belleson-frontend/Users/mache/Documents/demo/mdc/src/utils/ajax.js
 */
import axios from 'axios'
@@ -23,7 +23,6 @@
// request拦截器
service.interceptors.request.use(config => {
  config.url = `${URL_CFG.BASE_URL}${config.url}`
  console.log('>>>>>>>>>>>???????????',getToken().value)
  if (getToken().value) {
    config.headers['mdc-token'] = getToken().value // 让每个请求携带自定义token 请根据实际情况自行修改
  }