package handler import ( "net/http" "github.com/zeromicro/go-zero/rest/httpx" "bp.jydev.jianyu360.cn/BaseService/jyMicroservices/jyBXCore/api/internal/logic" "bp.jydev.jianyu360.cn/BaseService/jyMicroservices/jyBXCore/api/internal/svc" ) func searchCriteriaHandler(svcCtx *svc.ServiceContext) http.HandlerFunc { return func(w http.ResponseWriter, r *http.Request) { l := logic.NewSearchCriteriaLogic(r.Context(), svcCtx) resp, err := l.SearchCriteria() if err != nil { httpx.ErrorCtx(r.Context(), w, err) } else { httpx.OkJsonCtx(r.Context(), w, resp) } } }