From c8c2f837639ec68a952904c5f5b69203b80fbb6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E7=A5=A5=E8=B6=85?= Date: Thu, 16 Jun 2022 15:35:14 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E4=B8=8D=E5=BF=85=E8=A6=81?= =?UTF-8?q?=E7=9A=84=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../clusters/monitors/groups/options.go | 32 ------------------- 1 file changed, 32 deletions(-) delete mode 100644 internal/web/actions/default/clusters/monitors/groups/options.go diff --git a/internal/web/actions/default/clusters/monitors/groups/options.go b/internal/web/actions/default/clusters/monitors/groups/options.go deleted file mode 100644 index 3a6b70e2..00000000 --- a/internal/web/actions/default/clusters/monitors/groups/options.go +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved. - -package groups - -import ( - "github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils" - "github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb" - "github.com/iwind/TeaGo/maps" -) - -type OptionsAction struct { - actionutils.ParentAction -} - -func (this *OptionsAction) RunPost(params struct{}) { - resp, err := this.RPC().ReportNodeGroupRPC().FindAllEnabledReportNodeGroups(this.AdminContext(), &pb.FindAllEnabledReportNodeGroupsRequest{}) - if err != nil { - this.ErrorPage(err) - return - } - - var groupMaps = []maps.Map{} - for _, group := range resp.ReportNodeGroups { - groupMaps = append(groupMaps, maps.Map{ - "id": group.Id, - "name": group.Name, - }) - } - this.Data["groups"] = groupMaps - - this.Success() -}