src/Entity/Distributors.php line 11

  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\DistributorsRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. #[ORM\Entity(repositoryClass: DistributorsRepository::class)]
  8. class Distributors
  9. {
  10. #[ORM\Id]
  11. #[ORM\GeneratedValue]
  12. #[ORM\Column(type: 'integer')]
  13. private $id;
  14. #[ORM\Column(type: 'string', length: 255)]
  15. private $distributorName;
  16. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  17. private $logo;
  18. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  19. private $telephone;
  20. #[ORM\Column(type: 'string', length: 255)]
  21. private $email;
  22. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  23. private $website;
  24. #[ORM\Column(type: 'text', nullable: true)]
  25. private $about;
  26. #[ORM\Column(type: 'text', nullable: true)]
  27. private $operatingHours;
  28. #[ORM\Column(type: 'text', nullable: true)]
  29. private $refundPolicy;
  30. #[ORM\Column(type: 'text', nullable: true)]
  31. private $salesTaxPolicy;
  32. #[ORM\Column(type: 'boolean', nullable: true)]
  33. private $isManufaturer;
  34. #[ORM\Column(type: 'integer', nullable: true)]
  35. private $themeId;
  36. #[ORM\Column(type: 'datetime')]
  37. private $modified;
  38. #[ORM\Column(type: 'datetime')]
  39. private $created;
  40. #[ORM\OneToMany(targetEntity: DistributorClinicPrices::class, mappedBy: 'distributor')]
  41. private $distributorClinicPrices;
  42. #[ORM\OneToMany(targetEntity: DistributorProducts::class, mappedBy: 'distributor')]
  43. private $distributorProducts;
  44. #[ORM\OneToMany(targetEntity: DistributorUsers::class, mappedBy: 'distributor')]
  45. private $distributorUsers;
  46. #[ORM\OneToMany(targetEntity: EventLog::class, mappedBy: 'distributor')]
  47. private $eventLogs;
  48. #[ORM\OneToMany(targetEntity: OrderItems::class, mappedBy: 'distributor')]
  49. private $orderItems;
  50. #[ORM\OneToMany(targetEntity: ListItems::class, mappedBy: 'distributor')]
  51. private $listItems;
  52. #[ORM\OneToMany(targetEntity: BasketItems::class, mappedBy: 'distributor')]
  53. private $basketItems;
  54. #[ORM\OneToMany(targetEntity: ClinicProducts::class, mappedBy: 'distributor')]
  55. private $clinicProducts;
  56. #[ORM\OneToMany(targetEntity: AvailabilityTracker::class, mappedBy: 'distributor')]
  57. private $availabilityTrackers;
  58. #[ORM\Column(type: 'string', length: 10, nullable: true)]
  59. private $poNumberPrefix;
  60. #[ORM\OneToMany(targetEntity: ChatParticipants::class, mappedBy: 'distributor')]
  61. private $chatParticipants;
  62. #[ORM\OneToMany(targetEntity: ChatMessages::class, mappedBy: 'distributor')]
  63. private $chatMessages;
  64. #[ORM\OneToMany(targetEntity: Notifications::class, mappedBy: 'distributor')]
  65. private $notifications;
  66. #[ORM\OneToMany(targetEntity: OrderStatus::class, mappedBy: 'distributor')]
  67. private $orderStatuses;
  68. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  69. private $addressStreet;
  70. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  71. private $addressCity;
  72. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  73. private $addressPostalCode;
  74. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  75. private $addressState;
  76. #[ORM\ManyToOne(targetEntity: Countries::class, inversedBy: 'distributors')]
  77. private $addressCountry;
  78. #[ORM\Column(type: 'text', nullable: true)]
  79. private $shippingPolicy;
  80. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  81. private $isoCode;
  82. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  83. private $intlCode;
  84. #[ORM\OneToMany(targetEntity: DistributorUserPermissions::class, mappedBy: 'distributor')]
  85. private $distributorUserPermissions;
  86. #[ORM\OneToOne(targetEntity: ApiDetails::class, mappedBy: 'distributor', cascade: ['persist', 'remove'])]
  87. private $api;
  88. #[ORM\OneToMany(targetEntity: DistributorClinics::class, mappedBy: 'distributor')]
  89. private $distributorClinics;
  90. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  91. private $hashedEmail;
  92. #[ORM\ManyToOne(targetEntity: Tracking::class, inversedBy: 'distributors')]
  93. #[ORM\JoinColumn(nullable: false)]
  94. private $tracking;
  95. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  96. private $domainName;
  97. #[ORM\Column(type: 'integer', nullable: true)]
  98. private $isApproved;
  99. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  100. private $managerFirstName;
  101. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  102. private $managerLastName;
  103. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  104. private $tradeLicense;
  105. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  106. private $tradeLicenseNo;
  107. #[ORM\Column(type: 'date', nullable: true)]
  108. private $tradeLicenseExpDate;
  109. #[ORM\Column(type: 'string', length: 255, nullable: true)]
  110. private $managerIdNo;
  111. #[ORM\Column(type: 'date', nullable: true)]
  112. private $managerIdExpDate;
  113. #[ORM\OneToMany(targetEntity: ControlledDrugFiles::class, mappedBy: 'distributor')]
  114. private $controlledDrugFiles;
  115. /**
  116. * @var Collection<int, CustomPriceLists>
  117. */
  118. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: CustomPriceLists::class)]
  119. private Collection $customPriceLists;
  120. #[ORM\OneToOne(mappedBy: 'distributor', cascade: ['persist', 'remove'])]
  121. private ?ScraperAunthentication $scraperAunthentication = null;
  122. /**
  123. * @var Collection<int, ScraperUrls>
  124. */
  125. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: ScraperUrls::class)]
  126. private Collection $scraperUrls;
  127. /**
  128. * @var Collection<int, ClinicDistributorContacts>
  129. */
  130. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: ClinicDistributorContacts::class)]
  131. private Collection $clinicDistributorContacts;
  132. /**
  133. * @var Collection<int, ScraperLog>
  134. */
  135. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: ScraperLog::class)]
  136. private Collection $scraperLogs;
  137. /**
  138. * @var Collection<int, ScraperProducts>
  139. */
  140. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: ScraperProducts::class)]
  141. private Collection $scraperProducts;
  142. /**
  143. * @var Collection<int, AiDistributorProducts>
  144. */
  145. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiDistributorProducts::class)]
  146. private Collection $aiDistributorProducts;
  147. /**
  148. * @var Collection<int, AiListItems>
  149. */
  150. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiListItems::class)]
  151. private Collection $aiListItems;
  152. /**
  153. * @var Collection<int, AiBasketItems>
  154. */
  155. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiBasketItems::class)]
  156. private Collection $aiBasketItems;
  157. /**
  158. * @var Collection<int, AiOrderItems>
  159. */
  160. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiOrderItems::class)]
  161. private Collection $aiOrderItems;
  162. /**
  163. * @var Collection<int, AiClinicProducts>
  164. */
  165. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiClinicProducts::class)]
  166. private Collection $aiClinicProducts;
  167. /**
  168. * @var Collection<int, AiCustomPriceLists>
  169. */
  170. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiCustomPriceLists::class)]
  171. private Collection $aiCustomPriceLists;
  172. /**
  173. * @var Collection<int, AiControlledDrugFiles>
  174. */
  175. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiControlledDrugFiles::class)]
  176. private Collection $aiControlledDrugFiles;
  177. /**
  178. * @var Collection<int, AiOrderStatus>
  179. */
  180. #[ORM\OneToMany(mappedBy: 'distributor', targetEntity: AiOrderStatus::class)]
  181. private Collection $aiOrderStatuses;
  182. public function __construct()
  183. {
  184. $date = new \DateTime("now", new \DateTimeZone('Asia/Dubai'));
  185. $this->setModified($date);
  186. if ($this->getCreated() == null)
  187. {
  188. $this->setCreated($date);
  189. }
  190. $this->distributors = new ArrayCollection();
  191. $this->distributorClinicPrices = new ArrayCollection();
  192. $this->distributorProducts = new ArrayCollection();
  193. $this->distributorUsers = new ArrayCollection();
  194. $this->eventLogs = new ArrayCollection();
  195. $this->orderItems = new ArrayCollection();
  196. $this->listItems = new ArrayCollection();
  197. $this->basketItems = new ArrayCollection();
  198. $this->clinicProducts = new ArrayCollection();
  199. $this->availabilityTrackers = new ArrayCollection();
  200. $this->chatParticipants = new ArrayCollection();
  201. $this->chatMessages = new ArrayCollection();
  202. $this->notifications = new ArrayCollection();
  203. $this->orderStatuses = new ArrayCollection();
  204. $this->distributorUserPermissions = new ArrayCollection();
  205. $this->refreshTokens = new ArrayCollection();
  206. $this->distributorClinics = new ArrayCollection();
  207. $this->controlledDrugFiles = new ArrayCollection();
  208. $this->customPriceLists = new ArrayCollection();
  209. $this->scraperUrls = new ArrayCollection();
  210. $this->clinicDistributorContacts = new ArrayCollection();
  211. $this->scraperLogs = new ArrayCollection();
  212. $this->scraperImages = new ArrayCollection();
  213. $this->scraperProducts = new ArrayCollection();
  214. $this->aiDistributorProducts = new ArrayCollection();
  215. $this->aiListItems = new ArrayCollection();
  216. $this->aiBasketItems = new ArrayCollection();
  217. $this->aiOrderItems = new ArrayCollection();
  218. $this->aiClinicProducts = new ArrayCollection();
  219. $this->aiCustomPriceLists = new ArrayCollection();
  220. $this->aiControlledDrugFiles = new ArrayCollection();
  221. $this->aiOrderStatuses = new ArrayCollection();
  222. }
  223. public function getId(): ?int
  224. {
  225. return $this->id;
  226. }
  227. public function getDistributorName(): ?string
  228. {
  229. return $this->distributorName;
  230. }
  231. public function setDistributorName(string $distributorName): self
  232. {
  233. $this->distributorName = $distributorName;
  234. return $this;
  235. }
  236. public function getLogo(): ?string
  237. {
  238. return $this->logo;
  239. }
  240. public function setLogo(string $logo): self
  241. {
  242. $this->logo = $logo;
  243. return $this;
  244. }
  245. public function getEmail(): ?string
  246. {
  247. return $this->email;
  248. }
  249. public function setEmail(string $email): self
  250. {
  251. $this->email = $email;
  252. return $this;
  253. }
  254. public function getTelephone(): ?string
  255. {
  256. return $this->telephone;
  257. }
  258. public function setTelephone(string $telephone): self
  259. {
  260. $this->telephone = $telephone;
  261. return $this;
  262. }
  263. public function getWebsite(): ?string
  264. {
  265. return $this->website;
  266. }
  267. public function setWebsite(string $website): self
  268. {
  269. $this->website = $website;
  270. return $this;
  271. }
  272. public function getAbout(): ?string
  273. {
  274. return $this->about;
  275. }
  276. public function setAbout(?string $about): self
  277. {
  278. $this->about = $about;
  279. return $this;
  280. }
  281. public function getOperatingHours(): ?string
  282. {
  283. return $this->operatingHours;
  284. }
  285. public function setOperatingHours(string $operatingHours): self
  286. {
  287. $this->operatingHours = $operatingHours;
  288. return $this;
  289. }
  290. public function getRefundPolicy(): ?string
  291. {
  292. return $this->refundPolicy;
  293. }
  294. public function setRefundPolicy(string $refundPolicy): self
  295. {
  296. $this->refundPolicy = $refundPolicy;
  297. return $this;
  298. }
  299. public function getSalesTaxPolicy(): ?string
  300. {
  301. return $this->salesTaxPolicy;
  302. }
  303. public function setSalesTaxPolicy(string $salesTaxPolicy): self
  304. {
  305. $this->salesTaxPolicy = $salesTaxPolicy;
  306. return $this;
  307. }
  308. public function getIsManufaturer(): ?bool
  309. {
  310. return $this->isManufaturer;
  311. }
  312. public function setIsManufaturer(bool $isManufaturer): self
  313. {
  314. $this->isManufaturer = $isManufaturer;
  315. return $this;
  316. }
  317. public function getThemeId(): ?int
  318. {
  319. return $this->themeId;
  320. }
  321. public function setThemeId(?int $themeId): self
  322. {
  323. $this->themeId = $themeId;
  324. return $this;
  325. }
  326. public function getModified(): ?\DateTimeInterface
  327. {
  328. return $this->modified;
  329. }
  330. public function setModified(\DateTimeInterface $modified): self
  331. {
  332. $this->modified = $modified;
  333. return $this;
  334. }
  335. public function getCreated(): ?\DateTimeInterface
  336. {
  337. return $this->created;
  338. }
  339. public function setCreated(\DateTimeInterface $created): self
  340. {
  341. $this->created = $created;
  342. return $this;
  343. }
  344. /**
  345. * @return Collection|DistributorClinicPrices[]
  346. */
  347. public function getDistributorClinicPrices(): Collection
  348. {
  349. return $this->distributorClinicPrices;
  350. }
  351. public function addDistributorClinicPrice(DistributorClinicPrices $distributorClinicPrice): self
  352. {
  353. if (!$this->distributorClinicPrices->contains($distributorClinicPrice)) {
  354. $this->distributorClinicPrices[] = $distributorClinicPrice;
  355. $distributorClinicPrice->setDistributor($this);
  356. }
  357. return $this;
  358. }
  359. public function removeDistributorClinicPrice(DistributorClinicPrices $distributorClinicPrice): self
  360. {
  361. if ($this->distributorClinicPrices->removeElement($distributorClinicPrice)) {
  362. // set the owning side to null (unless already changed)
  363. if ($distributorClinicPrice->getDistributor() === $this) {
  364. $distributorClinicPrice->setDistributor(null);
  365. }
  366. }
  367. return $this;
  368. }
  369. /**
  370. * @return Collection|DistributorProducts[]
  371. */
  372. public function getDistributorProducts(): Collection
  373. {
  374. return $this->distributorProducts;
  375. }
  376. public function addDistributorProduct(DistributorProducts $distributorProduct): self
  377. {
  378. if (!$this->distributorProducts->contains($distributorProduct)) {
  379. $this->distributorProducts[] = $distributorProduct;
  380. $distributorProduct->setDistributor($this);
  381. }
  382. return $this;
  383. }
  384. public function removeDistributorProduct(DistributorProducts $distributorProduct): self
  385. {
  386. if ($this->distributorProducts->removeElement($distributorProduct)) {
  387. // set the owning side to null (unless already changed)
  388. if ($distributorProduct->getDistributor() === $this) {
  389. $distributorProduct->setDistributor(null);
  390. }
  391. }
  392. return $this;
  393. }
  394. /**
  395. * @return Collection|DistributorUsers[]
  396. */
  397. public function getDistributorUsers(): Collection
  398. {
  399. return $this->distributorUsers;
  400. }
  401. public function addDistributorUser(DistributorUsers $distributorUser): self
  402. {
  403. if (!$this->distributorUsers->contains($distributorUser)) {
  404. $this->distributorUsers[] = $distributorUser;
  405. $distributorUser->setDistributor($this);
  406. }
  407. return $this;
  408. }
  409. public function removeDistributorUser(DistributorUsers $distributorUser): self
  410. {
  411. if ($this->distributorUsers->removeElement($distributorUser)) {
  412. // set the owning side to null (unless already changed)
  413. if ($distributorUser->getDistributor() === $this) {
  414. $distributorUser->setDistributor(null);
  415. }
  416. }
  417. return $this;
  418. }
  419. /**
  420. * @return Collection|EventLog[]
  421. */
  422. public function getEventLogs(): Collection
  423. {
  424. return $this->eventLogs;
  425. }
  426. public function addEventLog(EventLog $eventLog): self
  427. {
  428. if (!$this->eventLogs->contains($eventLog)) {
  429. $this->eventLogs[] = $eventLog;
  430. $eventLog->setDistributor($this);
  431. }
  432. return $this;
  433. }
  434. public function removeEventLog(EventLog $eventLog): self
  435. {
  436. if ($this->eventLogs->removeElement($eventLog)) {
  437. // set the owning side to null (unless already changed)
  438. if ($eventLog->getDistributor() === $this) {
  439. $eventLog->setDistributor(null);
  440. }
  441. }
  442. return $this;
  443. }
  444. /**
  445. * @return Collection|OrderItems[]
  446. */
  447. public function getOrderItems(): Collection
  448. {
  449. return $this->orderItems;
  450. }
  451. public function addOrderItem(OrderItems $orderItem): self
  452. {
  453. if (!$this->orderItems->contains($orderItem)) {
  454. $this->orderItems[] = $orderItem;
  455. $orderItem->setDistributor($this);
  456. }
  457. return $this;
  458. }
  459. public function removeOrderItem(OrderItems $orderItem): self
  460. {
  461. if ($this->orderItems->removeElement($orderItem)) {
  462. // set the owning side to null (unless already changed)
  463. if ($orderItem->getDistributor() === $this) {
  464. $orderItem->setDistributor(null);
  465. }
  466. }
  467. return $this;
  468. }
  469. /**
  470. * @return Collection<int, ListItems>
  471. */
  472. public function getListItems(): Collection
  473. {
  474. return $this->listItems;
  475. }
  476. public function addListItem(ListItems $listItem): self
  477. {
  478. if (!$this->listItems->contains($listItem)) {
  479. $this->listItems[] = $listItem;
  480. $listItem->setDistributor($this);
  481. }
  482. return $this;
  483. }
  484. public function removeListItem(ListItems $listItem): self
  485. {
  486. if ($this->listItems->removeElement($listItem)) {
  487. // set the owning side to null (unless already changed)
  488. if ($listItem->getDistributor() === $this) {
  489. $listItem->setDistributor(null);
  490. }
  491. }
  492. return $this;
  493. }
  494. /**
  495. * @return Collection<int, BasketItems>
  496. */
  497. public function getBasketItems(): Collection
  498. {
  499. return $this->basketItems;
  500. }
  501. public function addBasketItem(BasketItems $basketItem): self
  502. {
  503. if (!$this->basketItems->contains($basketItem)) {
  504. $this->basketItems[] = $basketItem;
  505. $basketItem->setDistributor($this);
  506. }
  507. return $this;
  508. }
  509. public function removeBasketItem(BasketItems $basketItem): self
  510. {
  511. if ($this->basketItems->removeElement($basketItem)) {
  512. // set the owning side to null (unless already changed)
  513. if ($basketItem->getDistributor() === $this) {
  514. $basketItem->setDistributor(null);
  515. }
  516. }
  517. return $this;
  518. }
  519. /**
  520. * @return Collection<int, ClinicProducts>
  521. */
  522. public function getClinicProducts(): Collection
  523. {
  524. return $this->clinicProducts;
  525. }
  526. public function addClinicProduct(ClinicProducts $clinicProduct): self
  527. {
  528. if (!$this->clinicProducts->contains($clinicProduct)) {
  529. $this->clinicProducts[] = $clinicProduct;
  530. $clinicProduct->setDistributor($this);
  531. }
  532. return $this;
  533. }
  534. public function removeClinicProduct(ClinicProducts $clinicProduct): self
  535. {
  536. if ($this->clinicProducts->removeElement($clinicProduct)) {
  537. // set the owning side to null (unless already changed)
  538. if ($clinicProduct->getDistributor() === $this) {
  539. $clinicProduct->setDistributor(null);
  540. }
  541. }
  542. return $this;
  543. }
  544. /**
  545. * @return Collection<int, AvailabilityTracker>
  546. */
  547. public function getAvailabilityTrackers(): Collection
  548. {
  549. return $this->availabilityTrackers;
  550. }
  551. public function addAvailabilityTracker(AvailabilityTracker $availabilityTracker): self
  552. {
  553. if (!$this->availabilityTrackers->contains($availabilityTracker)) {
  554. $this->availabilityTrackers[] = $availabilityTracker;
  555. $availabilityTracker->setDistributor($this);
  556. }
  557. return $this;
  558. }
  559. public function removeAvailabilityTracker(AvailabilityTracker $availabilityTracker): self
  560. {
  561. if ($this->availabilityTrackers->removeElement($availabilityTracker)) {
  562. // set the owning side to null (unless already changed)
  563. if ($availabilityTracker->getDistributor() === $this) {
  564. $availabilityTracker->setDistributor(null);
  565. }
  566. }
  567. return $this;
  568. }
  569. public function getPoNumberPrefix(): ?string
  570. {
  571. return $this->poNumberPrefix;
  572. }
  573. public function setPoNumberPrefix(?string $poNumberPrefix): self
  574. {
  575. $this->poNumberPrefix = $poNumberPrefix;
  576. return $this;
  577. }
  578. /**
  579. * @return Collection<int, ChatParticipants>
  580. */
  581. public function getChatParticipants(): Collection
  582. {
  583. return $this->chatParticipants;
  584. }
  585. public function addChatParticipant(ChatParticipants $chatParticipant): self
  586. {
  587. if (!$this->chatParticipants->contains($chatParticipant)) {
  588. $this->chatParticipants[] = $chatParticipant;
  589. $chatParticipant->setDistributor($this);
  590. }
  591. return $this;
  592. }
  593. public function removeChatParticipant(ChatParticipants $chatParticipant): self
  594. {
  595. if ($this->chatParticipants->removeElement($chatParticipant)) {
  596. // set the owning side to null (unless already changed)
  597. if ($chatParticipant->getDistributor() === $this) {
  598. $chatParticipant->setDistributor(null);
  599. }
  600. }
  601. return $this;
  602. }
  603. /**
  604. * @return Collection<int, ChatMessages>
  605. */
  606. public function getChatMessages(): Collection
  607. {
  608. return $this->chatMessages;
  609. }
  610. public function addChatMessage(ChatMessages $chatMessage): self
  611. {
  612. if (!$this->chatMessages->contains($chatMessage)) {
  613. $this->chatMessages[] = $chatMessage;
  614. $chatMessage->setDistributor($this);
  615. }
  616. return $this;
  617. }
  618. public function removeChatMessage(ChatMessages $chatMessage): self
  619. {
  620. if ($this->chatMessages->removeElement($chatMessage)) {
  621. // set the owning side to null (unless already changed)
  622. if ($chatMessage->getDistributor() === $this) {
  623. $chatMessage->setDistributor(null);
  624. }
  625. }
  626. return $this;
  627. }
  628. /**
  629. * @return Collection<int, Notifications>
  630. */
  631. public function getNotifications(): Collection
  632. {
  633. return $this->notifications;
  634. }
  635. public function addNotification(Notifications $notification): self
  636. {
  637. if (!$this->notifications->contains($notification)) {
  638. $this->notifications[] = $notification;
  639. $notification->setDistributors($this);
  640. }
  641. return $this;
  642. }
  643. public function removeNotification(Notifications $notification): self
  644. {
  645. if ($this->notifications->removeElement($notification)) {
  646. // set the owning side to null (unless already changed)
  647. if ($notification->getDistributors() === $this) {
  648. $notification->setDistributors(null);
  649. }
  650. }
  651. return $this;
  652. }
  653. /**
  654. * @return Collection<int, OrderStatus>
  655. */
  656. public function getOrderStatuses(): Collection
  657. {
  658. return $this->orderStatuses;
  659. }
  660. public function addOrderStatus(OrderStatus $orderStatus): self
  661. {
  662. if (!$this->orderStatuses->contains($orderStatus)) {
  663. $this->orderStatuses[] = $orderStatus;
  664. $orderStatus->setDistributor($this);
  665. }
  666. return $this;
  667. }
  668. public function removeOrderStatus(OrderStatus $orderStatus): self
  669. {
  670. if ($this->orderStatuses->removeElement($orderStatus)) {
  671. // set the owning side to null (unless already changed)
  672. if ($orderStatus->getDistributor() === $this) {
  673. $orderStatus->setDistributor(null);
  674. }
  675. }
  676. return $this;
  677. }
  678. public function getAddressStreet(): ?string
  679. {
  680. return $this->addressStreet;
  681. }
  682. public function setAddressStreet(?string $addressStreet): self
  683. {
  684. $this->addressStreet = $addressStreet;
  685. return $this;
  686. }
  687. public function getAddressCity(): ?string
  688. {
  689. return $this->addressCity;
  690. }
  691. public function setAddressCity(?string $addressCity): self
  692. {
  693. $this->addressCity = $addressCity;
  694. return $this;
  695. }
  696. public function getAddressPostalCode(): ?string
  697. {
  698. return $this->addressPostalCode;
  699. }
  700. public function setAddressPostalCode(?string $addressPostalCode): self
  701. {
  702. $this->addressPostalCode = $addressPostalCode;
  703. return $this;
  704. }
  705. public function getAddressState(): ?string
  706. {
  707. return $this->addressState;
  708. }
  709. public function setAddressState(?string $addressState): self
  710. {
  711. $this->addressState = $addressState;
  712. return $this;
  713. }
  714. public function getAddressCountry(): ?Countries
  715. {
  716. return $this->addressCountry;
  717. }
  718. public function setAddressCountry(?Countries $addressCountry): self
  719. {
  720. $this->addressCountry = $addressCountry;
  721. return $this;
  722. }
  723. public function getShippingPolicy(): ?string
  724. {
  725. return $this->shippingPolicy;
  726. }
  727. public function setShippingPolicy(?string $shippingPolicy): self
  728. {
  729. $this->shippingPolicy = $shippingPolicy;
  730. return $this;
  731. }
  732. public function getIsoCode(): ?string
  733. {
  734. return $this->isoCode;
  735. }
  736. public function setIsoCode(?string $isoCode): self
  737. {
  738. $this->isoCode = $isoCode;
  739. return $this;
  740. }
  741. public function getIntlCode(): ?string
  742. {
  743. return $this->intlCode;
  744. }
  745. public function setIntlCode(?string $intlCode): self
  746. {
  747. $this->intlCode = $intlCode;
  748. return $this;
  749. }
  750. /**
  751. * @return Collection<int, DistributorUserPermissions>
  752. */
  753. public function getDistributorUserPermissions(): Collection
  754. {
  755. return $this->distributorUserPermissions;
  756. }
  757. public function addDistributorUserPermission(DistributorUserPermissions $distributorUserPermission): self
  758. {
  759. if (!$this->distributorUserPermissions->contains($distributorUserPermission)) {
  760. $this->distributorUserPermissions[] = $distributorUserPermission;
  761. $distributorUserPermission->setDistributor($this);
  762. }
  763. return $this;
  764. }
  765. public function removeDistributorUserPermission(DistributorUserPermissions $distributorUserPermission): self
  766. {
  767. if ($this->distributorUserPermissions->removeElement($distributorUserPermission)) {
  768. // set the owning side to null (unless already changed)
  769. if ($distributorUserPermission->getDistributor() === $this) {
  770. $distributorUserPermission->setDistributor(null);
  771. }
  772. }
  773. return $this;
  774. }
  775. public function getApiDetails(): ?ApiDetails
  776. {
  777. return $this->api;
  778. }
  779. public function setApiDetails(ApiDetails $api): self
  780. {
  781. // set the owning side of the relation if necessary
  782. if ($api->getDistributor() !== $this) {
  783. $api->setDistributor($this);
  784. }
  785. $this->api = $api;
  786. return $this;
  787. }
  788. /**
  789. * @return Collection<int, DistributorClinics>
  790. */
  791. public function getDistributorClinics(): Collection
  792. {
  793. return $this->distributorClinics;
  794. }
  795. public function addDistributorClinic(DistributorClinics $distributorClinic): self
  796. {
  797. if (!$this->distributorClinics->contains($distributorClinic)) {
  798. $this->distributorClinics[] = $distributorClinic;
  799. $distributorClinic->setDistributor($this);
  800. }
  801. return $this;
  802. }
  803. public function removeDistributorClinic(DistributorClinics $distributorClinic): self
  804. {
  805. if ($this->distributorClinics->removeElement($distributorClinic)) {
  806. // set the owning side to null (unless already changed)
  807. if ($distributorClinic->getDistributor() === $this) {
  808. $distributorClinic->setDistributor(null);
  809. }
  810. }
  811. return $this;
  812. }
  813. public function getHashedEmail(): ?string
  814. {
  815. return $this->hashedEmail;
  816. }
  817. public function setHashedEmail(?string $hashedEmail): self
  818. {
  819. $this->hashedEmail = $hashedEmail;
  820. return $this;
  821. }
  822. public function getTracking(): ?Tracking
  823. {
  824. return $this->tracking;
  825. }
  826. public function setTracking(?Tracking $tracking): self
  827. {
  828. $this->tracking = $tracking;
  829. return $this;
  830. }
  831. public function getDomainName(): ?string
  832. {
  833. return $this->domainName;
  834. }
  835. public function setDomainName(?string $domainName): self
  836. {
  837. $this->domainName = $domainName;
  838. return $this;
  839. }
  840. public function getIsApproved(): ?int
  841. {
  842. return $this->isApproved;
  843. }
  844. public function setIsApproved(?int $isApproved): self
  845. {
  846. $this->isApproved = $isApproved;
  847. return $this;
  848. }
  849. public function getManagerFirstName(): ?string
  850. {
  851. return $this->managerFirstName;
  852. }
  853. public function setManagerFirstName(?string $managerFirstName): self
  854. {
  855. $this->managerFirstName = $managerFirstName;
  856. return $this;
  857. }
  858. public function getManagerLastName(): ?string
  859. {
  860. return $this->managerLastName;
  861. }
  862. public function setManagerLastName(?string $managerLastName): self
  863. {
  864. $this->managerLastName = $managerLastName;
  865. return $this;
  866. }
  867. public function getTradeLicense(): ?string
  868. {
  869. return $this->tradeLicense;
  870. }
  871. public function setTradeLicense(?string $tradeLicense): self
  872. {
  873. $this->tradeLicense = $tradeLicense;
  874. return $this;
  875. }
  876. public function getTradeLicenseNo(): ?string
  877. {
  878. return $this->tradeLicenseNo;
  879. }
  880. public function setTradeLicenseNo(?string $tradeLicenseNo): self
  881. {
  882. $this->tradeLicenseNo = $tradeLicenseNo;
  883. return $this;
  884. }
  885. public function getTradeLicenseExpDate(): ?\DateTimeInterface
  886. {
  887. return $this->tradeLicenseExpDate;
  888. }
  889. public function setTradeLicenseExpDate(?\DateTimeInterface $tradeLicenseExpDate): self
  890. {
  891. $this->tradeLicenseExpDate = $tradeLicenseExpDate;
  892. return $this;
  893. }
  894. public function getManagerIdNo(): ?string
  895. {
  896. return $this->managerIdNo;
  897. }
  898. public function setManagerIdNo(?string $managerIdNo): self
  899. {
  900. $this->managerIdNo = $managerIdNo;
  901. return $this;
  902. }
  903. public function getManagerIdExpDate(): ?\DateTimeInterface
  904. {
  905. return $this->managerIdExpDate;
  906. }
  907. public function setManagerIdExpDate(?\DateTimeInterface $managerIdExpDate): self
  908. {
  909. $this->managerIdExpDate = $managerIdExpDate;
  910. return $this;
  911. }
  912. /**
  913. * @return Collection<int, ControlledDrugFiles>
  914. */
  915. public function getControlledDrugFiles(): Collection
  916. {
  917. return $this->controlledDrugFiles;
  918. }
  919. public function addControlledDrugFile(ControlledDrugFiles $controlledDrugFile): self
  920. {
  921. if (!$this->controlledDrugFiles->contains($controlledDrugFile)) {
  922. $this->controlledDrugFiles[] = $controlledDrugFile;
  923. $controlledDrugFile->setDistributor($this);
  924. }
  925. return $this;
  926. }
  927. public function removeControlledDrugFile(ControlledDrugFiles $controlledDrugFile): self
  928. {
  929. if ($this->controlledDrugFiles->removeElement($controlledDrugFile)) {
  930. // set the owning side to null (unless already changed)
  931. if ($controlledDrugFile->getDistributor() === $this) {
  932. $controlledDrugFile->setDistributor(null);
  933. }
  934. }
  935. return $this;
  936. }
  937. /**
  938. * @return Collection<int, CustomPriceLists>
  939. */
  940. public function getCustomPriceLists(): Collection
  941. {
  942. return $this->customPriceLists;
  943. }
  944. public function addCustomPriceList(CustomPriceLists $customPriceList): static
  945. {
  946. if (!$this->customPriceLists->contains($customPriceList)) {
  947. $this->customPriceLists->add($customPriceList);
  948. $customPriceList->setDistributor($this);
  949. }
  950. return $this;
  951. }
  952. public function removeCustomPriceList(CustomPriceLists $customPriceList): static
  953. {
  954. if ($this->customPriceLists->removeElement($customPriceList)) {
  955. // set the owning side to null (unless already changed)
  956. if ($customPriceList->getDistributor() === $this) {
  957. $customPriceList->setDistributor(null);
  958. }
  959. }
  960. return $this;
  961. }
  962. public function getScraperAunthentication(): ?ScraperAunthentication
  963. {
  964. return $this->scraperAunthentication;
  965. }
  966. public function setScraperAunthentication(ScraperAunthentication $scraperAunthentication): static
  967. {
  968. // set the owning side of the relation if necessary
  969. if ($scraperAunthentication->getDistributor() !== $this) {
  970. $scraperAunthentication->setDistributor($this);
  971. }
  972. $this->scraperAunthentication = $scraperAunthentication;
  973. return $this;
  974. }
  975. /**
  976. * @return Collection<int, ScraperUrls>
  977. */
  978. public function getScraperUrls(): Collection
  979. {
  980. return $this->scraperUrls;
  981. }
  982. public function addScraperUrl(ScraperUrls $scraperUrl): static
  983. {
  984. if (!$this->scraperUrls->contains($scraperUrl)) {
  985. $this->scraperUrls->add($scraperUrl);
  986. $scraperUrl->setDistributor($this);
  987. }
  988. return $this;
  989. }
  990. public function removeScraperUrl(ScraperUrls $scraperUrl): static
  991. {
  992. if ($this->scraperUrls->removeElement($scraperUrl)) {
  993. // set the owning side to null (unless already changed)
  994. if ($scraperUrl->getDistributor() === $this) {
  995. $scraperUrl->setDistributor(null);
  996. }
  997. }
  998. return $this;
  999. }
  1000. /**
  1001. * @return Collection<int, ClinicDistributorContacts>
  1002. */
  1003. public function getClinicDistributorContacts(): Collection
  1004. {
  1005. return $this->clinicDistributorContacts;
  1006. }
  1007. public function addClinicDistributorContact(ClinicDistributorContacts $clinicDistributorContact): static
  1008. {
  1009. if (!$this->clinicDistributorContacts->contains($clinicDistributorContact)) {
  1010. $this->clinicDistributorContacts->add($clinicDistributorContact);
  1011. $clinicDistributorContact->setDistributor($this);
  1012. }
  1013. return $this;
  1014. }
  1015. public function removeClinicDistributorContact(ClinicDistributorContacts $clinicDistributorContact): static
  1016. {
  1017. if ($this->clinicDistributorContacts->removeElement($clinicDistributorContact)) {
  1018. // set the owning side to null (unless already changed)
  1019. if ($clinicDistributorContact->getDistributor() === $this) {
  1020. $clinicDistributorContact->setDistributor(null);
  1021. }
  1022. }
  1023. return $this;
  1024. }
  1025. /**
  1026. * @return Collection<int, ScraperLog>
  1027. */
  1028. public function getScraperLogs(): Collection
  1029. {
  1030. return $this->scraperLogs;
  1031. }
  1032. public function addScraperLog(ScraperLog $scraperLog): static
  1033. {
  1034. if (!$this->scraperLogs->contains($scraperLog)) {
  1035. $this->scraperLogs->add($scraperLog);
  1036. $scraperLog->setDistributor($this);
  1037. }
  1038. return $this;
  1039. }
  1040. public function removeScraperLog(ScraperLog $scraperLog): static
  1041. {
  1042. if ($this->scraperLogs->removeElement($scraperLog)) {
  1043. // set the owning side to null (unless already changed)
  1044. if ($scraperLog->getDistributor() === $this) {
  1045. $scraperLog->setDistributor(null);
  1046. }
  1047. }
  1048. return $this;
  1049. }
  1050. /**
  1051. * @return Collection<int, ScraperProducts>
  1052. */
  1053. public function getScraperProducts(): Collection
  1054. {
  1055. return $this->scraperProducts;
  1056. }
  1057. public function addScraperProduct(ScraperProducts $scraperProduct): static
  1058. {
  1059. if (!$this->scraperProducts->contains($scraperProduct)) {
  1060. $this->scraperProducts->add($scraperProduct);
  1061. $scraperProduct->setDistributor($this);
  1062. }
  1063. return $this;
  1064. }
  1065. public function removeScraperProduct(ScraperProducts $scraperProduct): static
  1066. {
  1067. if ($this->scraperProducts->removeElement($scraperProduct)) {
  1068. // set the owning side to null (unless already changed)
  1069. if ($scraperProduct->getDistributor() === $this) {
  1070. $scraperProduct->setDistributor(null);
  1071. }
  1072. }
  1073. return $this;
  1074. }
  1075. /**
  1076. * @return Collection<int, AiDistributorProducts>
  1077. */
  1078. public function getAiDistributorProducts(): Collection
  1079. {
  1080. return $this->aiDistributorProducts;
  1081. }
  1082. public function addAiDistributorProduct(AiDistributorProducts $aiDistributorProduct): static
  1083. {
  1084. if (!$this->aiDistributorProducts->contains($aiDistributorProduct)) {
  1085. $this->aiDistributorProducts->add($aiDistributorProduct);
  1086. $aiDistributorProduct->setDistributor($this);
  1087. }
  1088. return $this;
  1089. }
  1090. public function removeAiDistributorProduct(AiDistributorProducts $aiDistributorProduct): static
  1091. {
  1092. if ($this->aiDistributorProducts->removeElement($aiDistributorProduct)) {
  1093. // set the owning side to null (unless already changed)
  1094. if ($aiDistributorProduct->getDistributor() === $this) {
  1095. $aiDistributorProduct->setDistributor(null);
  1096. }
  1097. }
  1098. return $this;
  1099. }
  1100. /**
  1101. * @return Collection<int, AiListItems>
  1102. */
  1103. public function getAiListItems(): Collection
  1104. {
  1105. return $this->aiListItems;
  1106. }
  1107. public function addAiListItem(AiListItems $aiListItem): static
  1108. {
  1109. if (!$this->aiListItems->contains($aiListItem)) {
  1110. $this->aiListItems->add($aiListItem);
  1111. $aiListItem->setDistributor($this);
  1112. }
  1113. return $this;
  1114. }
  1115. public function removeAiListItem(AiListItems $aiListItem): static
  1116. {
  1117. if ($this->aiListItems->removeElement($aiListItem)) {
  1118. // set the owning side to null (unless already changed)
  1119. if ($aiListItem->getDistributor() === $this) {
  1120. $aiListItem->setDistributor(null);
  1121. }
  1122. }
  1123. return $this;
  1124. }
  1125. /**
  1126. * @return Collection<int, AiBasketItems>
  1127. */
  1128. public function getAiBasketItems(): Collection
  1129. {
  1130. return $this->aiBasketItems;
  1131. }
  1132. public function addAiBasketItem(AiBasketItems $aiBasketItem): static
  1133. {
  1134. if (!$this->aiBasketItems->contains($aiBasketItem)) {
  1135. $this->aiBasketItems->add($aiBasketItem);
  1136. $aiBasketItem->setDistributor($this);
  1137. }
  1138. return $this;
  1139. }
  1140. public function removeAiBasketItem(AiBasketItems $aiBasketItem): static
  1141. {
  1142. if ($this->aiBasketItems->removeElement($aiBasketItem)) {
  1143. // set the owning side to null (unless already changed)
  1144. if ($aiBasketItem->getDistributor() === $this) {
  1145. $aiBasketItem->setDistributor(null);
  1146. }
  1147. }
  1148. return $this;
  1149. }
  1150. /**
  1151. * @return Collection<int, AiOrderItems>
  1152. */
  1153. public function getAiOrderItems(): Collection
  1154. {
  1155. return $this->aiOrderItems;
  1156. }
  1157. public function addAiOrderItem(AiOrderItems $aiOrderItem): static
  1158. {
  1159. if (!$this->aiOrderItems->contains($aiOrderItem)) {
  1160. $this->aiOrderItems->add($aiOrderItem);
  1161. $aiOrderItem->setDistributor($this);
  1162. }
  1163. return $this;
  1164. }
  1165. public function removeAiOrderItem(AiOrderItems $aiOrderItem): static
  1166. {
  1167. if ($this->aiOrderItems->removeElement($aiOrderItem)) {
  1168. // set the owning side to null (unless already changed)
  1169. if ($aiOrderItem->getDistributor() === $this) {
  1170. $aiOrderItem->setDistributor(null);
  1171. }
  1172. }
  1173. return $this;
  1174. }
  1175. /**
  1176. * @return Collection<int, AiClinicProducts>
  1177. */
  1178. public function getAiClinicProducts(): Collection
  1179. {
  1180. return $this->aiClinicProducts;
  1181. }
  1182. public function addAiCinicProduct(AiClinicProducts $aiCinicProduct): static
  1183. {
  1184. if (!$this->aiClinicProducts->contains($aiCinicProduct)) {
  1185. $this->aiClinicProducts->add($aiCinicProduct);
  1186. $aiCinicProduct->setDistributor($this);
  1187. }
  1188. return $this;
  1189. }
  1190. public function removeAiCinicProduct(AiClinicProducts $aiCinicProduct): static
  1191. {
  1192. if ($this->aiClinicProducts->removeElement($aiCinicProduct)) {
  1193. // set the owning side to null (unless already changed)
  1194. if ($aiCinicProduct->getDistributor() === $this) {
  1195. $aiCinicProduct->setDistributor(null);
  1196. }
  1197. }
  1198. return $this;
  1199. }
  1200. /**
  1201. * @return Collection<int, AiCustomPriceLists>
  1202. */
  1203. public function getAiCustomPriceLists(): Collection
  1204. {
  1205. return $this->aiCustomPriceLists;
  1206. }
  1207. public function addAiCustomPriceList(AiCustomPriceLists $aiCustomPriceList): static
  1208. {
  1209. if (!$this->aiCustomPriceLists->contains($aiCustomPriceList)) {
  1210. $this->aiCustomPriceLists->add($aiCustomPriceList);
  1211. $aiCustomPriceList->setDistributor($this);
  1212. }
  1213. return $this;
  1214. }
  1215. public function removeAiCustomPriceList(AiCustomPriceLists $aiCustomPriceList): static
  1216. {
  1217. if ($this->aiCustomPriceLists->removeElement($aiCustomPriceList)) {
  1218. // set the owning side to null (unless already changed)
  1219. if ($aiCustomPriceList->getDistributor() === $this) {
  1220. $aiCustomPriceList->setDistributor(null);
  1221. }
  1222. }
  1223. return $this;
  1224. }
  1225. /**
  1226. * @return Collection<int, AiControlledDrugFiles>
  1227. */
  1228. public function getAiControlledDrugFiles(): Collection
  1229. {
  1230. return $this->aiControlledDrugFiles;
  1231. }
  1232. public function addAiControlledDrugFile(AiControlledDrugFiles $aiControlledDrugFile): static
  1233. {
  1234. if (!$this->aiControlledDrugFiles->contains($aiControlledDrugFile)) {
  1235. $this->aiControlledDrugFiles->add($aiControlledDrugFile);
  1236. $aiControlledDrugFile->setDistributor($this);
  1237. }
  1238. return $this;
  1239. }
  1240. public function removeAiControlledDrugFile(AiControlledDrugFiles $aiControlledDrugFile): static
  1241. {
  1242. if ($this->aiControlledDrugFiles->removeElement($aiControlledDrugFile)) {
  1243. // set the owning side to null (unless already changed)
  1244. if ($aiControlledDrugFile->getDistributor() === $this) {
  1245. $aiControlledDrugFile->setDistributor(null);
  1246. }
  1247. }
  1248. return $this;
  1249. }
  1250. /**
  1251. * @return Collection<int, AiOrderStatus>
  1252. */
  1253. public function getAiOrderStatuses(): Collection
  1254. {
  1255. return $this->aiOrderStatuses;
  1256. }
  1257. public function addAiOrderStatus(AiOrderStatus $aiOrderStatus): static
  1258. {
  1259. if (!$this->aiOrderStatuses->contains($aiOrderStatus)) {
  1260. $this->aiOrderStatuses->add($aiOrderStatus);
  1261. $aiOrderStatus->setDistributor($this);
  1262. }
  1263. return $this;
  1264. }
  1265. public function removeAiOrderStatus(AiOrderStatus $aiOrderStatus): static
  1266. {
  1267. if ($this->aiOrderStatuses->removeElement($aiOrderStatus)) {
  1268. // set the owning side to null (unless already changed)
  1269. if ($aiOrderStatus->getDistributor() === $this) {
  1270. $aiOrderStatus->setDistributor(null);
  1271. }
  1272. }
  1273. return $this;
  1274. }
  1275. }