src/Flexy/ShopBundle/Entity/Shipping/Vehicle/BodyCondition.php line 12
<?php
namespace App\Flexy\ShopBundle\Entity\Shipping\Vehicle;
use ApiPlatform\Core\Annotation\ApiResource;
use App\Repository\Flexy\ShopBundle\Entity\Shipping\Vehicle\BodyConditionRepository;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: BodyConditionRepository::class)]
#[ApiResource()]
class BodyCondition
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\Column( nullable: true)]
private ?string $frontImage = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $backImage = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $leftImage = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $rightImage = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $frontObservation = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $backObservation = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $leftObservation = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $rightObservation = null;
#[ORM\Column(type: Types::DATETIME_MUTABLE, nullable: true)]
private ?\DateTimeInterface $createdAt = null;
#[ORM\ManyToOne(inversedBy: 'bodyConditions',cascade:["persist"])]
private ?ShippingVehicle $shippingVehicle = null;
#[ORM\Column(type: Types::TEXT, nullable: true)]
private ?string $frontImageBase64 = null;
public function __construct()
{
$this->createdAt=new \DateTime();
}
public function __toString()
{
return (string)"Etat de ".$this->getShippingVehicle()." le ".$this->createdAt->format("d/m/Y H:i");
}
public function getId(): ?int
{
return $this->id;
}
public function getFrontImage(): ?string
{
return $this->frontImage;
}
public function setFrontImage(?string $frontImage): self
{
$this->frontImage = $frontImage;
return $this;
}
public function getBackImage(): ?string
{
return $this->backImage;
}
public function setBackImage(?string $backImage): self
{
$this->backImage = $backImage;
return $this;
}
public function getLeftImage(): ?string
{
return $this->leftImage;
}
public function setLeftImage(?string $leftImage): self
{
$this->leftImage = $leftImage;
return $this;
}
public function getRightImage(): ?string
{
return $this->rightImage;
}
public function setRightImage(?string $rightImage): self
{
$this->rightImage = $rightImage;
return $this;
}
/**
* Get the value of frontObservation
*/
public function getFrontObservation()
{
return $this->frontObservation;
}
/**
* Set the value of frontObservation
*
* @return self
*/
public function setFrontObservation($frontObservation)
{
$this->frontObservation = $frontObservation;
return $this;
}
/**
* Get the value of backObservation
*/
public function getBackObservation()
{
return $this->backObservation;
}
/**
* Set the value of backObservation
*
* @return self
*/
public function setBackObservation($backObservation)
{
$this->backObservation = $backObservation;
return $this;
}
/**
* Get the value of leftObservation
*/
public function getLeftObservation()
{
return $this->leftObservation;
}
/**
* Set the value of leftObservation
*
* @return self
*/
public function setLeftObservation($leftObservation)
{
$this->leftObservation = $leftObservation;
return $this;
}
/**
* Get the value of rightObservation
*/
public function getRightObservation()
{
return $this->rightObservation;
}
/**
* Set the value of rightObservation
*
* @return self
*/
public function setRightObservation($rightObservation)
{
$this->rightObservation = $rightObservation;
return $this;
}
public function getCreatedAt(): ?\DateTimeInterface
{
return $this->createdAt;
}
public function setCreatedAt(?\DateTimeInterface $createdAt): self
{
$this->createdAt = $createdAt;
return $this;
}
public function getShippingVehicle(): ?ShippingVehicle
{
return $this->shippingVehicle;
}
public function setShippingVehicle(?ShippingVehicle $shippingVehicle): self
{
$this->shippingVehicle = $shippingVehicle;
return $this;
}
public function getFrontImageBase64(): ?string
{
return $this->frontImageBase64;
}
public function setFrontImageBase64(?string $frontImageBase64): self
{
$this->frontImageBase64 = $frontImageBase64;
return $this;
}
}