Commit 02322dea by 姜雷

Merge branch 'develop' into 'test'

Develop See merge request !103
parents 690e02f7 9ae290f4
VUE_APP_BASE_URL=/
VUE_APP_DEV_LIB_URL=
VUE_APP_CUSTOMER_MENU_CODE=0001
VUE_APP_BASE_MENU_CODE=0002
VUE_APP_SYSTEM_MENU_CODE=0003
......
......@@ -9,16 +9,7 @@
<script src="https://unpkg.com/vue@2.6.10/dist/vue.js"></script>
<script src="https://unpkg.com/vuex@3.1.0/dist/vuex.js"></script>
<script src="https://unpkg.com/vue-router@3.0.1/dist/vue-router.js"></script>
<script src="/lib/manageShell.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/customerManage/lib/customerManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/baseManage/lib/baseManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/systemManage/lib/systemManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/operateManage/lib/operateManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/statisticsManage/lib/statisticsManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/deviceManage/lib/deviceManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/smaproManage/lib/smaproManage.umd.min.js"></script>
<link rel="stylesheet" href="/lib/manageShell.css" />
<link rel="stylesheet" href="<%= VUE_APP_DEV_LIB_URL %>/lib/manageShell.css" />
<title>多彩综合管理系统</title>
</head>
......@@ -30,6 +21,15 @@
<div id="app"></div>
<script src="https://webapi.amap.com/maps?v=1.4.12&key=dd6103c90f2f17310a8711f2d330a0a6"></script>
<script src="https://webapi.amap.com/ui/1.0/main.js?v=1.0.11"></script>
<script src="<%= VUE_APP_DEV_LIB_URL %>/lib/manageShell.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/customerManage/lib/customerManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/baseManage/lib/baseManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/systemManage/lib/systemManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/operateManage/lib/operateManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/statisticsManage/lib/statisticsManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/deviceManage/lib/deviceManage.umd.min.js"></script>
<script src="<%= VUE_APP_SUBSYSTEM %>/smaproManage/lib/smaproManage.umd.min.js"></script>
<!-- built files will be auto injected -->
</body>
......
......@@ -148,15 +148,14 @@ export default {
console.log('login done');
this.loading = false;
if (
userRoles.find(
item => item.menuCode === process.env.VUE_APP_DASHBOARD_CODE
) &&
this.$router.options.base === '/'
) {
this.$router.push({ name: 'dashboard' });
let dashboardPage = userRoles.find(
item => item.menuCode === process.env.VUE_APP_DASHBOARD_CODE
);
if (dashboardPage && this.$router.options.base === '/') {
window.location.href =
location.origin + '/' + dashboardPage.menuLink;
} else {
this.$router.push({ path: '/' });
window.location.href = location.origin;
}
})
.catch(err => {
......
......@@ -23,6 +23,7 @@ class SystemShell {
this.storeModule = storeModule;
this.mixinModule = mixinModule;
this.utils = utilsModule;
this.createBaseFetch = createBaseFetch;
}
createSystem = ({
basePath = '/',
......@@ -71,6 +72,5 @@ class SystemShell {
});
return app;
};
createBaseFetch = createBaseFetch;
}
export default new SystemShell();
......@@ -21,7 +21,7 @@ routeNameList.map(name => {
const System = manageShell.default;
System.createSystem({
export default System.createSystem({
basePath: process.env.VUE_APP_BASE_URL,
routers: allAasyncRouterMap,
routeFilter: (routes, allRoute) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment