mirror of
https://github.com/jumpserver/lina.git
synced 2025-09-17 23:59:02 +00:00
perf: 优化云同步测试账号再次打开后不显示上次选的地域信息
This commit is contained in:
@@ -359,7 +359,7 @@ export default {
|
||||
})
|
||||
},
|
||||
clearSelected() {
|
||||
this.iValue = []
|
||||
this.iValue = this.multiple ? [] : ''
|
||||
},
|
||||
checkDisabled(item) {
|
||||
return item.disabled === undefined ? this.disabledValues.indexOf(item.value) !== -1 : item.disabled
|
||||
|
@@ -7,12 +7,13 @@
|
||||
:confirm-title="$tc('assets.TestConnection')"
|
||||
:loading-status="testLoading"
|
||||
width="50"
|
||||
@close="handleCancel()"
|
||||
@cancel="handleCancel()"
|
||||
@confirm="handleConfirm()"
|
||||
>
|
||||
<el-form ref="regionFrom" label-width="auto" :model="account">
|
||||
<el-form ref="regionForm" label-width="auto" :model="account">
|
||||
<el-form-item :label="$tc('xpack.Cloud.Region')" :rules="regionRules" prop="region">
|
||||
<Select2 v-model="account.region" v-bind="select2" />
|
||||
<Select2 ref="regionSelect" v-model="account.region" v-bind="select2" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</Dialog>
|
||||
@@ -233,9 +234,10 @@ export default {
|
||||
},
|
||||
handleCancel() {
|
||||
this.visible = false
|
||||
this.$refs.regionSelect.clearSelected()
|
||||
},
|
||||
handleConfirm() {
|
||||
this.$refs.regionFrom.validate(valid => {
|
||||
this.$refs.regionForm.validate(valid => {
|
||||
if (valid) {
|
||||
this.testLoading = true
|
||||
this.$axios.get(
|
||||
|
Reference in New Issue
Block a user