Selaa lähdekoodia

fix: 路由调整

TwoKe945 1 vuosi sitten
vanhempi
commit
493a2de8df

+ 7 - 3
app/src/components/Headers.vue

@@ -96,7 +96,7 @@ export default {
         },
       ],
       test: 1,
-      flag: 1,
+      flag: -1,
     };
   },
   mounted() {
@@ -104,9 +104,11 @@ export default {
   },
   methods: {
     ConfirmBtn(item) {
-      this.flag = item.id
       if (item.url && this.$route.path !== item.url) {
+        this.flag = item.id
         this.$router.push(item.url)
+      } else {
+        alert("【" + item.name + "】模块开发中...")
       }
     },
     getClass(v) {
@@ -119,7 +121,9 @@ export default {
   watch: {
     $route: {
       handler(route) {
-        this.flag = route.meta.id
+        if(route.meta.id > 0) {
+          this.flag = route.meta.id
+        }
       },
       immediate: true,
       deep: true

+ 0 - 23
app/src/components/Monitor3D.vue

@@ -295,29 +295,6 @@ function getPie3D(pieData, internalDiameterRatio) {
     legend: {
       top: "200%",
     },
-    labelLine: {
-      show: true,
-      lineStyle: {
-          color: '#404772',
-      },
-    },
-    label: {
-        show: true,
-        position: 'inside',
-        rich: {
-          b: {
-            fontSize: 24,
-            lineHeight: 30,
-            fontWeight: 'bold',
-            color: '#fff',
-          },
-          c: {
-            fontSize: 18,
-            color: '#fff',
-          },
-        },
-        formatter: '{b|{b}}\n{c|{c}%}',
-    },
     tooltip: {
       formatter: (params) => {
         if (params.seriesName !== "mouseoutSeries") {

+ 6 - 6
app/src/router/index.js

@@ -2,7 +2,7 @@ import Vue from "vue";
 import VueRouter from "vue-router";
 import BasicLayout from '@/layouts/BasicLayout.vue'
 import HomePage from "../views/Home/index.vue";
-import BasicInfo from "../views/BasicInfo/index.vue";
+import DetailPage from "../views/Detail/index.vue";
 
 Vue.use(VueRouter);
 
@@ -14,7 +14,7 @@ const router = new VueRouter({
       path: "/",
       name: "basic-layout",
       component: BasicLayout,
-      redirect: '/basic',
+      redirect: '/detail',
       children: [
         {
           path: '/home',
@@ -25,11 +25,11 @@ const router = new VueRouter({
           }
         },
         {
-          path: '/basic',
-          name: 'basic-page',
-          component: BasicInfo,
+          path: '/detail',
+          name: 'detail-page',
+          component: DetailPage,
           meta: {
-            id: 2,
+            id: -1,
           }
         }
       ]

+ 0 - 0
app/src/views/BasicInfo/components/BuildingInfo.vue → app/src/views/Detail/components/BuildingInfo.vue


+ 0 - 0
app/src/views/BasicInfo/components/GementUnit.vue → app/src/views/Detail/components/GementUnit.vue


+ 0 - 0
app/src/views/BasicInfo/components/HiddenDanger.vue → app/src/views/Detail/components/HiddenDanger.vue


+ 0 - 0
app/src/views/BasicInfo/components/HistoricalFire.vue → app/src/views/Detail/components/HistoricalFire.vue


+ 0 - 0
app/src/views/BasicInfo/components/MaintenanceSupervision.vue → app/src/views/Detail/components/MaintenanceSupervision.vue


+ 0 - 0
app/src/views/BasicInfo/components/Risklevel.vue → app/src/views/Detail/components/Risklevel.vue


+ 0 - 0
app/src/views/BasicInfo/components/VideoInfo.vue → app/src/views/Detail/components/VideoInfo.vue


+ 0 - 0
app/src/views/BasicInfo/index.vue → app/src/views/Detail/index.vue