mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2026-05-21 04:45:19 +08:00
实现缓存策略部分管理功能
This commit is contained in:
@@ -27,7 +27,7 @@ func (this *IndexAction) RunGet(params struct {
|
||||
}
|
||||
|
||||
this.Data["webId"] = webConfig.Id
|
||||
this.Data["cacheConfig"] = webConfig.CacheRef
|
||||
this.Data["cacheConfig"] = webConfig.CacheRefs
|
||||
|
||||
// 所有缓存策略
|
||||
cachePoliciesResp, err := this.RPC().HTTPCachePolicyRPC().FindAllEnabledHTTPCachePolicies(this.AdminContext(), &pb.FindAllEnabledHTTPCachePoliciesRequest{})
|
||||
|
||||
@@ -25,7 +25,7 @@ func (this *IndexAction) RunGet(params struct {
|
||||
}
|
||||
|
||||
this.Data["webId"] = webConfig.Id
|
||||
this.Data["cacheConfig"] = webConfig.CacheRef
|
||||
this.Data["cacheConfig"] = webConfig.CacheRefs
|
||||
|
||||
// 所有缓存策略
|
||||
cachePoliciesResp, err := this.RPC().HTTPCachePolicyRPC().FindAllEnabledHTTPCachePolicies(this.AdminContext(), &pb.FindAllEnabledHTTPCachePoliciesRequest{})
|
||||
|
||||
@@ -100,7 +100,7 @@ func (this *LocationHelper) createMenus(serverIdString string, locationIdString
|
||||
"name": "缓存",
|
||||
"url": "/servers/server/settings/locations/cache?serverId=" + serverIdString + "&locationId=" + locationIdString,
|
||||
"isActive": secondMenuItem == "cache",
|
||||
"isOn": locationConfig != nil && locationConfig.Web != nil && locationConfig.Web.CacheRef != nil && locationConfig.Web.CacheRef.IsPrior,
|
||||
"isOn": locationConfig != nil && locationConfig.Web != nil && len(locationConfig.Web.CacheRefs) > 0,
|
||||
})
|
||||
menuItems = append(menuItems, maps.Map{
|
||||
"name": "访问控制",
|
||||
|
||||
Reference in New Issue
Block a user