diff --git a/gui/src/components/modalServer.vue b/gui/src/components/modalServer.vue
index 2a750410..967d94ee 100644
--- a/gui/src/components/modalServer.vue
+++ b/gui/src/components/modalServer.vue
@@ -672,15 +672,6 @@ export default {
}
},
mounted() {
- if (this.readonly) {
- this.$refs.section
- .querySelectorAll("input, textarea")
- .forEach(x => (x.readOnly = "readOnly"));
- this.$refs.section.querySelectorAll("select").forEach(x => {
- const text = x.querySelector(`option[value="${x.value}"]`).textContent;
- x.outerHTML = ``;
- });
- }
if (localStorage["vlessValid"] === "true") {
this.showVLess = true;
this.vlessVersion = 1;
@@ -737,6 +728,19 @@ export default {
this.trojan = this.resolveURL(res.data.data.sharingAddress);
this.tabChoice = 4;
}
+ this.$nextTick(() => {
+ if (this.readonly) {
+ this.$refs.section
+ .querySelectorAll("input, textarea")
+ .forEach(x => (x.readOnly = "readOnly"));
+ this.$refs.section.querySelectorAll("select").forEach(x => {
+ const text = x.querySelector(`option[value="${x.value}"]`)
+ .textContent;
+ console.log(x.value, text);
+ x.outerHTML = ``;
+ });
+ }
+ });
});
});
}