From 1f478b4b033d518f6de21f931d828d2a175b2a3e Mon Sep 17 00:00:00 2001
From: wzp <2880584989@qq.com>
Date: 星期二, 08 三月 2022 13:40:51 +0800
Subject: [PATCH] 最新版本,修复bug

---
 assetMgtH5/main.js |   49 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 49 insertions(+), 0 deletions(-)

diff --git a/assetMgtH5/main.js b/assetMgtH5/main.js
index af36c0f..fdaaabd 100644
--- a/assetMgtH5/main.js
+++ b/assetMgtH5/main.js
@@ -12,9 +12,58 @@
 
 import uView from '@/uni_modules/uview-ui'
 Vue.use(uView)
+//鑷畾涔夊鑸爮
 import cuCustom from './colorui/components/cu-custom.vue'
 Vue.component('cu-custom',cuCustom)
 
+import { http,apiBaseUrl } from '@/api/requestConfig.js'; // 鍏ㄥ眬鎸傝浇寮曞叆锛岄厤缃浉鍏冲湪璇ndex.js鏂囦欢閲屼慨鏀�
+Vue.prototype.$http = http;
+Vue.prototype.$ApiUrl = apiBaseUrl;
+
+
+// 璺敱瀹堝崼
+
+// import UniRouteGuards from 'uniapp-route-guards';
+// Vue.use(UniRouteGuards);
+
+// const guard = new UniRouteGuards();
+
+// // 鑷畾涔夎矾鐢辨嫤鎴櫧鍚嶅崟
+// const WHILE_LIST = [''];
+
+// // 璺宠繃璺敱鐧藉悕鍗曟嫤鎴�
+// guard.beforeEach((to, from, next) => {
+//     if (WHILE_LIST.includes(from.url)) {
+//         return next(to.url);
+//     }
+//     next();
+// });
+
+// // 鎷︽埅 璋冪敤 uni.switchTab 椤甸潰C骞惰烦杞埌 椤甸潰D
+// guard.beforeEach((to, from, next) => {
+//     console.log('\n');
+//     console.log('=================');
+//     console.log('guard.beforeEach');
+//     console.log('to: ', to);
+//     console.log('from: ', from);
+//     console.log('=================');
+//     console.log('\n');
+
+//     if (to.action === 'switchTab' && to.url === '/src/pages/c') {
+//         return next({
+//             url: '/src/pages/d',
+//             action: 'navigateTo'
+//         });
+//     }
+
+//     next();
+// });
+
+
+
+var dayjs = require('dayjs');
+Vue.prototype.$dayjs = dayjs;
+
 // #ifdef VUE3
 import { createSSRApp } from 'vue'
 export function createApp() {

--
Gitblit v1.9.1