优化域名服务相关功能

This commit is contained in:
刘祥超
2021-06-01 16:42:25 +08:00
parent d834c2517a
commit 201c3e2f97
15 changed files with 204 additions and 41 deletions

View File

@@ -7,6 +7,7 @@ import (
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/default/dns/domains/domainutils"
"github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb"
"github.com/iwind/TeaGo/actions"
"strings"
)
type CreateAction struct {
@@ -34,6 +35,8 @@ func (this *CreateAction) RunPost(params struct {
this.CreateLogInfo("创建域名 %d", domainId)
}()
params.Name = strings.ToLower(params.Name)
params.Must.
Field("name", params.Name).
Require("请输入域名").