支持阿里云DNS

This commit is contained in:
刘祥超
2020-11-15 11:57:43 +08:00
parent 9ce8c83798
commit 5d652c2f77
14 changed files with 178 additions and 27 deletions

View File

@@ -3,6 +3,7 @@ package domains
import (
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"
"github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb"
"github.com/iwind/TeaGo/maps"
)
type RoutesPopupAction struct {
@@ -21,10 +22,14 @@ func (this *RoutesPopupAction) RunGet(params struct {
this.ErrorPage(err)
return
}
if len(routesResp.Routes) == 0 {
routesResp.Routes = []string{}
routeMaps := []maps.Map{}
for _, route := range routesResp.Routes {
routeMaps = append(routeMaps, maps.Map{
"name": route.Name,
"code": route.Code,
})
}
this.Data["routes"] = routesResp.Routes
this.Data["routes"] = routeMaps
this.Show()
}