fix:修改 project module endpoint 的路由

This commit is contained in:
zhangyu
2022-03-23 18:08:00 +08:00
parent 34a6a92031
commit bd259fd291
5 changed files with 13 additions and 13 deletions

View File

@@ -100,7 +100,7 @@ export default {
permissionCode: 'asset_view'
},
{
route: '/monitor/project',
route: '/project',
title: this.$t('overall.monitor'),
icon: 'nz-icon nz-icon-menu-project',
tip: this.$t('guide.monitorTip'),
@@ -238,7 +238,7 @@ export default {
}
this.$emit('close')
this.$router.push({
path: '/monitor/project',
path: '/project',
query: {
t: +new Date(),
add: 'project'
@@ -252,7 +252,7 @@ export default {
}
this.$emit('close')
this.$router.push({
path: '/monitor/module',
path: '/module',
query: {
t: +new Date(),
add: 'module'
@@ -266,7 +266,7 @@ export default {
}
this.$emit('close')
this.$router.push({
path: '/monitor/endpoint',
path: '/endpoint',
query: {
t: +new Date(),
add: 'endpoint'
@@ -280,7 +280,7 @@ export default {
}
this.$emit('close')
this.$router.push({
path: '/monitor/endpoint',
path: '/endpoint',
query: {
t: +new Date(),
importEndpoint: 'importEndpoint'

View File

@@ -1475,7 +1475,7 @@ export default {
if (this.$route.path === '/assetLabel') {
this.getGroupData()
}
if (this.$route.path === '/monitor/module') {
if (this.$route.path === '/module') {
this.getProjectData()
}
if (this.$route.path === '/alertRule') {

View File

@@ -160,7 +160,7 @@ export default {
},
jumpModule (row) {
localStorage.setItem('moduleProjectId', JSON.stringify([row.id, row.name]))
this.$router.push({ path: '/monitor/module' })
this.$router.push({ path: '/module' })
},
jumpAlertMessage (row) {
localStorage.setItem('alertMessageProjectId', row.id)
@@ -168,7 +168,7 @@ export default {
},
jumpEndpoint (row) {
localStorage.setItem('endpointProjectId', row.id)
this.$router.push({ path: '/monitor/endpoint' })
this.$router.push({ path: '/endpoint' })
}
},
computed: {

View File

@@ -618,7 +618,7 @@ export default {
this.$get(this.url, params).then(response => {
this.tools.loading = false
if (response.code === 200) {
if (response.statistics && this.$route.path === '/monitor/endpoint') {
if (response.statistics && this.$route.path === '/endpoint') {
this.setSearchData(response.statistics)
}
for (let i = 0; i < response.data.list.length; i++) {

View File

@@ -34,16 +34,16 @@ export default new Router({
component: resolve => require(['../components/page/dashboard/overview/overview.vue'], resolve)
},
{
path: '/monitor/project',
path: '/project',
component: resolve => require(['../components/page/monitor/project/index.vue'], resolve)
},
{
path: '/monitor/module',
name: '/monitor/module',
path: '/module',
name: '/module',
component: resolve => require(['../components/page/monitor/module/moduleList.vue'], resolve)
},
{
path: '/monitor/endpoint',
path: '/endpoint',
component: resolve => require(['../components/page/monitor/endpoint/endpointList.vue'], resolve)
},
{