thread-master/apps/backend/internal/handler/publictools/public_style_quiz_handler.go

29 lines
732 B
Go
Raw Permalink Normal View History

2026-07-23 05:56:42 +00:00
// Code generated by goctl. DO NOT EDIT.
// goctl <no value>
package publictools
import (
"net/http"
"apps/backend/internal/logic/publictools"
"apps/backend/internal/response"
"apps/backend/internal/svc"
"apps/backend/internal/types"
"github.com/zeromicro/go-zero/rest/httpx"
)
func PublicStyleQuizHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
var req types.StyleQuizReq
if err := httpx.Parse(r, &req); err != nil {
response.Write(r.Context(), w, nil, response.WrapRequestError(err))
return
}
l := publictools.NewPublicStyleQuizLogic(r.Context(), svcCtx)
data, err := l.PublicStyleQuiz(&req)
response.Write(r.Context(), w, data, err)
}
}