diff --git a/src/router/audit/sessions.js b/src/router/audit/sessions.js index c84ae812f..5675ec732 100644 --- a/src/router/audit/sessions.js +++ b/src/router/audit/sessions.js @@ -34,7 +34,7 @@ export default [ { path: 'command', name: 'CommandList', - component: () => import('@/views/sessions/CommandList'), + component: () => import('@/views/sessions/CommandList/index'), meta: { title: i18n.t('route.Commands'), permissions: ['terminal.view_command'] diff --git a/src/router/console/sessions.js b/src/router/console/sessions.js index 6997519c3..bec33ed55 100644 --- a/src/router/console/sessions.js +++ b/src/router/console/sessions.js @@ -26,7 +26,7 @@ export default [ { path: 'commands', name: 'CommandList', - component: () => import('@/views/sessions/CommandList'), + component: () => import('@/views/sessions/CommandList/index'), meta: { title: i18n.t('route.Commands'), permissions: [] } }, { diff --git a/src/views/assets/Asset/AssetDetail/AssetCommand.vue b/src/views/assets/Asset/AssetDetail/AssetCommand.vue new file mode 100644 index 000000000..fda0e783d --- /dev/null +++ b/src/views/assets/Asset/AssetDetail/AssetCommand.vue @@ -0,0 +1,31 @@ + + + diff --git a/src/views/assets/Asset/AssetDetail/AssetSession.vue b/src/views/assets/Asset/AssetDetail/AssetSession.vue new file mode 100644 index 000000000..88e747568 --- /dev/null +++ b/src/views/assets/Asset/AssetDetail/AssetSession.vue @@ -0,0 +1,30 @@ + + + diff --git a/src/views/assets/Asset/AssetDetail/index.vue b/src/views/assets/Asset/AssetDetail/index.vue index 293e7d0cf..5462c2d2a 100644 --- a/src/views/assets/Asset/AssetDetail/index.vue +++ b/src/views/assets/Asset/AssetDetail/index.vue @@ -16,6 +16,8 @@ import { GenericDetailPage, TabPage } from '@/layout/components' import Detail from './Detail.vue' import Account from './Account.vue' import PermUserList from './PermUser.vue' +import AssetSession from './AssetSession.vue' +import AssetCommand from './AssetCommand.vue' export default { name: 'AssetListDetail', @@ -24,7 +26,9 @@ export default { TabPage, Detail, Account, - PermUserList + PermUserList, + AssetSession, + AssetCommand }, data() { return { @@ -45,6 +49,16 @@ export default { title: this.$t('assets.PermUserList'), name: 'PermUserList', hidden: () => !this.$hasPerm('perms.view_assetpermission') + }, + { + title: this.$t('route.SessionList'), + name: 'AssetSession', + hidden: () => !this.$hasPerm('terminal.view_session') + }, + { + title: this.$t('route.Commands'), + name: 'AssetCommand', + hidden: () => !this.$hasPerm('terminal.view_command') } ], hasRightSide: true, diff --git a/src/views/sessions/CommandList.vue b/src/views/sessions/CommandList/BaseList.vue similarity index 92% rename from src/views/sessions/CommandList.vue rename to src/views/sessions/CommandList/BaseList.vue index 5f58fed44..72fc2b419 100644 --- a/src/views/sessions/CommandList.vue +++ b/src/views/sessions/CommandList/BaseList.vue @@ -1,6 +1,6 @@