mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-04 05:00:25 +08:00
23 lines
456 B
JavaScript
23 lines
456 B
JavaScript
Tea.context(function () {
|
|
this.bind = function (list) {
|
|
this.$post("$")
|
|
.params({
|
|
httpFirewallPolicyId: this.httpFirewallPolicyId,
|
|
listId: list.id
|
|
})
|
|
.success(function () {
|
|
list.isSelected = true
|
|
})
|
|
}
|
|
|
|
this.unbind = function (list) {
|
|
this.$post(".unbindHTTPFirewall")
|
|
.params({
|
|
httpFirewallPolicyId: this.httpFirewallPolicyId,
|
|
listId: list.id
|
|
})
|
|
.success(function () {
|
|
list.isSelected = false
|
|
})
|
|
}
|
|
}) |