temp
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package IVYZ
|
||||
|
||||
import (
|
||||
xhttp "github.com/zeromicro/x/http"
|
||||
"net/http"
|
||||
"tianyuan-api/pkg/response"
|
||||
|
||||
@@ -14,10 +15,9 @@ func IVYZ5733Handler(svcCtx *svc.ServiceContext) http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
var req types.Request
|
||||
if err := httpx.Parse(r, &req); err != nil {
|
||||
response.Fail(r.Context(), w, err)
|
||||
xhttp.JsonBaseResponseCtx(r.Context(), w, err)
|
||||
return
|
||||
}
|
||||
|
||||
l := IVYZ.NewIVYZ5733Logic(r.Context(), svcCtx)
|
||||
resp, err := l.IVYZ5733(&req)
|
||||
if err != nil {
|
||||
|
||||
@@ -19,7 +19,7 @@ import (
|
||||
func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
server.AddRoutes(
|
||||
rest.WithMiddlewares(
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor},
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor, serverCtx.ApiMqsInterceptor},
|
||||
[]rest.Route{
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
@@ -78,7 +78,7 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
|
||||
server.AddRoutes(
|
||||
rest.WithMiddlewares(
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor},
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor, serverCtx.ApiMqsInterceptor},
|
||||
[]rest.Route{
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
@@ -117,7 +117,7 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
|
||||
server.AddRoutes(
|
||||
rest.WithMiddlewares(
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor},
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor, serverCtx.ApiMqsInterceptor},
|
||||
[]rest.Route{
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
@@ -134,21 +134,11 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
Path: "/JRZQ8203",
|
||||
Handler: JRZQ.JRZQ8203Handler(serverCtx),
|
||||
},
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
Path: "/JRZQCEE8",
|
||||
Handler: JRZQ.JRZQCEE8Handler(serverCtx),
|
||||
},
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
Path: "/JRZQDCBE",
|
||||
Handler: JRZQ.JRZQDCBEHandler(serverCtx),
|
||||
},
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
Path: "/JRZQFEF8",
|
||||
Handler: JRZQ.JRZQFEF8Handler(serverCtx),
|
||||
},
|
||||
}...,
|
||||
),
|
||||
rest.WithPrefix("/api/v1"),
|
||||
@@ -156,7 +146,7 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
|
||||
server.AddRoutes(
|
||||
rest.WithMiddlewares(
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor},
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor, serverCtx.ApiMqsInterceptor},
|
||||
[]rest.Route{
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
@@ -168,11 +158,6 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
Path: "/QYGL45BD",
|
||||
Handler: QYGL.QYGL45BDHandler(serverCtx),
|
||||
},
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
Path: "/QYGL51BC",
|
||||
Handler: QYGL.QYGL51BCHandler(serverCtx),
|
||||
},
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
Path: "/QYGL6F2D",
|
||||
@@ -195,7 +180,7 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
|
||||
server.AddRoutes(
|
||||
rest.WithMiddlewares(
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor},
|
||||
[]rest.Middleware{serverCtx.ApiAuthInterceptor, serverCtx.ApiMqsInterceptor},
|
||||
[]rest.Route{
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
|
||||
Reference in New Issue
Block a user