fund.go 955 B

123456789101112131415161718192021
  1. package api
  2. import "github.com/gogf/gf/v2/frame/g"
  3. type FundListReq struct {
  4. g.Meta `path:"/fund/list" method:"get" tags:"基金相关" summary:"获取基金列表"`
  5. BeginPriceDate string `p:"begin_price_date" v:"date-format:Y-m-d" dc:"起始净值日"`
  6. EndPriceDate string `p:"end_price_date" v:"date-format:Y-m-d" dc:"结束净值日"`
  7. Page int `p:"page" d:"1" v:"required|min:1" dc:"当前页数"`
  8. PageSize int `p:"page_size" d:"10" v:"required|min:1" dc:"单页数据量"`
  9. }
  10. type FundDetailReq struct {
  11. g.Meta `path:"/fund/detail" method:"get" tags:"基金相关" summary:"获取特定基金详情"`
  12. FundId string `p:"fund_id" v:"required|regex:^HF[0-9A-Z]{8}$#基金id缺失|基金格式有误" dc:"基金id"`
  13. }
  14. type FundTestReq struct {
  15. g.Meta `path:"/fund/test" method:"get" tags:"基金相关" summary:"基金模块测试接口"`
  16. FundId string `p:"fund_id" v:"required#基金id缺失" dc:"基金id"`
  17. }