From 23cade0714cf5728fe46583415ed0dd744f98695 Mon Sep 17 00:00:00 2001
From: kongdeqiang <123456>
Date: 星期四, 08 六月 2023 16:52:35 +0800
Subject: [PATCH] 修改前端页面

---
 src/main.js |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/src/main.js b/src/main.js
index 42298d2..1230d2b 100644
--- a/src/main.js
+++ b/src/main.js
@@ -15,6 +15,7 @@
 import TscPrintUtil from './assets/js/TscPrintUtil'
 import Print from './assets/js/print'
 import moment from 'moment'
+import store from './store/index' // 寮曞叆vuex
 Vue.prototype.$moment = moment;
 Vue.use(Print) // 娉ㄥ唽
 import ViewUI from 'view-design';
@@ -83,13 +84,22 @@
 Vue.prototype.$byutil = byUtils
 Vue.prototype.$stringUtil = StringUtil
 Vue.prototype.$tscPrintUtil = TscPrintUtil
-
+// const rolesList = JSON.parse(localStorage.getItem('userRouters')) 
 //浣跨敤閽╁瓙鍑芥暟瀵硅矾鐢辫繘琛屾潈闄愯烦杞�
 // router.beforeEach((to, from, next) => {
 //     let user = byUtils.getUser()
 //     if (!user && to.path!== '/') {
 //         next('/');
 //     }
+
+//    console.log(to,"瑙﹀彂浜�",router.options.routes);
+//    // type 2 : all admin
+//    // type 0 :  娉婅溅 id:2
+//    // type 1 :  鎵ф硶 id:3 
+
+  
+
+//    next();
 //         //
 //     // if (to.path==='/login') {
 //     //     byUtils.setUser(null)
@@ -110,6 +120,7 @@
 //         } else {
 //             next();
 //         }
+
 //     // }
 // })
 // router.beforeEach((to, from, next) => {
@@ -143,5 +154,6 @@
 
 new Vue({
     router,
+    store,
     render: h => h(App)
 }).$mount('#app')

--
Gitblit v1.9.1