diff --git a/src/router/tickets/index.js b/src/router/tickets/index.js index a11e6faf7..b07d8a1e4 100644 --- a/src/router/tickets/index.js +++ b/src/router/tickets/index.js @@ -91,26 +91,6 @@ export default { }, hidden: true }, - { - path: 'request-application-perm/create', - name: 'RequestApplicationPermTicketCreateUpdate', - component: () => import('@/views/tickets/RequestApplicationPerm/CreateUpdate'), - meta: { - title: i18n.t('route.TicketCreate'), - permissions: ['tickets.view_ticket'] - }, - hidden: true - }, - { - path: 'request-application-perm/:id', - name: 'AppsTicketDetail', - component: () => import('@/views/tickets/RequestApplicationPerm/Detail'), - meta: { - title: i18n.t('route.TicketDetail'), - permissions: ['tickets.view_ticket'] - }, - hidden: true - }, { path: 'command-confirm/:id', name: 'CommandConfirmDetail', diff --git a/src/views/tickets/BaseTicketList.vue b/src/views/tickets/BaseTicketList.vue index 7770f619f..4bde62cd2 100644 --- a/src/views/tickets/BaseTicketList.vue +++ b/src/views/tickets/BaseTicketList.vue @@ -46,8 +46,6 @@ export default { getRoute: function({ row }) { if (row.type === 'apply_asset') { return 'AssetsTicketDetail' - } else if (row.type === 'apply_application') { - return 'AppsTicketDetail' } else if (row.type === 'login_asset_confirm') { return 'LoginAssetTicketDetail' } else if (row.type === 'login_confirm') { @@ -175,13 +173,6 @@ export default { callback: () => this.$router.push({ name: 'RequestAssetPermTicketCreateUpdate' }) - }, - { - name: 'RequestApplicationPerm', - title: this.$t('tickets.RequestApplicationPerm'), - callback: () => this.$router.push({ - name: 'RequestApplicationPermTicketCreateUpdate' - }) } ] } diff --git a/src/views/tickets/CommandConfirm/Detail/TicketDetail.vue b/src/views/tickets/CommandConfirm/Detail/TicketDetail.vue index f1585059a..2b9f024a3 100644 --- a/src/views/tickets/CommandConfirm/Detail/TicketDetail.vue +++ b/src/views/tickets/CommandConfirm/Detail/TicketDetail.vue @@ -65,8 +65,8 @@ export default { value: object.apply_run_asset }, { - key: this.$t('tickets.ApplyRunSystemUser'), - value: object.rel_snapshot.apply_run_system_user + key: this.$t('tickets.ApplyRunAccount'), + value: object.rel_snapshot.apply_run_account }, { key: this.$t('tickets.ApplyRunCommand'), diff --git a/src/views/tickets/LoginAssetConfirm/Detail/TicketDetail.vue b/src/views/tickets/LoginAssetConfirm/Detail/TicketDetail.vue index f18b3d40b..89d46adb3 100644 --- a/src/views/tickets/LoginAssetConfirm/Detail/TicketDetail.vue +++ b/src/views/tickets/LoginAssetConfirm/Detail/TicketDetail.vue @@ -61,8 +61,8 @@ export default { value: object.rel_snapshot.apply_login_asset }, { - key: this.$t('acl.apply_login_system_user'), - value: object.rel_snapshot.apply_login_system_user + key: this.$t('acl.apply_login_account'), + value: object.rel_snapshot.apply_login_account }, { key: this.$t('acl.apply_login_user'), diff --git a/src/views/tickets/RequestApplicationPerm/CreateUpdate.vue b/src/views/tickets/RequestApplicationPerm/CreateUpdate.vue deleted file mode 100644 index d66bd38ff..000000000 --- a/src/views/tickets/RequestApplicationPerm/CreateUpdate.vue +++ /dev/null @@ -1,212 +0,0 @@ - - - - - diff --git a/src/views/tickets/RequestApplicationPerm/Detail/GroupSelectFormatter.vue b/src/views/tickets/RequestApplicationPerm/Detail/GroupSelectFormatter.vue deleted file mode 100644 index 8ee0f8a8d..000000000 --- a/src/views/tickets/RequestApplicationPerm/Detail/GroupSelectFormatter.vue +++ /dev/null @@ -1,47 +0,0 @@ - - - - - diff --git a/src/views/tickets/RequestApplicationPerm/Detail/TicketDetail.vue b/src/views/tickets/RequestApplicationPerm/Detail/TicketDetail.vue deleted file mode 100644 index ebb1aa32a..000000000 --- a/src/views/tickets/RequestApplicationPerm/Detail/TicketDetail.vue +++ /dev/null @@ -1,268 +0,0 @@ - - - - - diff --git a/src/views/tickets/RequestApplicationPerm/Detail/index.vue b/src/views/tickets/RequestApplicationPerm/Detail/index.vue deleted file mode 100644 index 9e4471950..000000000 --- a/src/views/tickets/RequestApplicationPerm/Detail/index.vue +++ /dev/null @@ -1,50 +0,0 @@ - - - - - diff --git a/src/views/tickets/RequestAssetPerm/CreateUpdate.vue b/src/views/tickets/RequestAssetPerm/CreateUpdate.vue index 06cb69805..b2adc8e97 100644 --- a/src/views/tickets/RequestAssetPerm/CreateUpdate.vue +++ b/src/views/tickets/RequestAssetPerm/CreateUpdate.vue @@ -37,7 +37,7 @@ export default { fields: [ [this.$t('common.Basic'), ['title', 'type', 'org_id', 'comment']], [this.$t('tickets.RequestPerm'), [ - 'apply_nodes', 'apply_assets', 'apply_system_users', + 'apply_nodes', 'apply_assets', 'apply_accounts', 'apply_actions', 'apply_date_start', 'apply_date_expired' ]] ], @@ -81,21 +81,6 @@ export default { } } }, - apply_system_users: { - type: 'systemUserSelect', - component: Select2, - label: this.$t('assets.SystemUser'), - el: { - value: [], - ajax: { - url: '', - transformOption: (item) => { - const username = item.username || '*' - return { label: item.name + '(' + username + ')', value: item.id } - } - } - } - }, org_id: { component: Select2, el: { @@ -108,7 +93,6 @@ export default { }, hidden: (form) => { const fieldsMeta = this.fieldsMeta - fieldsMeta.apply_system_users.el.ajax.url = `/api/v1/assets/system-users/suggestions/?oid=${form['org_id']}&protocol__in=rdp,ssh,vnc,telnet` fieldsMeta.apply_assets.el.ajax.url = `/api/v1/assets/assets/suggestions/?oid=${form['org_id']}` fieldsMeta.apply_nodes.el.ajax.url = `/api/v1/assets/nodes/suggestions/?oid=${form['org_id']}` } @@ -116,7 +100,7 @@ export default { }, cleanFormValue(value) { Object.keys(value).forEach((item, index, arr) => { - if (['apply_system_users', 'apply_assets', 'apply_nodes'].includes(item)) { + if (['apply_accounts', 'apply_assets', 'apply_nodes'].includes(item)) { if (value[item].length < 1) { delete value[item] } diff --git a/src/views/tickets/RequestAssetPerm/Detail/TicketDetail.vue b/src/views/tickets/RequestAssetPerm/Detail/TicketDetail.vue index 4165afdc3..3178e0c3f 100644 --- a/src/views/tickets/RequestAssetPerm/Detail/TicketDetail.vue +++ b/src/views/tickets/RequestAssetPerm/Detail/TicketDetail.vue @@ -21,7 +21,7 @@ - + { - const username = item.username || '*' - return { label: item.name + '(' + username + ')', value: item.id } - } - } } } }, @@ -170,8 +156,8 @@ export default { value: rel_snapshot.apply_assets.join(', ') }, { - key: this.$t('tickets.SystemUser'), - value: rel_snapshot.apply_system_users.join(', ') + key: this.$t('tickets.Account'), + value: rel_snapshot.apply_accounts.join(', ') }, { key: this.$t('assets.Action'), @@ -213,8 +199,8 @@ export default { value: rel_snapshot.apply_assets.join(', ') }, { - key: this.$t('tickets.SystemUser'), - value: rel_snapshot.apply_system_users.join(', ') + key: this.$t('tickets.Account'), + value: rel_snapshot.apply_accounts.join(', ') }, { key: this.$t('assets.Action'), diff --git a/src/views/tickets/TicketDetail/index.vue b/src/views/tickets/TicketDetail/index.vue index 080f686f6..d33312744 100644 --- a/src/views/tickets/TicketDetail/index.vue +++ b/src/views/tickets/TicketDetail/index.vue @@ -50,7 +50,6 @@ export default { afterGetTicket(ticket) { const ticketRouteMapper = { 'apply_asset': 'AssetsTicketDetail', - 'apply_application': 'AppsTicketDetail', 'login_confirm': 'LoginTicketDetail', 'login_asset_confirm': 'LoginAssetTicketDetail', 'command_confirm': 'CommandConfirmDetail' diff --git a/src/views/tickets/components/Session.vue b/src/views/tickets/components/Session.vue index ac4558c9d..70c77acd0 100644 --- a/src/views/tickets/components/Session.vue +++ b/src/views/tickets/components/Session.vue @@ -15,8 +15,8 @@ {{ session.asset }} - {{ $t('tickets.SystemUser') }}: - {{ session.system_user }} + {{ $t('tickets.Account') }}: + {{ session.account }} {{ $t('sessions.UseProtocol') }}: