增加修正nft质押者接口

This commit is contained in:
2025-01-12 23:11:38 +08:00
parent 63925584d7
commit 2e66a9b024
6 changed files with 111 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
package admin
import (
"net/http"
"github.com/zeromicro/go-zero/rest/httpx"
"nova_task/internal/logic/admin"
"nova_task/internal/svc"
)
// 修正 NFT 质押者
func FixNftStakerHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
l := admin.NewFixNftStakerLogic(r.Context(), svcCtx)
err := l.FixNftStaker()
if err != nil {
httpx.ErrorCtx(r.Context(), w, err)
} else {
httpx.Ok(w)
}
}
}