perf: 修改网域列表网关字段跳转

This commit is contained in:
Bai 2022-12-05 18:51:46 +08:00
parent 9623264e56
commit 9e3fbbad10
5 changed files with 14 additions and 3 deletions

View File

@ -179,6 +179,7 @@
"DomainHelpMessage": "The domain function is added to address the fact that some environments (such as the hybrid cloud) cannot be connected directly by jumping on the gateway server.\nJMS => Domain gateway => Target assets", "DomainHelpMessage": "The domain function is added to address the fact that some environments (such as the hybrid cloud) cannot be connected directly by jumping on the gateway server.\nJMS => Domain gateway => Target assets",
"FullName": "Full name", "FullName": "Full name",
"Gateway": "Gateway", "Gateway": "Gateway",
"GatewayList": "Gateway",
"GatewayProtocolHelpText": "SSH protocol gateway, support proxy SSH, RDP, VNC", "GatewayProtocolHelpText": "SSH protocol gateway, support proxy SSH, RDP, VNC",
"Hostname": "Hostname", "Hostname": "Hostname",
"IP": "IP", "IP": "IP",

View File

@ -181,6 +181,7 @@
"DomainHelpMessage": "ドメイン機能は、一部の環境 (ハイブリッドクラウドなど) が直接接続できないことを解決するために追加された機能で、ゲートウェイサーバを介してジャンプ登録を行うのが原理です。JMS => ドメインゲートウェイ => ターゲット資産", "DomainHelpMessage": "ドメイン機能は、一部の環境 (ハイブリッドクラウドなど) が直接接続できないことを解決するために追加された機能で、ゲートウェイサーバを介してジャンプ登録を行うのが原理です。JMS => ドメインゲートウェイ => ターゲット資産",
"FullName": "フルネーム", "FullName": "フルネーム",
"Gateway": "ゲートウェイ", "Gateway": "ゲートウェイ",
"GatewayList": "ゲートウェイの一覧",
"GatewayProtocolHelpText": "SSHゲートウェイ、プロキシSSH、RDP、VNCをサポート", "GatewayProtocolHelpText": "SSHゲートウェイ、プロキシSSH、RDP、VNCをサポート",
"Hostname": "ホスト名", "Hostname": "ホスト名",
"IP": "IP", "IP": "IP",

View File

@ -189,6 +189,7 @@
"DomainHelpMessage": "网域功能是为了解决部分环境混合云无法直接连接而新增的功能原理是通过网关服务器进行跳转登录。JMS => 网域网关 => 目标资产", "DomainHelpMessage": "网域功能是为了解决部分环境混合云无法直接连接而新增的功能原理是通过网关服务器进行跳转登录。JMS => 网域网关 => 目标资产",
"FullName": "全称", "FullName": "全称",
"Gateway": "网关", "Gateway": "网关",
"GatewayList": "网关列表",
"GatewayProtocolHelpText": "SSH网关支持代理SSH,RDP和VNC", "GatewayProtocolHelpText": "SSH网关支持代理SSH,RDP和VNC",
"Hostname": "主机名", "Hostname": "主机名",
"IP": "IP", "IP": "IP",

View File

@ -28,7 +28,7 @@ export default {
name: 'Detail' name: 'Detail'
}, },
{ {
title: this.$t('assets.Gateway'), title: this.$t('assets.GatewayList'),
name: 'GatewayList', name: 'GatewayList',
hidden: () => !this.$hasPerm('assets.view_gateway') hidden: () => !this.$hasPerm('assets.view_gateway')
} }

View File

@ -4,6 +4,7 @@
<script> <script>
import { GenericListPage } from '@/layout/components' import { GenericListPage } from '@/layout/components'
import { DetailFormatter } from '@/components/TableFormatters'
export default { export default {
components: { components: {
@ -32,8 +33,15 @@ export default {
gateway_count: { gateway_count: {
prop: 'gateways', prop: 'gateways',
label: this.$t('assets.Gateway'), label: this.$t('assets.Gateway'),
formatter: function(row) { formatter: DetailFormatter,
return <span> { row.gateways.length } </span> formatterArgs: {
permissions: 'assets.view_gateway',
routeQuery: {
activeTab: 'GatewayList'
},
getTitle: function({ cellValue }) {
return cellValue.length
}
} }
} }
} }