Browse Source

完善项目刷新功能和切换页面刷新功能

master
Zhao Qiqi 3 years ago
parent
commit
7256c8aeb4
  1. 1
      anrui-base/anrui-base-ui/src/layout/components/TagsView/index.vue
  2. 56
      anrui-base/anrui-base-ui/src/router/index.js
  3. 2
      anrui-base/anrui-base-ui/src/views/guakaogongsi/guakaogongsiguanli/guakaogongsiguanli.vue
  4. 12
      anrui-base/anrui-base-ui/src/views/redirect/index.vue
  5. 2
      anrui-base/anrui-base-ui/src/views/zifang/zifangguanli/zifangguanli.vue
  6. 2
      anrui-base/anrui-base-ui/src/views/zifang/zifangzhengce/zifangzhengce.vue
  7. 4
      anrui-buscenter/anrui-buscenter-ui/src/layout/components/TagsView/index.vue
  8. 12
      anrui-buscenter/anrui-buscenter-ui/src/router/index.js
  9. 12
      anrui-buscenter/anrui-buscenter-ui/src/views/redirect/index.vue
  10. 3
      anrui-buscenter/anrui-finmanage-ui/src/layout/components/TagsView/index.vue
  11. 12
      anrui-buscenter/anrui-finmanage-ui/src/router/index.js
  12. 12
      anrui-buscenter/anrui-finmanage-ui/src/views/redirect/index.vue
  13. 3
      anrui-management/anrui-management-ui/src/layout/components/TagsView/index.vue
  14. 9
      anrui-management/anrui-management-ui/src/router/index.js
  15. 12
      anrui-management/anrui-management-ui/src/views/redirect/index.vue
  16. 3
      anrui-scm/anrui-scm-ui/src/layout/components/TagsView/index.vue
  17. 12
      anrui-scm/anrui-scm-ui/src/router/index.js
  18. 2
      anrui-scm/anrui-scm-ui/src/router/modules/codemenu.js
  19. 2
      anrui-scm/anrui-scm-ui/src/views/cheliang/hegezhengtaizhang/hegezhengtaizhang.vue
  20. 18
      anrui-scm/anrui-scm-ui/src/views/examinePage/chukushenhe/chukushenheTodo.vue
  21. 12
      anrui-scm/anrui-scm-ui/src/views/redirect/index.vue
  22. 27
      anrui-scm/anrui-scm-ui/src/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangeng.vue
  23. 4
      anrui-scm/anrui-scm-ui/src/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangengAdd.vue
  24. 3
      anrui-system-ui/src/layout/components/TagsView/index.vue
  25. 13
      anrui-system-ui/src/router/index.js
  26. 12
      anrui-system-ui/src/views/redirect/index.vue

1
anrui-base/anrui-base-ui/src/layout/components/TagsView/index.vue

@ -137,7 +137,6 @@ export default {
refreshSelectedTag(view) { refreshSelectedTag(view) {
this.$store.dispatch('tagsView/delCachedView', view).then(() => { this.$store.dispatch('tagsView/delCachedView', view).then(() => {
const { fullPath } = view const { fullPath } = view
console.log('112233',view)
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
path: '/redirect' + fullPath path: '/redirect' + fullPath

56
anrui-base/anrui-base-ui/src/router/index.js

@ -8,6 +8,15 @@ Vue.use(Router)
/* 所有角色可以访问/没有权限要求的基页 */ /* 所有角色可以访问/没有权限要求的基页 */
export const constantRoutes = [ export const constantRoutes = [
{
path: '/redirect',
component: Layout,
hidden: true,
children: [{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect/index.vue')
}]
},
{ {
path: '/', path: '/',
redirect: 'index' redirect: 'index'
@ -53,7 +62,8 @@ export const constantRoutes = [
import('@/views/changshang/changshangguanli/changshangguanli.vue'), import('@/views/changshang/changshangguanli/changshangguanli.vue'),
name: 'changshangguanli', name: 'changshangguanli',
meta: { meta: {
title: '厂商管理' title: '厂商管理',
noCache: true,
} }
}, },
] ]
@ -73,7 +83,8 @@ export const constantRoutes = [
import('@/views/pinpai/pinpaiguanli/pinpaiguanli.vue'), import('@/views/pinpai/pinpaiguanli/pinpaiguanli.vue'),
name: 'pinpaiguanli', name: 'pinpaiguanli',
meta: { meta: {
title: '品牌管理' title: '品牌管理',
noCache: true,
} }
}, },
{ {
@ -83,7 +94,8 @@ export const constantRoutes = [
name: 'pinpaiAdd', name: 'pinpaiAdd',
hidden: true, hidden: true,
meta: { meta: {
title: '品牌管理' title: '品牌管理',
noCache: true,
} }
}, },
{ {
@ -93,7 +105,8 @@ export const constantRoutes = [
name: 'pinpaiInfo', name: 'pinpaiInfo',
hidden: true, hidden: true,
meta: { meta: {
title: '品牌详情' title: '品牌详情',
noCache: true,
} }
}, },
{ {
@ -123,7 +136,8 @@ export const constantRoutes = [
import('@/views/jingxiaoshang/jingxiaoshangguanli/jingxiaoshangguanli.vue'), import('@/views/jingxiaoshang/jingxiaoshangguanli/jingxiaoshangguanli.vue'),
name: 'jingxiaoshangguanli', name: 'jingxiaoshangguanli',
meta: { meta: {
title: '经销商管理' title: '经销商管理',
noCache: true,
} }
}, },
{ {
@ -133,7 +147,8 @@ export const constantRoutes = [
name: 'jingxiaoshangAdd', name: 'jingxiaoshangAdd',
hidden: true, hidden: true,
meta: { meta: {
title: '经销商添加' title: '经销商添加',
noCache: true,
} }
}, },
{ {
@ -143,7 +158,8 @@ export const constantRoutes = [
name: 'jingxiaoshangEdit', name: 'jingxiaoshangEdit',
hidden: true, hidden: true,
meta: { meta: {
title: '经销商修改' title: '经销商修改',
noCache: true,
} }
}, },
{ {
@ -153,7 +169,8 @@ export const constantRoutes = [
name: 'jingxiaoshangInfo', name: 'jingxiaoshangInfo',
hidden: true, hidden: true,
meta: { meta: {
title: '经销商详情' title: '经销商详情',
noCache: true,
} }
} }
// { // {
@ -185,7 +202,8 @@ export const constantRoutes = [
import('@/views/guakaogongsi/guakaogongsiguanli/guakaogongsiguanli.vue'), import('@/views/guakaogongsi/guakaogongsiguanli/guakaogongsiguanli.vue'),
name: 'guakaogongsiguanli', name: 'guakaogongsiguanli',
meta: { meta: {
title: '经销商' title: '经销商',
noCache: true,
} }
}, },
// { // {
@ -245,7 +263,8 @@ export const constantRoutes = [
import('@/views/zifang/zifangguanli/zifangguanli.vue'), import('@/views/zifang/zifangguanli/zifangguanli.vue'),
name: 'zifangguanli', name: 'zifangguanli',
meta: { meta: {
title: '资方信息管理' title: '资方信息管理',
noCache: true,
} }
}, },
{ {
@ -255,7 +274,8 @@ export const constantRoutes = [
name: 'zifangguanliAdd', name: 'zifangguanliAdd',
hidden: true, hidden: true,
meta: { meta: {
title: '资方信息添加' title: '资方信息添加',
noCache: true,
} }
}, },
{ {
@ -265,7 +285,8 @@ export const constantRoutes = [
name: 'zifangguanliInfo', name: 'zifangguanliInfo',
hidden: true, hidden: true,
meta: { meta: {
title: '资方信息详细信息' title: '资方信息详细信息',
noCache: true,
} }
}, },
{ {
@ -274,7 +295,8 @@ export const constantRoutes = [
import('@/views/zifang/zifangzhengce/zifangzhengce.vue'), import('@/views/zifang/zifangzhengce/zifangzhengce.vue'),
name: 'zifangzhengce', name: 'zifangzhengce',
meta: { meta: {
title: '资方政策管理' title: '资方政策管理',
noCache: true,
} }
}, },
{ {
@ -284,7 +306,8 @@ export const constantRoutes = [
name: 'zifangzhengceAdd', name: 'zifangzhengceAdd',
hidden: true, hidden: true,
meta: { meta: {
title: '资方政策添加' title: '资方政策添加',
noCache: true,
} }
}, },
{ {
@ -294,7 +317,8 @@ export const constantRoutes = [
name: 'zifangzhengceInfo', name: 'zifangzhengceInfo',
hidden: true, hidden: true,
meta: { meta: {
title: '资方政策详细信息' title: '资方政策详细信息',
noCache: true,
} }
} }
@ -313,7 +337,7 @@ export const constantRoutes = [
path: '/fileList/index', path: '/fileList/index',
component: () => import('@/views/fileList/fileList.vue'), component: () => import('@/views/fileList/fileList.vue'),
name: 'fileList', name: 'fileList',
meta: { title: '资料清单' } meta: { title: '资料清单',noCache: true, }
}] }]
}, },

2
anrui-base/anrui-base-ui/src/views/guakaogongsi/guakaogongsiguanli/guakaogongsiguanli.vue

@ -168,7 +168,7 @@ import guakaogongsiInfo from './guakaogongsiInfo.vue'
import ButtonBar from '@/components/ButtonBar/index.vue' import ButtonBar from '@/components/ButtonBar/index.vue'
export default { export default {
name: 'Guakaogongsiguanli', name: 'guakaogongsiguanli',
components: { components: {
Pagination, Pagination,
pageye, pageye,

12
anrui-base/anrui-base-ui/src/views/redirect/index.vue

@ -0,0 +1,12 @@
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
}
}
</script>

2
anrui-base/anrui-base-ui/src/views/zifang/zifangguanli/zifangguanli.vue

@ -95,7 +95,7 @@
import zifangguanliAdd from './zifangguanliAdd.vue' import zifangguanliAdd from './zifangguanliAdd.vue'
import zifangguanliInfo from './zifangguanliInfo.vue' import zifangguanliInfo from './zifangguanliInfo.vue'
export default { export default {
name: 'Zifangguanli', name: 'zifangguanli',
components: { components: {
Pagination, Pagination,
pageye, pageye,

2
anrui-base/anrui-base-ui/src/views/zifang/zifangzhengce/zifangzhengce.vue

@ -151,7 +151,7 @@
import { brandLike } from '@/api/jichuxinxi/brandManagement' import { brandLike } from '@/api/jichuxinxi/brandManagement'
import { basefinbankDnamesDown } from '@/api/jichuxinxi/basefinbank' // import { basefinbankDnamesDown } from '@/api/jichuxinxi/basefinbank' //
export default { export default {
name: 'Zifangzhengce', name: 'zifangzhengce',
components: { components: {
Pagination, Pagination,
pageye pageye

4
anrui-buscenter/anrui-buscenter-ui/src/layout/components/TagsView/index.vue

@ -141,8 +141,8 @@
} = view } = view
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
// path: '/redirect' + fullPath path: '/redirect' + fullPath
path: fullPath // path: fullPath
}) })
}) })
}) })

12
anrui-buscenter/anrui-buscenter-ui/src/router/index.js

@ -7,7 +7,17 @@ import codemenu from './modules/codemenu'
Vue.use(Router) Vue.use(Router)
export const constantRoutes = [{ export const constantRoutes = [
{
path: '/redirect',
component: Layout,
hidden: true,
children: [{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect/index.vue')
}]
},
{
path: '/', path: '/',
redirect: 'index' redirect: 'index'
}, { }, {

12
anrui-buscenter/anrui-buscenter-ui/src/views/redirect/index.vue

@ -0,0 +1,12 @@
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
}
}
</script>

3
anrui-buscenter/anrui-finmanage-ui/src/layout/components/TagsView/index.vue

@ -138,8 +138,7 @@ export default {
const { fullPath } = view const { fullPath } = view
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
path: fullPath path: '/redirect' + fullPath
// path: '/redirect' + fullPath
}) })
}) })
}) })

12
anrui-buscenter/anrui-finmanage-ui/src/router/index.js

@ -9,7 +9,17 @@ import Layout from '@/layout'
import codemenu from './modules/codemenu' import codemenu from './modules/codemenu'
export const constantRoutes = [{ export const constantRoutes = [
{
path: '/redirect',
component: Layout,
hidden: true,
children: [{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect/index.vue')
}]
},
{
path: '/', path: '/',
redirect: 'index' redirect: 'index'
}, { }, {

12
anrui-buscenter/anrui-finmanage-ui/src/views/redirect/index.vue

@ -0,0 +1,12 @@
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
}
}
</script>

3
anrui-management/anrui-management-ui/src/layout/components/TagsView/index.vue

@ -130,8 +130,7 @@ export default {
const { fullPath } = view const { fullPath } = view
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
path: fullPath path: '/redirect' + fullPath
// path: '/redirect' + fullPath
}) })
}) })
}) })

9
anrui-management/anrui-management-ui/src/router/index.js

@ -8,6 +8,15 @@ import Layout from '@/layout'
/* 所有角色可以访问/没有权限要求的基页 */ /* 所有角色可以访问/没有权限要求的基页 */
export const constantRoutes = [ export const constantRoutes = [
{
path: '/redirect',
component: Layout,
hidden: true,
children: [{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect/index.vue')
}]
},
{ {
path: '/', path: '/',
redirect: 'index' redirect: 'index'

12
anrui-management/anrui-management-ui/src/views/redirect/index.vue

@ -0,0 +1,12 @@
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
}
}
</script>

3
anrui-scm/anrui-scm-ui/src/layout/components/TagsView/index.vue

@ -139,8 +139,7 @@ export default {
const { fullPath } = view const { fullPath } = view
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
path: fullPath path: '/redirect' + fullPath
// path: '/redirect' + fullPath
}) })
}) })
}) })

12
anrui-scm/anrui-scm-ui/src/router/index.js

@ -9,7 +9,17 @@ import Layout from '@/layout'
import codemenu from './modules/codemenu' import codemenu from './modules/codemenu'
export const constantRoutes = [{ export const constantRoutes = [
{
path: '/redirect',
component: Layout,
hidden: true,
children: [{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect/index.vue')
}]
},
{
path: '/', path: '/',
redirect: 'index' redirect: 'index'
}, { }, {

2
anrui-scm/anrui-scm-ui/src/router/modules/codemenu.js

@ -393,7 +393,7 @@ const codemenu = [
path: '/kucunguanli/rukuguanli', path: '/kucunguanli/rukuguanli',
component: () => import('@/views/supplychain/rukuguanli/rukuguanliAwait.vue'), component: () => import('@/views/supplychain/rukuguanli/rukuguanliAwait.vue'),
name: 'rukuguanliawait', name: 'rukuguanliawait',
meta: { title: '入库车辆管理' } meta: { title: '入库车辆管理',noCache:true }
} }
] ]
}, },

2
anrui-scm/anrui-scm-ui/src/views/cheliang/hegezhengtaizhang/hegezhengtaizhang.vue

@ -85,7 +85,7 @@
<span>{{ scope.row.receiver }}</span> <span>{{ scope.row.receiver }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="备注" width="370px" align="left"> <el-table-column label="备注" width="370px" header-align="center" align="left">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.remarks }}</span> <span>{{ scope.row.remarks }}</span>
</template> </template>

18
anrui-scm/anrui-scm-ui/src/views/examinePage/chukushenhe/chukushenheTodo.vue

@ -9,19 +9,13 @@
type="primary" type="primary"
size="small" size="small"
:disabled="createBtn" :disabled="createBtn"
@click="handleAgree()" @click="handleAgree()">同意</el-button>
>同意</el-button
>
<el-button <el-button
type="primary" type="primary"
size="small" size="small"
:disabled="disabled" :disabled="disabled"
@click="handleDisagree()" @click="handleDisagree()">不同意</el-button>
>不同意</el-button <el-button type="info" size="small" @click="handleReturn()">返回</el-button>
>
<el-button type="info" size="small" @click="handleReturn()"
>返回</el-button
>
</div> </div>
</div> </div>
<div class="listconadd"> <div class="listconadd">
@ -31,8 +25,7 @@
label-position="right" label-position="right"
label-width="100%" label-width="100%"
class="formadd" class="formadd"
:rules="rules" :rules="rules">
>
<div class="tit"> <div class="tit">
出库申请 出库申请
<div class="times"> <div class="times">
@ -56,8 +49,7 @@
</el-col> </el-col>
<el-col :span="4"> <el-col :span="4">
<el-form-item <el-form-item
><span slot="label">是否为终端客户</span></el-form-item ><span slot="label">是否为终端客户</span></el-form-item>
>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item> <el-form-item>

12
anrui-scm/anrui-scm-ui/src/views/redirect/index.vue

@ -0,0 +1,12 @@
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
}
}
</script>

27
anrui-scm/anrui-scm-ui/src/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangeng.vue

@ -61,9 +61,12 @@
<el-table-column width="160px" prop="" label="目标存放地点" align="center"/> <el-table-column width="160px" prop="" label="目标存放地点" align="center"/>
<el-table-column width="130px" prop="" label="经办人" align="center"/> <el-table-column width="130px" prop="" label="经办人" align="center"/>
<el-table-column width="160px" prop="" label="申请费用" align="center"/> <el-table-column width="160px" prop="" label="申请费用" align="center"/>
<el-table-column width="160px" prop="" label="现场照片" align="center"> <el-table-column width="180px" prop="" label="现场照片" align="center">
<template slot-scope="{row}"> <template slot-scope="{row}">
<el-button size="mini" type="primary" @click="handleUpload(row)">上传</el-button> <div class="upload_img">
<upload ref="uploadMoreImg" v-model="imgList" :limit="1" bucket="map" @eett="getList" :upload-data="{type:'0001',modelSid: row.sid}"></upload>
</div>
<!-- <el-button size="mini" type="primary" @click="handleUpload(row)">上传</el-button>-->
<el-button size="mini" type="primary" @click="handleCheckImg(row)">查看</el-button> <el-button size="mini" type="primary" @click="handleCheckImg(row)">查看</el-button>
</template> </template>
</el-table-column> </el-table-column>
@ -84,6 +87,10 @@
</div> </div>
</div> </div>
</div> </div>
<!-- 照片弹窗 -->
<el-dialog title="查看" :visible.sync="dialogImgVisible">
<el-image v-for="item in srcList" style="width: 100px; height: 100px" :src="item" :preview-src-list="srcList"/>
</el-dialog>
<cunfangdidianbiangeng-add v-show="viewState == 2 || viewState == 3" ref="divadd" @doback="resetState" @reloadlist="getList"/> <cunfangdidianbiangeng-add v-show="viewState == 2 || viewState == 3" ref="divadd" @doback="resetState" @reloadlist="getList"/>
<cunfangdidianbiangeng-info v-show="viewState == 4" ref="divinfo" @doback="resetState"/> <cunfangdidianbiangeng-info v-show="viewState == 4" ref="divinfo" @doback="resetState"/>
</div> </div>
@ -97,6 +104,7 @@ import Pagination from '@/components/pagination'
import pageye from '@/components/pagination/pageye' import pageye from '@/components/pagination/pageye'
import cunfangdidianbiangengAdd from '@/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangengAdd' import cunfangdidianbiangengAdd from '@/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangengAdd'
import cunfangdidianbiangengInfo from '@/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangengInfo' import cunfangdidianbiangengInfo from '@/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangengInfo'
import upload from '../../../components/uploadFile/upload_chexing'
export default { export default {
name: 'cunfangdidianbiangeng', name: 'cunfangdidianbiangeng',
@ -105,7 +113,8 @@ export default {
Pagination, Pagination,
pageye, pageye,
cunfangdidianbiangengAdd, cunfangdidianbiangengAdd,
cunfangdidianbiangengInfo cunfangdidianbiangengInfo,
upload
}, },
data() { data() {
@ -114,6 +123,9 @@ export default {
viewState: 1, // 1 2 3 4 viewState: 1, // 1 2 3 4
isSearchShow: false, isSearchShow: false,
tableLoading: false, tableLoading: false,
dialogImgVisible: false,
srcList: [],
imgList:[],
multipleSelection:[], multipleSelection:[],
sids:[], sids:[],
dataList: [], dataList: [],
@ -300,8 +312,9 @@ export default {
handleUpload(){ handleUpload(){
}, },
handleCheckImg(){ handleCheckImg(row){
this.dialogImgVisible = true
// this.srcList = row.vehicleModelUrls
}, },
// //
getModelName() { getModelName() {
@ -358,4 +371,8 @@ export default {
.tab-header /deep/ .el-form-item { .tab-header /deep/ .el-form-item {
margin-bottom: 10px; margin-bottom: 10px;
} }
.upload_img {
display: inline-block;
padding-right: 10px;
}
</style> </style>

4
anrui-scm/anrui-scm-ui/src/views/supplychain/cunfangdidianbiangeng/cunfangdidianbiangengAdd.vue

@ -9,7 +9,7 @@
</div> </div>
<div class="listconadd"> <div class="listconadd">
<div class="title">车辆存放地点变更申请</div> <div class="title">车辆存放地点变更申请</div>
<el-form ref="dataForm" :model="temp" label-position="right" label-width="190px" class="formadd" :rules="rules"> <el-form ref="dataForm" :model="temp" label-position="right" class="formadd" :rules="rules">
<div class="tit"> <div class="tit">
<div class="times"> <div class="times">
<div> <div>
@ -77,8 +77,10 @@
<span>保险状态</span> <span>保险状态</span>
</el-col> </el-col>
<el-col :span="9"> <el-col :span="9">
<el-form-item>
<el-radio v-model="temp.isTerminal" :label="0"></el-radio> <el-radio v-model="temp.isTerminal" :label="0"></el-radio>
<el-radio v-model="temp.isTerminal" :label="1"></el-radio> <el-radio v-model="temp.isTerminal" :label="1"></el-radio>
</el-form-item>
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>

3
anrui-system-ui/src/layout/components/TagsView/index.vue

@ -140,8 +140,7 @@ export default {
const { fullPath } = view const { fullPath } = view
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
path: fullPath path: '/redirect' + fullPath
// path: '/redirect' + fullPath
}) })
}) })
}) })

13
anrui-system-ui/src/router/index.js

@ -1,14 +1,23 @@
import Vue from 'vue' import Vue from 'vue'
import Router from 'vue-router' import Router from 'vue-router'
/* Layout */
import Layout from '@/layout'
Vue.use(Router) Vue.use(Router)
/* Layout */
import Layout from '@/layout'
/* 所有角色可以访问/没有权限要求的基页 */ /* 所有角色可以访问/没有权限要求的基页 */
export const constantRoutes = [ export const constantRoutes = [
{
path: '/redirect',
component: Layout,
hidden: true,
children: [{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect/index.vue')
}]
},
{ {
path: '/', path: '/',
redirect: 'login' redirect: 'login'

12
anrui-system-ui/src/views/redirect/index.vue

@ -0,0 +1,12 @@
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
}
}
</script>
Loading…
Cancel
Save