<?php
namespace EADPlataforma\Entity;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\Common\Collections\Collection;
use Symfony\Component\Validator\Constraints as Assert;
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
use EADPlataforma\Validator\Constraints as EADAssert;
use EADPlataforma\Services\FileService;
use EADPlataforma\Util\StringUtil;
use EADPlataforma\Util\DateTimeUtil;
use EADPlataforma\Enum\ProductPageEnum;
use \DateTime;
/**
* ProductPage
*
* @ORM\Table(name="product_page", indexes={
* @ORM\Index(name="fk_product_page_product_id", columns={"product_id"}),
* @ORM\Index(name="fk_product_page_library_id", columns={"library_id"}),
* @ORM\Index(name="fk_product_page_user_delete_id", columns={"user_delete_id"})
*})
*
* @ORM\Entity(repositoryClass="EADPlataforma\Repository\ProductPageRepository")
*/
class ProductPage
{
/**
* @var int
*
* @ORM\Column(name="id", type="integer", nullable=false)
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* @Assert\NotBlank(
* message = "Deleted not informed"
* )
*
* @Assert\Choice(
* choices = {
* ProductPageEnum::ITEM_NO_DELETED,
* ProductPageEnum::ITEM_ON_TRASH,
* ProductPageEnum::ITEM_DELETED
* },
* message = "Delete Option Invalid"
* )
*
* @var int
*
* @ORM\Column(name="deleted", type="integer", nullable=false, options={"default"="0"})
*/
private $deleted = ProductPageEnum::ITEM_NO_DELETED;
/**
* @Assert\NotBlank(
* message = "Status not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::DRAFT, ProductPageEnum::PUBLISHED },
* message = "Status Invalid"
* )
*
* @var int
*
* @ORM\Column(name="status", type="integer", nullable=false, options={"default"="0"})
*/
private $status = ProductPageEnum::DRAFT;
/**
* @Assert\NotBlank(
* message = "Default not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Default Invalid"
* )
*
* @var int
*
* @ORM\Column(name="`default`", type="integer", nullable=false, options={"default"="0"})
*/
private $default = ProductPageEnum::NO;
/**
* @Assert\NotBlank(
* message = "Type not informed"
* )
*
* @Assert\Choice(
* choices = {
* ProductPageEnum::TYPE_DEFAULT,
* ProductPageEnum::TYPE_EXTERNAL,
* ProductPageEnum::TYPE_LAND_PAGE
* },
* message = "Type Invalid"
* )
*
* @var int
*
* @ORM\Column(name="type", type="integer", nullable=false)
*/
private $type;
/**
* @Assert\NotBlank(
* message = "Name not informed"
* )
*
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string
*
* @ORM\Column(name="name", type="string", length=255, nullable=false)
*/
private $name;
/**
* @Assert\NotBlank(
* message = "Title not informed"
* )
*
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string
*
* @ORM\Column(name="title", type="string", length=255, nullable=false)
*/
private $title;
/**
* @var string|null
*
* @ORM\Column(name="description", type="text", length=0, nullable=true)
*/
private $description;
/**
* @var string|null
*
* @ORM\Column(name="about", type="text", length=0, nullable=true)
*/
private $about;
/**
* @var string|null
*
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @ORM\Column(name="overview", type="string", length=255, nullable=true)
*/
private $overview;
/**
* @var string|null
*
* @ORM\Column(name="target", type="text", nullable=true)
*/
private $target;
/**
* @var string|null
*
* @ORM\Column(name="about_certificate", type="text", nullable=true)
*/
private $aboutCertificate;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="video", type="string", length=255, nullable=true)
*/
private $video;
/**
* @Assert\NotBlank(
* message = "Autoplay not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Autoplay Invalid"
* )
*
* @var int
*
* @ORM\Column(name="autoplay", type="integer", nullable=false, options={"default"="0"})
*/
private $autoplay = ProductPageEnum::NO;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="photo", type="string", length=255, nullable=true)
*/
private $photo;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="photo_stand", type="string", length=255, nullable=true)
*/
private $photoStand;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="photo_expand", type="string", length=255, nullable=true)
*/
private $photoExpand;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="cover", type="string", length=255, nullable=true)
*/
private $cover;
/**
* @var string|null
*
* @ORM\Column(name="page_color_text", type="string", length=20, nullable=true)
*/
private $pageColorText;
/**
* @var string|null
*
* @ORM\Column(name="background_color", type="string", length=20, nullable=true)
*/
private $backgroundColor;
/**
* @var int
*
* @Assert\NotBlank(
* message = "External Page not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "External Page Invalid"
* )
*
* @var int
*
* @ORM\Column(name="external_page", type="integer", nullable=false, options={"default"="0"})
*/
private $externalPage = ProductPageEnum::NO;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="external_page_link", type="string", length=255, nullable=true)
*/
private $externalPageLink;
/**
* @var int
*
* @Assert\NotBlank(
* message = "External Conclusion not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "External Conclusion Invalid"
* )
*
* @var int
*
* @ORM\Column(name="allow_external_conclusion", type="integer", nullable=false, options={"default"="0"})
*/
private $allowExternalConclusion = ProductPageEnum::NO;
/**
* @Assert\Length(
* min = 0,
* max = 250
* )
*
* @var string|null
*
* @ORM\Column(name="external_conclusion_link", type="string", length=255, nullable=true)
*/
private $externalConclusionLink;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Module Coupon not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Module Coupon Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_module_coupon", type="integer", nullable=false, options={"default"="1"})
*/
private $showModuleCoupon = ProductPageEnum::YES;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Module Testimonials not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Module Testimonials Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_module_testimonials", type="integer", nullable=false, options={"default"="1"})
*/
private $showModuleTestimonials = ProductPageEnum::YES;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Module Data Billing not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Module Data Billing Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_module_data_billing", type="integer", nullable=false, options={"default"="1"})
*/
private $showModuleDataBilling = ProductPageEnum::YES;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Module Option Foreign not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Module Option Foreign Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_module_option_foreign", type="integer", nullable=false, options={"default"="1"})
*/
private $showModuleOptionForeign = ProductPageEnum::YES;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Module Header not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Header Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_module_header", type="integer", nullable=false, options={"default"="1"})
*/
private $showModuleHeader = ProductPageEnum::YES;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Module Contracts not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Contracts Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_module_contracts", type="integer", nullable=false, options={"default"="1"})
*/
private $showModuleContracts = ProductPageEnum::YES;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Shortage Control Time not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Shortage Control Time Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_shortage_control_time", type="integer", nullable=false, options={"default"="0"})
*/
private $showShortageControlTime = ProductPageEnum::NO;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Shortage Control Visualization not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Shortage Control Visualization Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_shortage_control_visualization", type="integer", nullable=false, options={"default"="0"})
*/
private $showShortageControlVisualization = ProductPageEnum::NO;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Shortage Control Buyers not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Shortage Control Buyers Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_shortage_control_buyers", type="integer", nullable=false, options={"default"="0"})
*/
private $showShortageControlBuyers = ProductPageEnum::NO;
/**
* @var int
*
* @Assert\NotBlank(
* message = "Show Shortage Control Vacancies not informed"
* )
*
* @Assert\Choice(
* choices = { ProductPageEnum::NO, ProductPageEnum::YES },
* message = "Show Shortage Control Vacancies Invalid"
* )
*
* @var int
*
* @ORM\Column(name="show_shortage_control_vacancies", type="integer", nullable=false, options={"default"="0"})
*/
private $showShortageControlVacancies = ProductPageEnum::NO;
/**
* @var string
*
* @ORM\Column(name="shortage_time_number", type="string", length=10, nullable=true)
*/
private $shortageTimeNumber;
/**
* @var int
*
* @ORM\Column(name="shortage_visualization_number", type="integer", nullable=true)
*/
private $shortageVisualizationNumber;
/**
* @var int
*
* @ORM\Column(name="shortage_buyers_number", type="integer", nullable=true)
*/
private $shortageBuyersNumber;
/**
* @var int
*
* @ORM\Column(name="shortage_vacancies_number", type="integer", nullable=true)
*/
private $shortageVacanciesNumber;
/**
* @Assert\Valid
*
* @var \Library
*
* @ORM\ManyToOne(targetEntity="Library")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="library_id", referencedColumnName="id", nullable=true)
* })
*/
private $library;
/**
* @Assert\NotBlank(
* message = "Product not informed"
* )
*
* @Assert\Valid
*
* @var \Product
*
* @ORM\ManyToOne(targetEntity="Product")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="product_id", referencedColumnName="id", nullable=false)
* })
*/
private $product;
/**
* @Assert\Valid
*
* @var \EADPlataforma\Entity\User
*
* @ORM\ManyToOne(targetEntity="User")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="user_delete_id", referencedColumnName="id", nullable=true)
* })
*/
private $userDelete;
/**
* @Assert\Choice(
* choices = {
* ProductPageEnum::INDIVIDUAL,
* ProductPageEnum::CASCADE
* },
* message = "Type Delete Invalid"
* )
*
* @var int
*
* @ORM\Column(name="type_delete", type="integer", nullable=true)
*/
private $typeDelete;
/**
* @EADAssert\DateTimeEAD(
* message = "Date Delete Invalid"
* )
*
* @var \DateTime|null
*
* @ORM\Column(name="date_delete", type="datetime", nullable=true)
*/
private $dateDelete;
/**
* Constructor
*/
public function __construct()
{
}
public function getId(): ?int
{
return $this->id;
}
public function getStatus(): ?int
{
return $this->status;
}
public function setStatus(int $status): self
{
$this->status = $status;
return $this;
}
public function getDefault(): ?int
{
return $this->default;
}
public function setDefault(int $default): self
{
$this->default = $default;
return $this;
}
public function getType(): ?int
{
return $this->type;
}
public function setType(int $type): self
{
$this->type = $type;
return $this;
}
public function getName(): ?string
{
$this->name = StringUtil::removeScriptsStatic($this->name);
return StringUtil::encodeStringStatic($this->name);
}
public function setName(string $name): self
{
$name = StringUtil::removeScriptsStatic($name);
$this->name = $name;
return $this;
}
public function getTitle(): ?string
{
$this->title = StringUtil::removeScriptsStatic($this->title);
return StringUtil::encodeStringStatic($this->title);
}
public function setTitle(?string $title): self
{
$title = StringUtil::removeScriptsStatic($title);
$this->title = $title;
return $this;
}
public function getDescription(): ?string
{
$this->description = StringUtil::removeScriptsStatic($this->description);
return StringUtil::encodeStringStatic($this->description);
}
public function setDescription(?string $description): self
{
$description = StringUtil::removeScriptsStatic($description);
$this->description = $description;
return $this;
}
public function getAbout(): ?string
{
$this->about = StringUtil::removeScriptsStatic($this->about);
return html_entity_decode(StringUtil::encodeStringStatic($this->about));
}
public function setAbout(?string $about): self
{
$about = StringUtil::removeScriptsStatic($about);
$this->about = $about;
return $this;
}
public function getOverview(): ?string
{
$this->overview = StringUtil::removeScriptsStatic($this->overview);
return StringUtil::encodeStringStatic($this->overview);
}
public function setOverview(?string $overview): self
{
$overview = StringUtil::removeScriptsStatic($overview);
$this->overview = $overview;
return $this;
}
public function getTarget(): ?string
{
$this->target = StringUtil::removeScriptsStatic($this->target);
return html_entity_decode(StringUtil::encodeStringStatic($this->target));
}
public function setTarget(?string $target): self
{
$target = StringUtil::removeScriptsStatic($target);
$this->target = $target;
return $this;
}
public function getAboutCertificate(): ?string
{
$this->aboutCertificate = StringUtil::removeScriptsStatic($this->aboutCertificate);
return html_entity_decode(StringUtil::encodeStringStatic($this->aboutCertificate));
}
public function setAboutCertificate(?string $aboutCertificate): self
{
$aboutCertificate = StringUtil::removeScriptsStatic($aboutCertificate);
$this->aboutCertificate = $aboutCertificate;
return $this;
}
public function getVideo(): ?string
{
$this->video = StringUtil::removeScriptsStatic($this->video);
if(!empty($this->video)){
$url = str_replace('http:', '', $this->video);
$url = str_replace('https:', '', $url);
return "https:{$url}";
}
return $this->video;
}
public function setVideo(?string $video): self
{
$video = StringUtil::removeScriptsStatic($video);
$this->video = $video;
return $this;
}
public function getAutoplay(): ?int
{
return (int)$this->autoplay;
}
public function setAutoplay(?int $autoplay): self
{
$this->autoplay = (int)$autoplay;
return $this;
}
public function getPhoto(): ?string
{
return $this->photo;
}
public function setPhoto(?string $photo): self
{
$this->photo = $photo;
return $this;
}
public function getPhotoStand(): ?string
{
return $this->photoStand;
}
public function setPhotoStand(?string $photoStand): self
{
$this->photoStand = $photoStand;
return $this;
}
public function getPhotoExpand(): ?string
{
return $this->photoExpand;
}
public function setPhotoExpand(?string $photoExpand): self
{
$this->photoExpand = $photoExpand;
return $this;
}
public function getCover(): ?string
{
return $this->cover;
}
public function setCover(?string $cover): self
{
$this->cover = $cover;
return $this;
}
public function getPageColorText(): ?string
{
return $this->pageColorText;
}
public function setPageColorText(?string $pageColorText): self
{
$this->pageColorText = $pageColorText;
return $this;
}
public function getBackgroundColor(): ?string
{
return $this->backgroundColor;
}
public function setBackgroundColor(?string $backgroundColor): self
{
$this->backgroundColor = $backgroundColor;
return $this;
}
public function getExternalPage(): ?int
{
return $this->externalPage;
}
public function setExternalPage(?int $externalPage): self
{
$this->externalPage = $externalPage;
return $this;
}
public function getExternalPageLink(): ?string
{
return $this->externalPageLink;
}
public function setExternalPageLink(?string $externalPageLink): self
{
$this->externalPageLink = $externalPageLink;
return $this;
}
public function getAllowExternalConclusion(): ?int
{
return $this->allowExternalConclusion;
}
public function setAllowExternalConclusion(?int $allowExternalConclusion): self
{
$this->allowExternalConclusion = $allowExternalConclusion;
return $this;
}
public function getExternalConclusionLink(): ?string
{
return $this->externalConclusionLink;
}
public function setExternalConclusionLink(?string $externalConclusionLink): self
{
$this->externalConclusionLink = $externalConclusionLink;
return $this;
}
public function getShowModuleCoupon(): ?int
{
return $this->showModuleCoupon;
}
public function setShowModuleCoupon(?int $showModuleCoupon): self
{
$this->showModuleCoupon = $showModuleCoupon;
return $this;
}
public function getShowModuleTestimonials(): ?int
{
return $this->showModuleTestimonials;
}
public function setShowModuleTestimonials(?int $showModuleTestimonials): self
{
$this->showModuleTestimonials = $showModuleTestimonials;
return $this;
}
public function getShowModuleDataBilling(): ?int
{
return $this->showModuleDataBilling;
}
public function setShowModuleDataBilling(?int $showModuleDataBilling): self
{
$this->showModuleDataBilling = $showModuleDataBilling;
return $this;
}
public function getShowModuleOptionForeign(): ?int
{
return $this->showModuleOptionForeign;
}
public function setShowModuleOptionForeign(?int $showModuleOptionForeign): self
{
$this->showModuleOptionForeign = $showModuleOptionForeign;
return $this;
}
public function getShowModuleHeader(): ?int
{
return $this->showModuleHeader;
}
public function setShowModuleHeader(?int $showModuleHeader): self
{
$this->showModuleHeader = $showModuleHeader;
return $this;
}
public function getShowModuleContracts(): ?int
{
return $this->showModuleContracts;
}
public function setShowModuleContracts(?int $showModuleContracts): self
{
$this->showModuleContracts = $showModuleContracts;
return $this;
}
public function getShowShortageControlTime(): ?int
{
return $this->showShortageControlTime;
}
public function setShowShortageControlTime(?int $showShortageControlTime): self
{
$this->showShortageControlTime = $showShortageControlTime;
return $this;
}
public function getShowShortageControlVisualization(): ?int
{
return $this->showShortageControlVisualization;
}
public function setShowShortageControlVisualization(?int $showShortageControlVisualization): self
{
$this->showShortageControlVisualization = $showShortageControlVisualization;
return $this;
}
public function getShowShortageControlBuyers(): ?int
{
return $this->showShortageControlBuyers;
}
public function setShowShortageControlBuyers(?int $showShortageControlBuyers): self
{
$this->showShortageControlBuyers = $showShortageControlBuyers;
return $this;
}
public function getShowShortageControlVacancies(): ?int
{
return $this->showShortageControlVacancies;
}
public function setShowShortageControlVacancies(?int $showShortageControlVacancies): self
{
$this->showShortageControlVacancies = $showShortageControlVacancies;
return $this;
}
public function getShortageTimeNumber(?bool $seconds = false): ?string
{
if($seconds && !empty($this->shortageTimeNumber)){
return DateTimeUtil::timeToSecStatic($this->shortageTimeNumber);
}
return $this->shortageTimeNumber;
}
public function setShortageTimeNumber(?string $shortageTimeNumber): self
{
$this->shortageTimeNumber = $shortageTimeNumber;
return $this;
}
public function getShortageVisualizationNumber(): ?int
{
return $this->shortageVisualizationNumber;
}
public function setShortageVisualizationNumber(?int $shortageVisualizationNumber): self
{
$this->shortageVisualizationNumber = $shortageVisualizationNumber;
return $this;
}
public function getShortageBuyersNumber(): ?int
{
return $this->shortageBuyersNumber;
}
public function setShortageBuyersNumber(?int $shortageBuyersNumber): self
{
$this->shortageBuyersNumber = $shortageBuyersNumber;
return $this;
}
public function getShortageVacanciesNumber(): ?int
{
return $this->shortageVacanciesNumber;
}
public function setShortageVacanciesNumber(?int $shortageVacanciesNumber): self
{
$this->shortageVacanciesNumber = $shortageVacanciesNumber;
return $this;
}
public function getLibrary(): ?Library
{
return $this->library;
}
public function setLibrary(?Library $library): self
{
$this->library = $library;
return $this;
}
public function getProduct(): ?Product
{
return $this->product;
}
public function setProduct(?Product $product): self
{
$this->product = $product;
return $this;
}
public function getUserDelete(): ?User
{
return $this->userDelete;
}
public function setUserDelete(?User $userDelete): self
{
$this->userDelete = $userDelete;
return $this;
}
public function getDateDelete($dateFormat = 'Y-m-d H:i:s')
{
if($this->dateDelete){
return $this->dateDelete->format($dateFormat);
}
return $this->dateDelete;
}
public function setDateDelete($dateDelete): self
{
if(!empty($dateDelete)){
$dateDelete = DateTime::createFromFormat('Y-m-d H:i:s', $dateDelete);
}
$this->dateDelete = $dateDelete;
return $this;
}
public function isDisable(): bool
{
if($this->deleted != ProductPageEnum::ITEM_NO_DELETED){
return true;
}
if($this->status == ProductPageEnum::DRAFT){
return true;
}
return false;
}
public function isLive(): bool
{
return ($this->deleted == ProductPageEnum::ITEM_NO_DELETED);
}
public function individual(): self
{
$this->typeDelete = ProductPageEnum::INDIVIDUAL;
return $this;
}
public function cascade(): self
{
$this->typeDelete = ProductPageEnum::CASCADE;
return $this;
}
public function isOnTrash(): bool
{
return ($this->deleted == ProductPageEnum::ITEM_ON_TRASH);
}
public function isDeleted(): bool
{
return ($this->deleted == ProductPageEnum::ITEM_DELETED);
}
public function restore(): self
{
$this->deleted = ProductPageEnum::ITEM_NO_DELETED;
return $this;
}
public function trash(): self
{
$this->deleted = ProductPageEnum::ITEM_ON_TRASH;
return $this;
}
public function delete(): self
{
$this->deleted = ProductPageEnum::ITEM_DELETED;
return $this;
}
public function toReturn(){
$data = [
"id" => $this->id,
"deleted" => $this->deleted,
"status" => $this->status,
"default" => $this->default,
"type" => $this->type,
"name" => $this->getName(),
"title" => $this->getTitle(),
"description" => $this->getDescription(),
"about" => $this->getAbout(),
"overview" => $this->getOverview(),
"target" => $this->getTarget(),
"aboutCertificate" => $this->getAboutCertificate(),
"video" => $this->getVideo(),
"autoplay" => $this->autoplay,
"photo" => FileService::getFilePathComplete(
$this->photo,
ProductPageEnum::PATH_PRODUCT_PHOTO,
true,
true
),
"photoStand" => FileService::getFilePathComplete(
$this->photoStand,
ProductPageEnum::PATH_PRODUCT_PHOTO,
true,
true
),
"photoExpand" => FileService::getFilePathComplete(
$this->photoExpand,
ProductPageEnum::PATH_PRODUCT_PHOTO,
true,
true
),
"cover" => FileService::getFilePathComplete(
$this->cover,
ProductPageEnum::PATH_PRODUCT_COVER,
true,
true
),
"pageColorText" => $this->pageColorText,
"backgroundColor" => $this->backgroundColor,
"externalPage" => $this->externalPage,
"externalPageLink" => $this->externalPageLink,
"showModuleCoupon" => $this->showModuleCoupon,
"showModuleTestimonials" => $this->showModuleTestimonials,
"showModuleDataBilling" => $this->showModuleDataBilling,
"showModuleOptionForeign" => $this->showModuleOptionForeign,
"showShortageControlTime" => $this->showShortageControlTime,
"showShortageControlVisualization" => $this->showShortageControlVisualization,
"showShortageControlBuyers" => $this->showShortageControlBuyers,
"showShortageControlVacancies" => $this->showShortageControlVacancies,
"allowExternalConclusion" => $this->allowExternalConclusion,
"externalConclusionLink" => $this->externalConclusionLink,
"showModuleHeader" => $this->showModuleHeader,
"showModuleContracts" => $this->showModuleContracts,
"shortageTimeNumber" => $this->shortageTimeNumber,
"shortageVisualizationNumber" => $this->shortageVisualizationNumber,
"shortageBuyersNumber" => $this->shortageBuyersNumber,
"shortageVacanciesNumber" => $this->shortageVacanciesNumber,
"library" => ( $this->library ? $this->library->getId() : null ),
"product" => ( $this->product ? $this->product->getId() : null ),
"userDelete" => ( $this->userDelete ? $this->userDelete->getId() : null ),
"typeDelete" => $this->typeDelete,
"dateDelete" => $this->getDateDelete()
];
return $data;
}
}