We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
API的文件定义传参为List,但goctl 并不会实际生成。
The text was updated successfully, but these errors were encountered:
demolist.api
syntax = "v1" type Request { Name string `path:"name,options=you|me"` } type Response { Message string `json:"message"` } service demolist-api { @handler DemolistHandler get /from/:name ([]Request) returns ([]Response) }
goctl api go --api .\demolist.api --dir .
可以看到请求并没有生成List
func DemolistHandler(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 { httpx.ErrorCtx(r.Context(), w, err) return } l := logic.NewDemolistLogic(r.Context(), svcCtx) resp, err := l.Demolist(&req) if err != nil { httpx.ErrorCtx(r.Context(), w, err) } else { httpx.OkJsonCtx(r.Context(), w, resp) } } }
Sorry, something went wrong.
No branches or pull requests
API的文件定义传参为List,但goctl 并不会实际生成。
The text was updated successfully, but these errors were encountered: