src/Bundles/Messenger/Entity/Event.php line 13

Open in your IDE?
  1. <?php
  2. namespace Bundles\Messenger\Entity;
  3. use Bundles\Messenger\Repository\EventRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use App\Entity\User;
  6. use App\Entity\CurrencyPair;
  7. /**
  8. * @ORM\Entity(repositoryClass=EventRepository::class)
  9. */
  10. class Event
  11. {
  12. /**
  13. * @ORM\Id
  14. * @ORM\GeneratedValue
  15. * @ORM\Column(type="integer")
  16. */
  17. private $id;
  18. /**
  19. * @ORM\Column(type="string", length=50)
  20. */
  21. private $type;
  22. /**
  23. * @ORM\ManyToOne(targetEntity=User::class, inversedBy="events")
  24. * @ORM\JoinColumn(nullable=false)
  25. */
  26. private $User;
  27. /**
  28. * @ORM\ManyToOne(targetEntity=CurrencyPair::class)
  29. */
  30. private $CurrencyPair;
  31. /**
  32. * @ORM\Column(type="boolean", nullable=true)
  33. */
  34. private $sendSms = false;
  35. /**
  36. * @ORM\Column(type="boolean", nullable=true)
  37. */
  38. private $sendEmail = false;
  39. /**
  40. * @ORM\Column(type="boolean", nullable=true)
  41. */
  42. private $sendWebpush = false;
  43. /**
  44. * @ORM\Column(type="boolean", nullable=true)
  45. */
  46. private $anytime = false;
  47. /**
  48. * @ORM\Column(type="integer", nullable=true)
  49. */
  50. private $sentCount = 0;
  51. /**
  52. * @ORM\Column(type="integer", nullable=false)
  53. */
  54. private $repeatTimes = 0;
  55. /**
  56. * @ORM\Column(type="boolean", nullable=true)
  57. */
  58. private $active = true;
  59. /**
  60. * @ORM\Column(type="string", nullable=true)
  61. */
  62. private $updated = '';
  63. /**
  64. * Breakeven rate
  65. * @ORM\Column(type="string", length=255)
  66. */
  67. private $point;
  68. /**
  69. * @ORM\Column(type="string", length=255)
  70. */
  71. private $message = '';
  72. /**
  73. * @ORM\Column(type="integer", nullable=true)
  74. * int
  75. */
  76. private $flowId;
  77. /**
  78. * @ORM\Column(type="boolean")
  79. */
  80. private $needCheck = true;
  81. /**
  82. * @ORM\Column(type="string", length=50)
  83. */
  84. private $objectType;
  85. public function getId(): ?int
  86. {
  87. return $this->id;
  88. }
  89. public function getType(): ?string
  90. {
  91. return $this->type;
  92. }
  93. public function setType(string $type): self
  94. {
  95. $this->type = $type;
  96. return $this;
  97. }
  98. public function getUser(): ?User
  99. {
  100. return $this->User;
  101. }
  102. public function setUser(?User $User): self
  103. {
  104. $this->User = $User;
  105. return $this;
  106. }
  107. public function getCurrencyPair(): ?CurrencyPair
  108. {
  109. return $this->CurrencyPair;
  110. }
  111. public function setCurrencyPair(?CurrencyPair $CurrencyPair): self
  112. {
  113. $this->CurrencyPair = $CurrencyPair;
  114. return $this;
  115. }
  116. public function isSendSms(): ?bool
  117. {
  118. return $this->sendSms;
  119. }
  120. public function setSendSms(?bool $sendSms): self
  121. {
  122. $this->sendSms = $sendSms;
  123. return $this;
  124. }
  125. public function isSendEmail(): ?bool
  126. {
  127. return $this->sendEmail;
  128. }
  129. public function setSendEmail(?bool $sendEmail): self
  130. {
  131. $this->sendEmail = $sendEmail;
  132. return $this;
  133. }
  134. public function isSendWebpush(): ?bool
  135. {
  136. return $this->sendWebpush;
  137. }
  138. public function setSendWebpush(?bool $sendWebpush): self
  139. {
  140. $this->sendWebpush = $sendWebpush;
  141. return $this;
  142. }
  143. public function isAnytime(): ?bool
  144. {
  145. return $this->anytime;
  146. }
  147. public function setAnytime(?bool $anytime): self
  148. {
  149. $this->anytime = $anytime;
  150. return $this;
  151. }
  152. public function getSentCount(): ?int
  153. {
  154. return $this->sentCount;
  155. }
  156. public function setSentCount(?int $sentCount): self
  157. {
  158. $this->sentCount = $sentCount;
  159. return $this;
  160. }
  161. public function getRepeatTimes(): ?int
  162. {
  163. return $this->repeatTimes;
  164. }
  165. public function setRepeatTimes(?int $repeatTimes): self
  166. {
  167. $this->repeatTimes = $repeatTimes;
  168. return $this;
  169. }
  170. public function getPoint(): ?string
  171. {
  172. return $this->point;
  173. }
  174. public function setPoint(string $point): self
  175. {
  176. $this->point = $point;
  177. return $this;
  178. }
  179. /**
  180. * @return mixed
  181. */
  182. public function getActive() {
  183. return $this->active;
  184. }
  185. /**
  186. * @param mixed $active
  187. */
  188. public function setActive($active): void {
  189. $this->active = $active;
  190. }
  191. /**
  192. * @return string
  193. */
  194. public function getUpdated(): string {
  195. return $this->updated;
  196. }
  197. /**
  198. * @param string $updated
  199. */
  200. public function setUpdated(string $updated): void {
  201. $this->updated = $updated;
  202. }
  203. /**
  204. * Kai reiksme perlipo per nustatyta, pazymime, kad nereikia tikrinti/siusti infos,
  205. * kol spoto reiksme auksciau uz nustatyta ir kol nepasikeis salygos, pranesimu siusti nereikia
  206. * @return bool
  207. */
  208. public function isNeedCheck(): bool {
  209. return $this->needCheck;
  210. }
  211. /**
  212. * @param bool $needCheck
  213. */
  214. public function setNeedCheck(bool $needCheck): void {
  215. $this->needCheck = $needCheck;
  216. }
  217. /**
  218. * @return string
  219. */
  220. public function getMessage(): string {
  221. return $this->message;
  222. }
  223. /**
  224. * @param string $message
  225. */
  226. public function setMessage(string $message): void {
  227. $this->message = $message;
  228. }
  229. /**
  230. * @return mixed
  231. */
  232. public function getFlowId() {
  233. return $this->flowId;
  234. }
  235. /**
  236. * @param mixed $flowId
  237. */
  238. public function setFlowId($flowId): void {
  239. $this->flowId = $flowId;
  240. }
  241. /**
  242. * @return mixed
  243. */
  244. public function getObjectType() {
  245. return $this->objectType;
  246. }
  247. /**
  248. * @param mixed $objectType
  249. */
  250. public function setObjectType($objectType): void {
  251. $this->objectType = $objectType;
  252. }
  253. }