*/ #[ORM\OneToMany(targetEntity: Accounting::class, mappedBy: 'company', orphanRemoval: true)] private Collection $accountings; /** * @var Collection */ #[ORM\ManyToMany(targetEntity: User::class, mappedBy: 'companys')] private Collection $users; /** * @var Collection */ #[ORM\OneToMany(targetEntity: Year::class, mappedBy: 'company', orphanRemoval: true)] private Collection $years; /** * @var Collection */ #[ORM\OneToMany(targetEntity: Operation::class, mappedBy: 'company', orphanRemoval: true)] private Collection $operations; public function __construct() { $this->accountings = new ArrayCollection(); $this->users = new ArrayCollection(); $this->years = new ArrayCollection(); $this->operations = new ArrayCollection(); } public function getId(): ?int { return $this->id; } public function getTitle(): ?string { return $this->title; } public function setTitle(string $title): static { $this->title = $title; return $this; } public function getLogo(): ?string { return $this->logo ? $this->logo : 'medias/logo/logo.png'; } public function setLogo(?string $logo): static { $this->logo = $logo; return $this; } public function getEmail(): ?string { return $this->email; } public function setEmail(?string $email): static { $this->email = $email; return $this; } public function getAdress(): ?string { return $this->adress; } public function setAdress(?string $adress): static { $this->adress = $adress; return $this; } public function getBankname(): ?string { return $this->bankname; } public function setBankname(?string $bankname): static { $this->bankname = $bankname; return $this; } public function getBankcode(): ?string { return $this->bankcode; } public function setBankcode(?string $bankcode): static { $this->bankcode = $bankcode; return $this; } public function getBankguichet(): ?string { return $this->bankguichet; } public function setBankguichet(?string $bankguichet): static { $this->bankguichet = $bankguichet; return $this; } public function getBanknum(): ?string { return $this->banknum; } public function setBanknum(?string $banknum): static { $this->banknum = $banknum; return $this; } public function getBankkey(): ?string { return $this->bankkey; } public function setBankkey(?string $bankkey): static { $this->bankkey = $bankkey; return $this; } public function getBanklocality(): ?string { return $this->banklocality; } public function setBanklocality(?string $banklocality): static { $this->banklocality = $banklocality; return $this; } public function getBankiban(): ?string { return $this->bankiban; } public function setBankiban(?string $bankiban): static { $this->bankiban = $bankiban; return $this; } public function getBankbic(): ?string { return $this->bankbic; } public function setBankbic(?string $bankbic): static { $this->bankbic = $bankbic; return $this; } /** * @return Collection */ public function getAccountings(): Collection { return $this->accountings; } public function addAccounting(Accounting $accounting): static { if (!$this->accountings->contains($accounting)) { $this->accountings->add($accounting); $accounting->setCompany($this); } return $this; } public function removeAccounting(Accounting $accounting): static { if ($this->accountings->removeElement($accounting)) { // set the owning side to null (unless already changed) if ($accounting->getCompany() === $this) { $accounting->setCompany(null); } } return $this; } /** * @return Collection */ public function getUsers(): Collection { return $this->users; } public function addUser(User $user): static { if (!$this->users->contains($user)) { $this->users->add($user); $user->addCompany($this); } return $this; } public function removeUser(User $user): static { if ($this->users->removeElement($user)) { $user->removeCompany($this); } return $this; } /** * @return Collection */ public function getYears(): Collection { return $this->years; } public function addYear(Year $year): static { if (!$this->years->contains($year)) { $this->years->add($year); $year->setCompany($this); } return $this; } public function removeYear(Year $year): static { if ($this->years->removeElement($year)) { // set the owning side to null (unless already changed) if ($year->getCompany() === $this) { $year->setCompany(null); } } return $this; } /** * @return Collection */ public function getOperations(): Collection { return $this->operations; } public function addOperation(Operation $operation): static { if (!$this->operations->contains($operation)) { $this->operations->add($operation); $operation->setCompany($this); } return $this; } public function removeOperation(Operation $operation): static { if ($this->operations->removeElement($operation)) { // set the owning side to null (unless already changed) if ($operation->getCompany() === $this) { $operation->setCompany(null); } } return $this; } }