<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass="App\Repository\RequestAccessRepository")
*/
class RequestAccess
{
/**
* @ORM\Id()
* @ORM\GeneratedValue()
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="string", length=255)
*/
private $customerAccountName;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\Country", inversedBy="requestAccesses")
* @ORM\JoinColumn(nullable=false)
*/
private $country;
/**
* @ORM\Column(type="string", length=255)
*/
private $addressLine1;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $addressLine2;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $zipCode;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $city;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\Country")
* @ORM\JoinColumn(nullable=false)
*/
private $phoneCountryCode;
/**
* @ORM\Column(type="string", length=255)
*/
private $phone;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $website;
/**
* @ORM\Column(type="string", length=255)
*/
private $contactFirstName;
/**
* @ORM\Column(type="string", length=255)
*/
private $contactLastName;
/**
* @ORM\Column(type="string", length=20, nullable=true)
*/
private $gender;
/**
/**
* @ORM\Column(type="string", length=255)
*/
private $email;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $IATANumber;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\Language")
* @ORM\JoinColumn(nullable=false)
*/
private $language;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\State")
*/
private $state;
// /**
// * @CaptchaAssert\ValidCaptcha(
// * message = "CAPTCHA validation failed, try again."
// * )
// */
// protected $captchaCode;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\CustomerAccount")
* @ORM\JoinColumn(nullable=true)
*/
private $customerAccount;
/**
* @ORM\Column(type="string", length=180, nullable=true)
*/
private $ownershipLink;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
private $isApproved;
// public function getCaptchaCode()
// {
// return $this->captchaCode;
// }
//
// public function setCaptchaCode($captchaCode)
// {
// $this->captchaCode = $captchaCode;
// }
public function getId(): ?int
{
return $this->id;
}
public function getCustomerAccountName(): ?string
{
return $this->customerAccountName;
}
public function setCustomerAccountName(string $customerAccountName): self
{
$this->customerAccountName = $customerAccountName;
return $this;
}
public function getCountry(): ?Country
{
return $this->country;
}
public function setCountry(?Country $country): self
{
$this->country = $country;
return $this;
}
public function getAddressLine1(): ?string
{
return $this->addressLine1;
}
public function setAddressLine1(string $addressLine1): self
{
$this->addressLine1 = $addressLine1;
return $this;
}
public function getAddressLine2(): ?string
{
return $this->addressLine2;
}
public function setAddressLine2(?string $addressLine2): self
{
$this->addressLine2 = $addressLine2;
return $this;
}
public function getZipCode(): ?string
{
return $this->zipCode;
}
public function setZipCode(?string $zipCode): self
{
$this->zipCode = $zipCode;
return $this;
}
public function getCity(): ?string
{
return $this->city;
}
public function setCity(?string $city): self
{
$this->city = $city;
return $this;
}
public function getPhoneCountryCode(): ?Country
{
return $this->phoneCountryCode;
}
public function setPhoneCountryCode(?Country $phoneCountryCode): self
{
$this->phoneCountryCode = $phoneCountryCode;
return $this;
}
public function getPhone(): ?string
{
return $this->phone;
}
public function setPhone(string $phone): self
{
$this->phone = $phone;
return $this;
}
public function getWebsite(): ?string
{
return $this->website;
}
public function setWebsite(?string $website): self
{
$this->website = $website;
return $this;
}
public function getContactFirstName(): ?string
{
return $this->contactFirstName;
}
public function setContactFirstName(string $contactFirstName): self
{
$this->contactFirstName = $contactFirstName;
return $this;
}
public function getContactLastName(): ?string
{
return $this->contactLastName;
}
public function setContactLastName($contactLastName):self
{
$this->contactLastName = $contactLastName;
return $this;
}
public function getGender():? string
{
return $this->gender;
}
public function setGender($gender):self
{
$this->gender = $gender;
return $this;
}
public function getEmail(): ?string
{
return $this->email;
}
public function setEmail(string $email): self
{
$this->email = $email;
return $this;
}
public function getIATANumber():?string
{
return $this->IATANumber;
}
public function setIATANumber($IATANumber): self
{
$this->IATANumber = $IATANumber;
return $this;
}
public function getLanguage(): ?Language
{
return $this->language;
}
public function setLanguage(?Language $language): self
{
$this->language = $language;
return $this;
}
public function getState(): ?State
{
return $this->state;
}
public function setState(?State $state): self
{
$this->state = $state;
return $this;
}
/**
* @return mixed
*/
public function getCustomerAccount()
{
return $this->customerAccount;
}
/**
* @param mixed $customerAccount
*/
public function setCustomerAccount($customerAccount): void
{
$this->customerAccount = $customerAccount;
}
/**
* @return mixed
*/
public function getOwnershipLink()
{
return $this->ownershipLink;
}
/**
* @param mixed $ownershipLink
*/
public function setOwnershipLink($ownershipLink): void
{
$this->ownershipLink = $ownershipLink;
}
/**
* @return mixed
*/
public function getIsApproved()
{
return $this->isApproved;
}
/**
* @param mixed $isApproved
*/
public function setIsApproved($isApproved): void
{
$this->isApproved = $isApproved;
}
/**
* @return string
*/
public function getStatus()
{
$status="Pending";
if($this->isApproved){
return "Approved";
}
if($this->isApproved===false){
return "Refused";
}
return $status;
}
}