fix: remove model in adapter page (#2161)

This commit is contained in:
Yaodong Yu
2023-07-29 23:42:08 +08:00
committed by GitHub
parent ea10f8e615
commit 026fb207b3
8 changed files with 53 additions and 121 deletions

View File

@ -145,7 +145,7 @@ func (c *ApiController) DeleteAdapter() {
c.ServeJSON()
}
func (c *ApiController) SyncPolicies() {
func (c *ApiController) GetPolicies() {
id := c.Input().Get("id")
adapter, err := object.GetAdapter(id)
if err != nil {
@ -153,7 +153,7 @@ func (c *ApiController) SyncPolicies() {
return
}
policies, err := object.SyncPolicies(adapter)
policies, err := object.GetPolicies(adapter)
if err != nil {
c.ResponseError(err.Error())
return