实现公用的IP名单

This commit is contained in:
刘祥超
2021-06-23 13:12:33 +08:00
parent c99547d9e3
commit 8e4ee54f03
88 changed files with 2060 additions and 69 deletions

View File

@@ -0,0 +1,27 @@
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
package iplists
import (
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"
"github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb"
)
type DeleteAction struct {
actionutils.ParentAction
}
func (this *DeleteAction) RunPost(params struct {
ListId int64
}) {
defer this.CreateLogInfo("删除IP名单 %d", params.ListId)
// 删除
_, err := this.RPC().IPListRPC().DeleteIPList(this.AdminContext(), &pb.DeleteIPListRequest{IpListId: params.ListId})
if err != nil {
this.ErrorPage(err)
return
}
this.Success()
}