优化API命名

This commit is contained in:
刘祥超
2021-05-25 17:48:51 +08:00
parent cc76172a46
commit b57b242232
35 changed files with 114 additions and 114 deletions

View File

@@ -35,8 +35,8 @@ func (this *IndexAction) RunGet(params struct {
// 认证
var grantMap interface{} = nil
if cluster.GrantId > 0 {
grantResp, err := this.RPC().NodeGrantRPC().FindEnabledNodeGrant(this.AdminContext(), &pb.FindEnabledNodeGrantRequest{NodeGrantId: cluster.GrantId})
if cluster.NodeGrantId > 0 {
grantResp, err := this.RPC().NodeGrantRPC().FindEnabledNodeGrant(this.AdminContext(), &pb.FindEnabledNodeGrantRequest{NodeGrantId: cluster.NodeGrantId})
if err != nil {
this.ErrorPage(err)
return
@@ -81,7 +81,7 @@ func (this *IndexAction) RunPost(params struct {
_, err := this.RPC().NodeClusterRPC().UpdateNodeCluster(this.AdminContext(), &pb.UpdateNodeClusterRequest{
NodeClusterId: params.ClusterId,
Name: params.Name,
GrantId: params.GrantId,
NodeGrantId: params.GrantId,
InstallDir: params.InstallDir,
})
if err != nil {