trade.go 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. package ferroalloy
  2. import (
  3. "mtp2_if/global/app"
  4. "mtp2_if/models"
  5. "github.com/gin-gonic/gin"
  6. )
  7. // QueryTHJPurchaseTradeDetail
  8. // @Summary 查询我的订单-采购订单
  9. // @Produce json
  10. // @Security ApiKeyAuth
  11. // @Param userid query int true "用户ID"
  12. // @Param type query int false "类型 - 0:未完成 1:已完成"
  13. // @Param page query int false "页码"
  14. // @Param pagesize query int false "每页条数"
  15. // @Success 200 {array} models.Thjpurchasetradedetail
  16. // @Failure 500 {object} app.Response
  17. // @Router /Ferroalloy/QueryTHJPurchaseTradeDetail [get]
  18. // @Tags 铁合金
  19. func QueryTHJPurchaseTradeDetail(c *gin.Context) {
  20. a := app.GinUtils{Gin: app.Gin{C: c}}
  21. m := models.Thjpurchasetradedetail{}
  22. a.DoBindReq(&m)
  23. a.DoGetDataByPage(&m)
  24. }
  25. // QueryTHJTradeData
  26. // @Summary 获取我的推广-交易数据
  27. // @Produce json
  28. // @Security ApiKeyAuth
  29. // @Param userid query int true "用户ID"
  30. // @Param marketid query int true "市场ID 采购-64201 供求-65201"
  31. // @Param page query int false "页码"
  32. // @Param pagesize query int false "每页条数"
  33. // @Success 200 {array} models.THJTradeData
  34. // @Failure 500 {object} app.Response
  35. // @Router /Ferroalloy/QueryTHJTradeData [get]
  36. // @Tags 铁合金
  37. func QueryTHJTradeData(c *gin.Context) {
  38. a := app.GinUtils{Gin: app.Gin{C: c}}
  39. m := models.THJTradeData{}
  40. a.DoBindReq(&m)
  41. a.DoGetDataByPage(&m)
  42. }
  43. // QueryTHJPurchaseTransferOrder
  44. // @Summary 查询我的订单-转让订单
  45. // @Produce json
  46. // @Security ApiKeyAuth
  47. // @Param userid query int true "用户ID"
  48. // @Param page query int false "页码"
  49. // @Param pagesize query int false "每页条数"
  50. // @Success 200 {array} models.Thjpurchasetransfer
  51. // @Failure 500 {object} app.Response
  52. // @Router /Ferroalloy/QueryTHJPurchaseTransferOrder [get]
  53. // @Tags 铁合金
  54. func QueryTHJPurchaseTransferOrder(c *gin.Context) {
  55. a := app.GinUtils{Gin: app.Gin{C: c}}
  56. m := models.Thjpurchasetransfer{}
  57. a.DoBindReq(&m)
  58. a.DoGetDataByPage(&m)
  59. }
  60. // QueryTHJPromotionIncome
  61. // @Summary 查询我的推广-推广收益
  62. // @Produce json
  63. // @Security ApiKeyAuth
  64. // @Param userid query int true "用户ID"
  65. // @Param page query int false "页码"
  66. // @Param pagesize query int false "每页条数"
  67. // @Success 200 {array} models.PromotionIncome
  68. // @Failure 500 {object} app.Response
  69. // @Router /Ferroalloy/QueryTHJPromotionIncome [get]
  70. // @Tags 铁合金
  71. func QueryTHJPromotionIncome(c *gin.Context) {
  72. a := app.GinUtils{Gin: app.Gin{C: c}}
  73. m := models.PromotionIncome{}
  74. a.DoBindReq(&m)
  75. a.DoGetDataByPage(&m)
  76. }
  77. // QueryTHJPromotionIncomeDetail
  78. // @Summary 查询我的推广-推广收益-明细
  79. // @Produce json
  80. // @Security ApiKeyAuth
  81. // @Param userid query int true "用户ID"
  82. // @Param mouth query string true "月份,格式:yyyymm"
  83. // @Param page query int false "页码"
  84. // @Param pagesize query int false "每页条数"
  85. // @Success 200 {array} models.PromotionIncomeDetail
  86. // @Failure 500 {object} app.Response
  87. // @Router /Ferroalloy/QueryTHJPromotionIncomeDetail [get]
  88. // @Tags 铁合金
  89. func QueryTHJPromotionIncomeDetail(c *gin.Context) {
  90. a := app.GinUtils{Gin: app.Gin{C: c}}
  91. m := models.PromotionIncomeDetail{}
  92. a.DoBindReq(&m)
  93. a.DoGetDataByPage(&m)
  94. }