params.go 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. package model
  2. // ArgPointAdd .
  3. type ArgPointAdd struct {
  4. Mid int64 `json:"mid" form:"mid" validate:"required,min=1,gte=1"`
  5. ChangeType int `json:"change_type" form:"change_type" validate:"required"`
  6. RelationID string `json:"relation_id" form:"relation_id"`
  7. Bcoin float64 `json:"bcoin" form:"bcoin" validate:"required"`
  8. Remark string `json:"remark" form:"remark"`
  9. OrderID string `json:"order_id" form:"order_id" validate:"required"`
  10. }
  11. // ArgMid .
  12. type ArgMid struct {
  13. Mid int64 `form:"mid" validate:"required,min=1,gte=1"`
  14. }
  15. //ArgPointHistory .
  16. type ArgPointHistory struct {
  17. Cursor int `form:"cursor"`
  18. PS int `form:"ps"`
  19. PN int `form:"pn"`
  20. }
  21. //ArgOldPointHistory .
  22. type ArgOldPointHistory struct {
  23. Mid int64 `form:"mid"`
  24. PS int `form:"ps"`
  25. PN int `form:"pn"`
  26. }
  27. // ArgConfig biz config.
  28. type ArgConfig struct {
  29. Mid int64 `form:"mid" validate:"required,min=1,gte=1"`
  30. Bp float64 `form:"bp"`
  31. ChangeType int8 `form:"change_type"`
  32. }
  33. // ArgPointConsume .
  34. type ArgPointConsume struct {
  35. Mid int64 `form:"mid" validate:"required,min=1,gte=1"`
  36. ChangeType int64 `form:"change_type" validate:"required,min=1,gte=1"`
  37. RelationID string `form:"relation_id"`
  38. Point int64 `form:"point"`
  39. Remark string `form:"remark"`
  40. }
  41. // ArgPoint .
  42. type ArgPoint struct {
  43. Mid int64 `form:"mid" validate:"required,min=1,gte=1"`
  44. ChangeType int64 `form:"change_type" validate:"required,min=1,gte=1"`
  45. Point int64 `form:"point"`
  46. Remark string `form:"remark"`
  47. Operator string `form:"operator"`
  48. }