Files
EdgeAdmin/web/views/@default/settings/api/node/createPopup.js
2023-06-05 09:41:52 +08:00

27 lines
643 B
JavaScript

Tea.context(function () {
this.hasHTTPS = false
this.grpcAddrs = []
this.restAddrs = []
this.changeListens = function (addrs) {
this.grpcAddrs = addrs
this.hasHTTPS = this.grpcAddrs.$any(function (k, v) {
return v.protocol == "https"
}) || (this.restIsOn && this.restAddrs.$any(function (k, v) {
return v.protocol == "https"
}))
}
this.changeRestListens = function (addrs) {
this.restAddrs = addrs
this.hasHTTPS = this.grpcAddrs.$any(function (k, v) {
return v.protocol == "https"
}) || (this.restIsOn && this.restAddrs.$any(function (k, v) {
return v.protocol == "https"
}))
}
this.restIsOn = false
})