diff --git a/nezha-fronted/src/components/cli/webSSH.vue b/nezha-fronted/src/components/cli/webSSH.vue index f908fef56..c97f70425 100644 --- a/nezha-fronted/src/components/cli/webSSH.vue +++ b/nezha-fronted/src/components/cli/webSSH.vue @@ -220,9 +220,9 @@
Connect
- - - + + + @@ -244,9 +244,6 @@ v-if="customConnect.authType === 2" :label='$t("webshell.authPriKey")' prop="authPriKey" - :rules="[ - { required: customConnect.authType ===2, message:$t('vali date.required'), trigger: 'change'}, - ]" > @@ -259,19 +256,13 @@ + prop="authUserTip"> @@ -429,6 +420,37 @@ export default { // { validator: this.authPriKeyValid, trigger: 'change' } // ] }, + rulesCustom2: { + authProtocol: [ + { required: true, message: this.$t('validate.required'), trigger: 'change' } + ], + authType: [ + { required: true, message: this.$t('validate.required'), trigger: 'change' } + ], + host: [ + { required: true, message: this.$t('validate.required'), trigger: 'change' }, + { validator: host, trigger: 'change' } + ], + port: [ + { required: true, message: this.$t('validate.required'), trigger: 'change' }, + { validator: port, trigger: 'change' } + ], + authUsername: [ + { required: true, message: this.$t('validate.required'), trigger: 'change' } + ], + authPin: [ + { required: false, message: this.$t('validate.required'), trigger: 'change' } + ], + authUserTip: [ + { required: false, message: this.$t('validate.required'), trigger: 'change' } + ], + authPinTip: [ + { required: false, message: this.$t('validate.required'), trigger: 'change' } + ], + authPriKey: [ + { required: true, message: this.$t('validate.required'), trigger: 'change' } + ] + }, assetData: [], assetLoading: false } @@ -889,6 +911,9 @@ export default { this.customConnect.authPriKey = '' this.customConnect.port = 23 } + setTimeout(()=>{ + this.$refs.customConnect.clearValidate() + }) }, authTypeChange () { if (this.customConnect.authType === 1) { diff --git a/nezha-fronted/src/components/page/dashboard/overview/chartConfig.vue b/nezha-fronted/src/components/page/dashboard/overview/chartConfig.vue index 26dc2aa0c..663c7675c 100644 --- a/nezha-fronted/src/components/page/dashboard/overview/chartConfig.vue +++ b/nezha-fronted/src/components/page/dashboard/overview/chartConfig.vue @@ -438,7 +438,7 @@ const tooltipPieOption = { fontSize: 14 }, top: 8, - left: 8 + right: 8 }, legend: { data: [], diff --git a/nezha-fronted/src/components/page/dashboard/overview/overview.vue b/nezha-fronted/src/components/page/dashboard/overview/overview.vue index e14e4a757..2ebeac187 100644 --- a/nezha-fronted/src/components/page/dashboard/overview/overview.vue +++ b/nezha-fronted/src/components/page/dashboard/overview/overview.vue @@ -635,10 +635,10 @@ export default { endpointOption.series[0].data = [ { name: vm.$t('dashboard.overview.asset.ok'), value: data.asset.ok ? data.asset.ok : 0 }, { name: vm.$t('dashboard.overview.asset.alarm'), value: data.asset.alarm ? data.asset.alarm : 0 }, - { name: vm.$t('dashboard.overview.asset.total'), value: data.asset.total ? data.asset.total : 0 } + // { name: vm.$t('dashboard.overview.asset.total'), value: data.asset.total ? data.asset.total : 0 } ] endpointOption.title.text = vm.$t('asset.asset') - endpointOption.legend.data = [vm.$t('dashboard.overview.asset.ok'), vm.$t('dashboard.overview.asset.alarm'), vm.$t('dashboard.overview.asset.total')] + endpointOption.legend.data = [vm.$t('dashboard.overview.asset.ok'), vm.$t('dashboard.overview.asset.alarm')] prometheusOption.series[0].label.formatter = data.agent.up + '' prometheusOption.series[0].data = [ { name: vm.$t('config.agent.up'), value: data.agent.up ? data.agent.up : 0 }, @@ -1030,7 +1030,6 @@ export default {
${dcStat.asset.ok}
${dcStat.asset.alarm}
-
${dcStat.asset.total}
${dcStat.agent.up}