Files
juwan-backend/app/shop/api/internal/handler/shop/myInvitationsHandler.go
T

26 lines
597 B
Go

// Code scaffolded by goctl. Safe to edit.
// goctl 1.10.1
package shop
import (
"net/http"
"github.com/zeromicro/go-zero/rest/httpx"
"juwan-backend/app/shop/api/internal/logic/shop"
"juwan-backend/app/shop/api/internal/svc"
)
// 获取我收到的邀请
func MyInvitationsHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
l := shop.NewMyInvitationsLogic(r.Context(), svcCtx)
resp, err := l.MyInvitations()
if err != nil {
httpx.ErrorCtx(r.Context(), w, err)
} else {
httpx.OkJsonCtx(r.Context(), w, resp)
}
}
}