coupon.proto 3.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. syntax = "proto3";
  2. package model;
  3. import "github.com/gogo/protobuf/gogoproto/gogo.proto";
  4. option (gogoproto.goproto_enum_prefix_all) = false;
  5. option (gogoproto.goproto_getters_all) = false;
  6. option (gogoproto.unmarshaler_all) = true;
  7. option (gogoproto.marshaler_all) = true;
  8. option (gogoproto.sizer_all) = true;
  9. message CouponInfo {
  10. int64 ID = 1 [(gogoproto.jsontag) = "_"];
  11. string CouponToken = 2 [(gogoproto.jsontag) = "coupon_token"];
  12. int64 Mid = 3 [(gogoproto.jsontag) = "mid"];
  13. int64 State = 4 [(gogoproto.jsontag) = "state"];
  14. int64 StartTime = 5 [(gogoproto.jsontag) = "start_time"];
  15. int64 ExpireTime = 6 [(gogoproto.jsontag) = "expire_time"];
  16. int64 Origin = 7 [(gogoproto.jsontag) = "origin"];
  17. int64 CouponType = 8 [(gogoproto.jsontag) = "coupon_type"];
  18. string OrderNO = 9 [(gogoproto.jsontag) = "order_no"];
  19. int64 Ver = 10 [(gogoproto.jsontag) = "ver"];
  20. int64 Oid = 11 [(gogoproto.jsontag) = "oid"];
  21. string Remark = 12 [(gogoproto.jsontag) = "remark"];
  22. int64 UseVer = 13 [(gogoproto.jsontag) = "use_ver"];
  23. int64 CTime = 14 [(gogoproto.jsontag) = "-", (gogoproto.casttype) = "go-common/library/time.Time"];
  24. int64 MTime = 15 [(gogoproto.jsontag) = "-", (gogoproto.casttype) = "go-common/library/time.Time"];
  25. string BatchToken = 16 [(gogoproto.jsontag) = "batch_token"];
  26. }
  27. message PointInfoList {
  28. repeated CouponInfo pointInfoList = 1;
  29. }
  30. message CouponBalanceInfo {
  31. int64 ID = 1 [(gogoproto.jsontag) = "_"];
  32. string BatchToken = 2 [(gogoproto.jsontag) = "batch_token"];
  33. int64 Mid = 3 [(gogoproto.jsontag) = "mid"];
  34. int64 Balance = 4 [(gogoproto.jsontag) = "balance"];
  35. int64 StartTime = 5 [(gogoproto.jsontag) = "start_time"];
  36. int64 ExpireTime = 6 [(gogoproto.jsontag) = "expire_time"];
  37. int64 Origin = 7 [(gogoproto.jsontag) = "origin"];
  38. int64 CouponType = 8 [(gogoproto.jsontag) = "coupon_type"];
  39. int64 Ver = 9 [(gogoproto.jsontag) = "ver"];
  40. int64 CTime = 10 [(gogoproto.jsontag) = "-", (gogoproto.casttype) = "go-common/library/time.Time"];
  41. int64 MTime = 11 [(gogoproto.jsontag) = "-", (gogoproto.casttype) = "go-common/library/time.Time"];
  42. }
  43. message CouponBalanceList {
  44. repeated CouponBalanceInfo couponBalanceList = 1;
  45. }
  46. message CouponAllowanceInfo {
  47. int64 ID = 1 [(gogoproto.jsontag) = "_"];
  48. string CouponToken = 2 [(gogoproto.jsontag) = "coupon_token"];
  49. int64 Mid = 3 [(gogoproto.jsontag) = "mid"];
  50. int32 State = 4 [(gogoproto.jsontag) = "state"];
  51. int64 StartTime = 5 [(gogoproto.jsontag) = "start_time"];
  52. int64 ExpireTime = 6 [(gogoproto.jsontag) = "expire_time"];
  53. int64 Origin = 7 [(gogoproto.jsontag) = "origin"];
  54. string OrderNO = 8 [(gogoproto.jsontag) = "order_no"];
  55. int64 Ver = 9 [(gogoproto.jsontag) = "ver"];
  56. string Remark = 10 [(gogoproto.jsontag) = "remark"];
  57. int64 CTime = 11 [(gogoproto.jsontag) = "-", (gogoproto.casttype) = "go-common/library/time.Time"];
  58. int64 MTime = 12 [(gogoproto.jsontag) = "-", (gogoproto.casttype) = "go-common/library/time.Time"];
  59. string BatchToken = 13 [(gogoproto.jsontag) = "batch_token"];
  60. double Amount = 14 [(gogoproto.jsontag) = "amount"];
  61. double FullAmount = 15 [(gogoproto.jsontag) = "full_amount"];
  62. int64 AppID = 16 [(gogoproto.jsontag) = "app_id"];
  63. }
  64. message CouponAllowanceList {
  65. repeated CouponAllowanceInfo couponAllowanceList = 1;
  66. }