Files
EdgeAdmin/web/views/@default/servers/server/settings/origins/addPopup.js
2021-06-05 20:27:57 +08:00

18 lines
346 B
JavaScript

Tea.context(function () {
this.addr = ""
this.protocol = ""
if (this.isHTTP) {
this.protocol = "http"
}
this.changeAddr = function () {
if (this.serverType == "httpProxy") {
if (this.addr.startsWith("http://")) {
this.protocol = "http"
} else if (this.addr.startsWith("https://")) {
this.protocol = "https"
}
}
}
})