<?php
/**
* Eshop class represents model of EasyCommerc Eshop entity
*
* $Project: Alliancemarkets2 $
* $Id$
*
* @package alliancemarkets2
* @author George Matyas <webexciter@yahoo.com>
* @version $Revision$
*/
namespace App\Entity;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass="App\EntityRepo\EshopRepo")
* @ORM\Table(name="eshop")
*/
class Eshop
{
/**
* @ORM\Column(type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $eshopId=0;
/**
* @ORM\Column(type="string", length=100)
*/
protected $eshopName;
/**
* @ORM\Column(type="integer")
*/
protected $userId=0;
/*
* Many Eshops have Many Users.
* @ORM\ManyToOne(targetEntity="User",cascade={"persist"})
* @ORM\JoinTable(name="eshop_user",
* joinColumns={@ORM\JoinColumn(name="user_id", referencedColumnName="user_id", unique=true)},
* inverseJoinColumns={@ORM\JoinColumn(name="eshop_id", referencedColumnName="eshop_id", unique=true)}
* )
*/
//protected $user;
/**
* @ORM\Column(type="string", length=100, nullable=true)
*/
protected $eshopType='eshop';
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $priority=1;
/**
* @ORM\Column(type="string", length=100, nullable=true)
*/
protected $status='new';
/**
* @ORM\Column(type="date", nullable=true)
*/
protected $dateInserted;
/**
* @ORM\Column(type="date", nullable=true)
*/
protected $dateLastControl;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
protected $logoUrl;
/**
* @ORM\Column(type="text", nullable=true)
*/
protected $notes;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $adminUserId=0;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
protected $eshopEmail;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
protected $orderEmail;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $eshopPrice;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $eshopCurrent;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
protected $eshopCss;
/*
* @ORM\OneToMany(targetEntity=Language::class, mappedBy="eshop")
*/
/**
* Many Eshops have Many Languages.
* @ORM\ManyToMany(targetEntity="Language",cascade={"persist"})
* @ORM\JoinTable(name="eshop_language",
* joinColumns={@ORM\JoinColumn(name="eshop_id", referencedColumnName="eshop_id")},
* inverseJoinColumns={@ORM\JoinColumn(name="lang_id", referencedColumnName="lang_id", unique=false)}
* )
*/
private $languages;
/*
* Many Eshops have Many Languages.
* @ORM\ManyToMany(targetEntity=Language::class,cascade={"persist"})
* @ORM\JoinTable(name="eshop_language",
* joinColumns={@ORM\JoinColumn(name="eshop_id", referencedColumnName="eshop_id")},
* inverseJoinColumns={@ORM\JoinColumn(name="lang_id", referencedColumnName="lang_id", unique=false)}
* )
*/
//protected $languages2;
/**
* Many Eshops have Many Currencies.
* @ORM\ManyToMany(targetEntity="Currency",cascade={"persist"})
* @ORM\JoinTable(name="eshop_currency",
* joinColumns={@ORM\JoinColumn(name="eshop_id", referencedColumnName="eshop_id")},
* inverseJoinColumns={@ORM\JoinColumn(name="currency_id", referencedColumnName="currency_id", unique=false)}
* )
*/
protected $currencies;
/**
* @ORM\Column(type="string", length=100, nullable=true)
*/
protected $productView='LIST';
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $imageThumbWidth=100;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $imageThumbHeight=100;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $wireFrameId = 1;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $productListWireFrameId = 1;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $productDetailWireFrameId = 1;
/**
* @ORM\Column(type="integer")
*/
protected $preferredLanguageId=0;
/**
* @ORM\Column(type="integer")
*/
protected $preferredCurrencyId=0;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $roundPrice=2;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $cutLongDescription=0;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $displayProductsFromSubfolders;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $countPerPage=12;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $isProductCatalogue=false;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $isPriceDisplay=true;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $displayNettoPrices=true;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $preferredVAT;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $categoryImageThumbWidth=100;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $isStock=false;
/**
* @ORM\Column(type="integer", nullable=true)
*/
protected $displayProductsFromSubfoldersLevel=1;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $isAsynchrounousShopping=false;
/**
* @ORM\Column(type="boolean", nullable=true)
*/
protected $isVirtualReality=false;
public function __construct()
{
$this->languages = new ArrayCollection();
$this->currencies = new ArrayCollection();
}
public function getEshopId(): ?int
{
return $this->eshopId;
}
public function getEshopName(): ?string
{
return $this->eshopName;
}
public function setEshopName(string $eshopName): self
{
$this->eshopName = $eshopName;
return $this;
}
public function getUserId(): ?int
{
return $this->userId;
}
public function setUserId(int $userId): self
{
$this->userId = $userId;
return $this;
}
public function getEshopType(): ?string
{
return $this->eshopType;
}
public function setEshopType(?string $eshopType): self
{
$this->eshopType = $eshopType;
return $this;
}
public function getPriority(): ?int
{
return $this->priority;
}
public function setPriority(?int $priority): self
{
$this->priority = $priority;
return $this;
}
public function getStatus(): ?string
{
return $this->status;
}
public function setStatus(?string $status): self
{
$this->status = $status;
return $this;
}
public function getDateInserted(): ?\DateTimeInterface
{
return $this->dateInserted;
}
public function setDateInserted(?\DateTimeInterface $dateInserted): self
{
$this->dateInserted = $dateInserted;
return $this;
}
public function getDateLastControl(): ?\DateTimeInterface
{
return $this->dateLastControl;
}
public function setDateLastControl(?\DateTimeInterface $dateLastControl): self
{
$this->dateLastControl = $dateLastControl;
return $this;
}
public function getLogoUrl(): ?string
{
return $this->logoUrl;
}
public function setLogoUrl(?string $logoUrl): self
{
$this->logoUrl = $logoUrl;
return $this;
}
public function getNotes(): ?string
{
return $this->notes;
}
public function setNotes(?string $notes): self
{
$this->notes = $notes;
return $this;
}
public function getAdminUserId(): ?int
{
return $this->adminUserId;
}
public function setAdminUserId(?int $adminUserId): self
{
$this->adminUserId = $adminUserId;
return $this;
}
public function getEshopEmail(): ?string
{
return $this->eshopEmail;
}
public function setEshopEmail(?string $eshopEmail): self
{
$this->eshopEmail = $eshopEmail;
return $this;
}
public function getOrderEmail(): ?string
{
return $this->orderEmail;
}
public function setOrderEmail(?string $orderEmail): self
{
$this->orderEmail = $orderEmail;
return $this;
}
public function getEshopPrice(): ?int
{
return $this->eshopPrice;
}
public function setEshopPrice(?int $eshopPrice): self
{
$this->eshopPrice = $eshopPrice;
return $this;
}
public function isEshopCurrent(): ?bool
{
return $this->eshopCurrent;
}
public function setEshopCurrent(?bool $eshopCurrent): self
{
$this->eshopCurrent = $eshopCurrent;
return $this;
}
public function getEshopCss(): ?string
{
return $this->eshopCss;
}
public function setEshopCss(?string $eshopCss): self
{
$this->eshopCss = $eshopCss;
return $this;
}
public function getProductView(): ?string
{
return $this->productView;
}
public function setProductView(?string $productView): self
{
$this->productView = $productView;
return $this;
}
public function getImageThumbWidth(): ?int
{
return $this->imageThumbWidth;
}
public function setImageThumbWidth(?int $imageThumbWidth): self
{
$this->imageThumbWidth = $imageThumbWidth;
return $this;
}
public function getImageThumbHeight(): ?int
{
return $this->imageThumbHeight;
}
public function setImageThumbHeight(?int $imageThumbHeight): self
{
$this->imageThumbHeight = $imageThumbHeight;
return $this;
}
public function getWireFrameId(): ?int
{
return $this->wireFrameId;
}
public function setWireFrameId(?int $wireFrameId): self
{
$this->wireFrameId = $wireFrameId;
return $this;
}
public function getProductListWireFrameId(): ?int
{
return $this->productListWireFrameId;
}
public function setProductListWireFrameId(?int $productListWireFrameId): self
{
$this->productListWireFrameId = $productListWireFrameId;
return $this;
}
public function getProductDetailWireFrameId(): ?int
{
return $this->productDetailWireFrameId;
}
public function setProductDetailWireFrameId(?int $productDetailWireFrameId): self
{
$this->productDetailWireFrameId = $productDetailWireFrameId;
return $this;
}
public function getPreferredLanguageId(): ?int
{
return $this->preferredLanguageId;
}
public function setPreferredLanguageId(int $preferredLanguageId): self
{
$this->preferredLanguageId = $preferredLanguageId;
return $this;
}
public function getPreferredCurrencyId(): ?int
{
return $this->preferredCurrencyId;
}
public function setPreferredCurrencyId(int $preferredCurrencyId): self
{
$this->preferredCurrencyId = $preferredCurrencyId;
return $this;
}
public function getRoundPrice(): ?int
{
return $this->roundPrice;
}
public function setRoundPrice(?int $roundPrice): self
{
$this->roundPrice = $roundPrice;
return $this;
}
public function getCutLongDescription(): ?int
{
return $this->cutLongDescription;
}
public function setCutLongDescription(?int $cutLongDescription): self
{
$this->cutLongDescription = $cutLongDescription;
return $this;
}
public function isDisplayProductsFromSubfolders(): ?bool
{
return $this->displayProductsFromSubfolders;
}
public function setDisplayProductsFromSubfolders(?bool $displayProductsFromSubfolders): self
{
$this->displayProductsFromSubfolders = $displayProductsFromSubfolders;
return $this;
}
public function getCountPerPage(): ?int
{
return $this->countPerPage;
}
public function setCountPerPage(?int $countPerPage): self
{
$this->countPerPage = $countPerPage;
return $this;
}
public function isIsProductCatalogue(): ?bool
{
return $this->isProductCatalogue;
}
public function setIsProductCatalogue(?bool $isProductCatalogue): self
{
$this->isProductCatalogue = $isProductCatalogue;
return $this;
}
public function isIsPriceDisplay(): ?bool
{
return $this->isPriceDisplay;
}
public function setIsPriceDisplay(?bool $isPriceDisplay): self
{
$this->isPriceDisplay = $isPriceDisplay;
return $this;
}
public function isDisplayNettoPrices(): ?bool
{
return $this->displayNettoPrices;
}
public function setDisplayNettoPrices(?bool $displayNettoPrices): self
{
$this->displayNettoPrices = $displayNettoPrices;
return $this;
}
public function getPreferredVAT(): ?int
{
return $this->preferredVAT;
}
public function setPreferredVAT(?int $preferredVAT): self
{
$this->preferredVAT = $preferredVAT;
return $this;
}
public function getCategoryImageThumbWidth(): ?int
{
return $this->categoryImageThumbWidth;
}
public function setCategoryImageThumbWidth(?int $categoryImageThumbWidth): self
{
$this->categoryImageThumbWidth = $categoryImageThumbWidth;
return $this;
}
public function isIsStock(): ?bool
{
return $this->isStock;
}
public function setIsStock(?bool $isStock): self
{
$this->isStock = $isStock;
return $this;
}
public function getDisplayProductsFromSubfoldersLevel(): ?int
{
return $this->displayProductsFromSubfoldersLevel;
}
public function setDisplayProductsFromSubfoldersLevel(?int $displayProductsFromSubfoldersLevel): self
{
$this->displayProductsFromSubfoldersLevel = $displayProductsFromSubfoldersLevel;
return $this;
}
public function isIsAsynchrounousShopping(): ?bool
{
return $this->isAsynchrounousShopping;
}
public function setIsAsynchrounousShopping(?bool $isAsynchrounousShopping): self
{
$this->isAsynchrounousShopping = $isAsynchrounousShopping;
return $this;
}
/**
* @return Collection<int, Language>
*/
public function getLanguages(): Collection
{
return $this->languages;
}
public function addLanguage(Language $language): self
{
if (!$this->languages->contains($language)) {
$this->languages->add($language);
//$language->setEshop($this);
}
return $this;
}
public function removeLanguage(Language $language): self
{
if ($this->languages->removeElement($language)) {
// set the owning side to null (unless already changed)
$this->languages->removeElement($language);
// if ($language->getEshop() === $this) {
// $language->setEshop(null);
// }
}
return $this;
}
/**
* @return Collection<int, Currency>
*/
public function getCurrencies(): Collection
{
return $this->currencies;
}
public function addCurrency(Currency $currency): self
{
if (!$this->currencies->contains($currency)) {
$this->currencies->add($currency);
}
return $this;
}
public function removeCurrency(Currency $currency): self
{
$this->currencies->removeElement($currency);
return $this;
}
public function isIsVirtualReality(): ?bool
{
return $this->isVirtualReality;
}
public function setIsVirtualReality(?bool $isVirtualReality): static
{
$this->isVirtualReality = $isVirtualReality;
return $this;
}
}