diff options
| author | Alireza Ahmadi <alireza7@gmail.com> | 2023-12-08 20:45:21 +0300 |
|---|---|---|
| committer | Alireza Ahmadi <alireza7@gmail.com> | 2023-12-08 20:45:21 +0300 |
| commit | 5fbf8f0d535b131ad6de22a0d1dda0f2167d5ee0 (patch) | |
| tree | c2da678a5d851fe5349644468427c5ba45e24d3d /web/html/xui/inbound_modal.html | |
| parent | bcc897640e68f7a731d39bee04c8930d7d7196c6 (diff) | |
Expand multiDomain to externalProxy #1300
Diffstat (limited to 'web/html/xui/inbound_modal.html')
| -rw-r--r-- | web/html/xui/inbound_modal.html | 28 |
1 files changed, 11 insertions, 17 deletions
diff --git a/web/html/xui/inbound_modal.html b/web/html/xui/inbound_modal.html index df42225c..4ef8f2d6 100644 --- a/web/html/xui/inbound_modal.html +++ b/web/html/xui/inbound_modal.html @@ -43,15 +43,6 @@ loading(loading) { inModal.confirmLoading = loading; }, - getClients(protocol, clientSettings) { - switch (protocol) { - case Protocols.VMESS: return clientSettings.vmesses; - case Protocols.VLESS: return clientSettings.vlesses; - case Protocols.TROJAN: return clientSettings.trojans; - case Protocols.SHADOWSOCKS: return clientSettings.shadowsockses; - default: return null; - } - }, }; new Vue({ @@ -70,7 +61,7 @@ return inModal.isEdit; }, get client() { - return inModal.getClients(this.inbound.protocol, this.inbound.settings)[0]; + return inModal.inbound.clients[0]; }, get delayedExpireDays() { return this.client && this.client.expiryTime < 0 ? this.client.expiryTime / -86400000 : 0; @@ -78,16 +69,19 @@ set delayedExpireDays(days) { this.client.expiryTime = -86400000 * days; }, - get multiDomain() { - return this.inbound.stream.tls.settings.domains.length > 0; + get externalProxy() { + return this.inbound.stream.externalProxy.length > 0; }, - set multiDomain(value) { + set externalProxy(value) { if (value) { - inModal.inbound.stream.tls.server = ""; - inModal.inbound.stream.tls.settings.domains = [{ remark: "", domain: window.location.hostname }]; + inModal.inbound.stream.externalProxy = [{ + forceTls: "same", + dest: window.location.hostname, + port: inModal.inbound.port, + remark: "" + }]; } else { - inModal.inbound.stream.tls.server = ""; - inModal.inbound.stream.tls.settings.domains = []; + inModal.inbound.stream.externalProxy = []; } } }, |
