SeckillEntity.php 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. <?php
  2. namespace app\entity\data\product;
  3. use app\entity\data\DataEntity;
  4. class SeckillEntity extends DataEntity
  5. {
  6. public $id = 0; // 自增ID
  7. public $productId = 0; // 秒杀商品ID
  8. public $seckillDate = null; // 秒杀时间段
  9. public $status = 1; // 状态 1 开启 0 关闭 2 已结束
  10. public $ctime = null; // 创建时间
  11. public $merId = 0; // 商户ID
  12. public function getId(): int
  13. {
  14. return $this->id;
  15. }
  16. public function setId(int $id): SeckillEntity
  17. {
  18. $this->id = $id;
  19. return $this;
  20. }
  21. public function getProductId(): int
  22. {
  23. return $this->productId;
  24. }
  25. public function setProductId(int $productId): SeckillEntity
  26. {
  27. $this->productId = $productId;
  28. return $this;
  29. }
  30. /**
  31. * @return null
  32. */
  33. public function getSeckillDate()
  34. {
  35. return $this->seckillDate;
  36. }
  37. /**
  38. * @param null $seckillDate
  39. * @return SeckillEntity
  40. */
  41. public function setSeckillDate($seckillDate)
  42. {
  43. $this->seckillDate = $seckillDate;
  44. return $this;
  45. }
  46. public function getStatus(): int
  47. {
  48. return $this->status;
  49. }
  50. public function setStatus(int $status): SeckillEntity
  51. {
  52. $this->status = $status;
  53. return $this;
  54. }
  55. /**
  56. * @return null
  57. */
  58. public function getCtime()
  59. {
  60. return $this->ctime;
  61. }
  62. /**
  63. * @param null $ctime
  64. * @return SeckillEntity
  65. */
  66. public function setCtime($ctime)
  67. {
  68. $this->ctime = $ctime;
  69. return $this;
  70. }
  71. public function getMerId(): int
  72. {
  73. return $this->merId;
  74. }
  75. public function setMerId(int $merId): SeckillEntity
  76. {
  77. $this->merId = $merId;
  78. return $this;
  79. }
  80. }