mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2025-11-08 03:00:26 +08:00
实现基本的区域监控终端管理功能
This commit is contained in:
12
internal/db/models/report_node_model_ext.go
Normal file
12
internal/db/models/report_node_model_ext.go
Normal file
@@ -0,0 +1,12 @@
|
||||
package models
|
||||
|
||||
import "encoding/json"
|
||||
|
||||
func (this *ReportNode) DecodeAllowIPs() []string {
|
||||
var result = []string{}
|
||||
if len(this.AllowIPs) > 0 {
|
||||
// 忽略错误
|
||||
_ = json.Unmarshal([]byte(this.AllowIPs), &result)
|
||||
}
|
||||
return result
|
||||
}
|
||||
Reference in New Issue
Block a user