src/Entity/Accommodation.php line 16

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Constant\OwnerType;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Symfony\Component\Validator\Constraints as Assert;
  7. use Gedmo\Mapping\Annotation as Gedmo;
  8. use Doctrine\ORM\Mapping as ORM;
  9. /**
  10.  * @ORM\Entity
  11.  * @ORM\Table(name="cal_accommodation")
  12.  */
  13. class Accommodation
  14. {
  15.     /**
  16.      * @ORM\Id
  17.      * @ORM\GeneratedValue
  18.      * @ORM\Column(type="integer")
  19.      */
  20.     private $id;
  21.     /**
  22.      * @Assert\NotBlank()
  23.      * @Assert\Length(max=100)
  24.      * @ORM\Column(type="string", length=100)
  25.      */
  26.     private $name "";
  27.     /**
  28.      * @ORM\OneToOne(targetEntity="App\Entity\Address", cascade={"persist"}, orphanRemoval=true)
  29.      */
  30.     private $address;
  31.     /**
  32.      * @ORM\OneToOne(targetEntity="App\Entity\Translation", cascade={"persist"}, orphanRemoval=true)
  33.      */
  34.     private $description;
  35.     /**
  36.      * @ORM\OneToOne(targetEntity="App\Entity\AccommodationImage", cascade={"persist"}, orphanRemoval=true)
  37.      */
  38.     private $cover;
  39.     /**
  40.      * @ORM\OneToMany(targetEntity="App\Entity\AccommodationImage", mappedBy="accommodation", cascade={"persist"}, orphanRemoval=true)
  41.      * @ORM\OrderBy({"position" = "ASC"})
  42.      */
  43.     private $images;
  44.     /**
  45.      * @ORM\OneToOne(targetEntity="App\Entity\AccommodationImage", cascade={"persist"}, orphanRemoval=true)
  46.      */
  47.     private $plan;
  48.     /**
  49.      * @ORM\Column(type="string", length=255, nullable=true)
  50.      */
  51.     private $virtualTour "";
  52.     /**
  53.      * @ORM\Column(type="boolean", nullable=true)
  54.      */
  55.     private $petFriendly;
  56.     /**
  57.      * @ORM\Column(type="boolean", nullable=true)
  58.      */
  59.     private $girlsOnly;
  60.     /**
  61.      * @ORM\Column(type="integer", nullable=true)
  62.      */
  63.     private $surface;
  64.     /**
  65.      * @ORM\Column(type="string", length=24, nullable=true)
  66.      */
  67.     private $type "";
  68.     /**
  69.      * @ORM\Column(type="string", length=500, nullable=true)
  70.      */
  71.     private $constructionYear "";
  72.     /**
  73.      * @ORM\Column(type="integer", nullable=true)
  74.      */
  75.     private $totalBedrooms;
  76.     /**
  77.      * @ORM\Column(type="integer", nullable=true)
  78.      */
  79.     private $totalBathrooms;
  80.     /**
  81.      * @ORM\Column(type="integer", nullable=true)
  82.      */
  83.     private $totalKitchens;
  84.     /**
  85.      * @ORM\Column(type="integer", nullable=true)
  86.      */
  87.     private $totalToilets;
  88.     /**
  89.      * @ORM\Column(type="boolean", nullable=true)
  90.      */
  91.     private $garden;
  92.     /**
  93.      * @ORM\OneToOne(targetEntity="App\Entity\Translation", cascade={"persist"}, orphanRemoval=true)
  94.      */
  95.     private $access;
  96.     /**
  97.      * @ORM\ManyToOne(targetEntity="App\Entity\PropertyListItem")
  98.      */
  99.     private $district;
  100.     /**
  101.      * @ORM\ManyToMany(targetEntity="App\Entity\PropertyListItem")
  102.      * @ORM\JoinTable(name="cal_accommodations_universities")
  103.      */
  104.     private $universities;
  105.     /**
  106.      * @ORM\ManyToMany(targetEntity="App\Entity\PropertyListItem")
  107.      * @ORM\JoinTable(name="cal_accommodations_transports")
  108.      */
  109.     private $transports;
  110.     /**
  111.      * @ORM\ManyToMany(targetEntity="App\Entity\PropertyListItem")
  112.      * @ORM\JoinTable(name="cal_accommodations_equipments")
  113.      */
  114.     private $equipments;
  115.     /**
  116.      * @ORM\ManyToMany(targetEntity="App\Entity\PropertyListItem")
  117.      * @ORM\JoinTable(name="cal_accommodations_security")
  118.      */
  119.     private $security;
  120.     /**
  121.      * @ORM\ManyToMany(targetEntity="App\Entity\PropertyListItem")
  122.      * @ORM\JoinTable(name="cal_accommodations_services")
  123.      */
  124.     private $services;
  125.     /**
  126.      * @var \DateTime $createdAt
  127.      *
  128.      * @Gedmo\Timestampable(on="create")
  129.      * @ORM\Column(type="datetime")
  130.      */
  131.     private $createdAt;
  132.     /**
  133.      * @var \DateTime $updated
  134.      *
  135.      * @Gedmo\Timestampable(on="update")
  136.      * @ORM\Column(type="datetime")
  137.      */
  138.     private $updatedAt;
  139.     /**
  140.      * @ORM\Column(type="boolean", nullable=true)
  141.      */
  142.     private $disabled false;
  143.     /**
  144.      * @ORM\OneToMany(targetEntity="App\Entity\AccommodationRoom", mappedBy="accommodation", orphanRemoval=false)
  145.      */
  146.     private $rooms = [];
  147.     /**
  148.      * @ORM\OneToMany(targetEntity="App\Entity\AccommodationReport", mappedBy="accommodation", orphanRemoval=false)
  149.      */
  150.     private $reports = [];
  151.     /**
  152.      * @ORM\OneToMany(targetEntity="App\Entity\Booking", mappedBy="accommodation")
  153.      */
  154.     private $bookings;
  155.     /**
  156.      * @ORM\OneToMany(targetEntity="App\Entity\AccommodationZone", mappedBy="accommodation", cascade={"persist"}, orphanRemoval=true)
  157.      * @ORM\OrderBy({"priority" = "DESC"})
  158.      */
  159.     private $zones;
  160.     /**
  161.      * @ORM\Column(type="string", length=50, nullable=true)
  162.      */
  163.     private $ownerType OwnerType::COLOCALYON_TRANSACTION;
  164.     /**
  165.      * @ORM\ManyToOne(targetEntity="App\Entity\User", inversedBy="ownedAccommodations")
  166.      */
  167.     private $owner;
  168.     /**
  169.      * @ORM\OneToOne(targetEntity="App\Entity\AccommodationOwnerInfo", cascade={"persist"}, orphanRemoval=true)
  170.      */
  171.     private $ownerInfo;
  172.     /**
  173.      * @ORM\OneToOne(targetEntity="App\Entity\AccommodationInfo", cascade={"persist"}, orphanRemoval=true)
  174.      */
  175.     private $info;
  176.     /**
  177.      * @ORM\OneToMany(targetEntity="App\Entity\Maintenance", mappedBy="accommodation")
  178.      */
  179.     private $maintenances;
  180.     /**
  181.      * @ORM\OneToMany(targetEntity="App\Entity\Survey", mappedBy="accommodation")
  182.      */
  183.     private $surveys;
  184.     /**
  185.      * @ORM\OneToOne(targetEntity="App\Entity\CleaningRecurrence", cascade={"persist"}, orphanRemoval=true)
  186.      */
  187.     private $cleaningRecurrence;
  188.     /**
  189.      * @ORM\OneToMany(targetEntity="App\Entity\CleaningDate", mappedBy="accommodation")
  190.      * @ORM\OrderBy({"date" = "ASC"})
  191.      */
  192.     private $cleaningDates;
  193.     /**
  194.      * @ORM\Column(type="integer", nullable=true)
  195.      */
  196.     private $squareMeterPrice;
  197.     /**
  198.      * @ORM\Column(type="integer", nullable=true)
  199.      */
  200.     private $majoredSquareMeterPrice;
  201.     /**
  202.      * @ORM\OneToMany(targetEntity="App\Entity\Insurance", mappedBy="accommodation", cascade={"persist"})
  203.      */
  204.     private $insurances;
  205.     /**
  206.      * @ORM\OneToOne (targetEntity="App\Entity\WorkflowProject", mappedBy="accommodation")
  207.      */
  208.     private $project;
  209.     //--------------------------------------------------------------
  210.     // Utilities
  211.     //--------------------------------------------------------------
  212.     public function __toString() {
  213.         return $this->getName();
  214.     }
  215.     public function __construct()
  216.     {
  217.         $this->zones = new ArrayCollection();
  218.         $this->images = new ArrayCollection();
  219.         $this->rooms = new ArrayCollection();
  220.         $this->reports = new ArrayCollection();
  221.         $this->maintenances = new ArrayCollection();
  222.         $this->surveys = new ArrayCollection();
  223.         $this->cleaningDates = new ArrayCollection();
  224.         $this->insurances = new ArrayCollection();
  225.     }
  226.     public function getLowestPrice() {
  227.         foreach ($this->getActiveRooms() as $room) {
  228.             if(empty($lowest) || $lowest $room->getRent()){
  229.                 $lowest $room->getRent();
  230.             }
  231.         }
  232.         return !empty($lowest) ? $lowest 0;
  233.     }
  234.     public function getTotalAvailableRooms() {
  235.         $total 0;
  236.         foreach ($this->getActiveRooms() as $room) {
  237.             if($room->isAvailable()){
  238.                 $total++;
  239.             }
  240.         }
  241.         return $total;
  242.     }
  243.     public function getFirstRoomAvailability() {
  244.         $dates array_filter($this->getRooms()->map(function(AccommodationRoom $room){
  245.            return $room->getAvailablilityDate();
  246.         })->toArray());
  247.         return !empty($dates) ? min($dates) : null;
  248.     }
  249.     public function getActiveRooms() {
  250.         return $this->getRooms()->filter(function(AccommodationRoom $room){
  251.             return !$room->getDisabled();
  252.         });
  253.     }
  254.     public function getRoommates() {
  255.         $users = [];
  256.         foreach ($this->getActiveRooms() as $room) {
  257.             if(!$room->isAvailable()){
  258.                 $occupancy $room->getOccupancy();
  259.                 if ($occupancy instanceof AccommodationOccupancy) {
  260.                     $users[] = $occupancy->getUser();
  261.                 }
  262.             }
  263.         }
  264.         return $users;
  265.     }
  266.     public function getCleaningDuration() {
  267.         return !empty($this->getCleaningRecurrence()) ? $this->getCleaningRecurrence()->getDuration() : 60;
  268.     }
  269.     public function getNextsCleaningDates() {
  270.         return $this->getCleaningDates()->slice(03);
  271.     }
  272.     public function getRoomsWithCleaning() {
  273.         return $this->getRooms()->filter(function ($room) {
  274.             $occupancy $room->getOccupancy();
  275.             if ($occupancy instanceof AccommodationOccupancy) {
  276.                 return $occupancy->isActive() && $occupancy->getActiveCleaning();
  277.             }
  278.             return false;
  279.         });
  280.     }
  281.     public function hasEmptyZone() {
  282.         if ($this->getZones()->count() === 0) return true;
  283.         $hasEmptyZone false;
  284.         foreach ($this->getZones() as $zone) {
  285.             if ($zone->isEmpty()) $hasEmptyZone true;
  286.         }
  287.         foreach ($this->getRooms() as $room) {
  288.             if ($room->hasEmptyZone()) $hasEmptyZone true;
  289.         }
  290.         return $hasEmptyZone;
  291.     }
  292.     public function export() {
  293.         $datas = [
  294.             "id" => $this->getId(),
  295.             "name" => $this->getName(),
  296.             "address" => $this->getAddress()->getFullAddress(),
  297.             "surface" => $this->getSurface(),
  298.             "total_bedrooms" => $this->getTotalBedrooms(),
  299.             "total_bathrooms" => $this->getTotalBathrooms(),
  300.             "total_kitchens" => $this->getTotalKitchens(),
  301.             "total_toilets" => $this->getTotalToilets(),
  302.             "total_roommates" => count($this->getRoommates()),
  303.         ];
  304.         if ($this->getOwner() instanceof User) {
  305.             $datas array_merge($datas, [
  306.                 "owner" => $this->getOwner()->getFullName(),
  307.             ]);
  308.         }
  309.         return $datas;
  310.     }
  311.     //--------------------------------------------------------------
  312.     // Collections
  313.     //--------------------------------------------------------------
  314.     public function addImage(AccommodationImage $image)
  315.     {
  316.         $image->setAccommodation($this);
  317.         $this->images[] = $image;
  318.         return $this;
  319.     }
  320.     public function removeImage(AccommodationImage $image)
  321.     {
  322.         $this->images->removeElement($image);
  323.     }
  324.     //--------------------------------------------------------------
  325.     // Getters and setters
  326.     //--------------------------------------------------------------
  327.     public function getImages()
  328.     {
  329.         return $this->images;
  330.     }
  331.     public function setImages($images)
  332.     {
  333.         $this->images $images;
  334.     }
  335.     /**
  336.      * @return mixed
  337.      */
  338.     public function getId()
  339.     {
  340.         return $this->id;
  341.     }
  342.     /**
  343.      * @param mixed $id
  344.      */
  345.     public function setId($id)
  346.     {
  347.         $this->id $id;
  348.     }
  349.     /**
  350.      * @return mixed
  351.      */
  352.     public function getName()
  353.     {
  354.         return $this->name;
  355.     }
  356.     /**
  357.      * @param mixed $name
  358.      */
  359.     public function setName($name)
  360.     {
  361.         $this->name $name;
  362.     }
  363.     /**
  364.      * @return mixed
  365.      */
  366.     public function getAddress()
  367.     {
  368.         return $this->address;
  369.     }
  370.     /**
  371.      * @param mixed $address
  372.      */
  373.     public function setAddress($address)
  374.     {
  375.         $this->address $address;
  376.     }
  377.     /**
  378.      * @return mixed
  379.      */
  380.     public function getDescription()
  381.     {
  382.         return $this->description;
  383.     }
  384.     /**
  385.      * @param mixed $description
  386.      */
  387.     public function setDescription($description)
  388.     {
  389.         $this->description $description;
  390.     }
  391.     /**
  392.      * @return mixed
  393.      */
  394.     public function getCover()
  395.     {
  396.         return $this->cover;
  397.     }
  398.     /**
  399.      * @param mixed $cover
  400.      */
  401.     public function setCover($cover)
  402.     {
  403.         $this->cover $cover;
  404.     }
  405.     /**
  406.      * @return mixed
  407.      */
  408.     public function getVirtualTour()
  409.     {
  410.         return $this->virtualTour;
  411.     }
  412.     /**
  413.      * @param mixed $virtualTour
  414.      */
  415.     public function setVirtualTour($virtualTour)
  416.     {
  417.         $this->virtualTour $virtualTour;
  418.     }
  419.     /**
  420.      * @return \DateTime
  421.      */
  422.     public function getCreatedAt(): \DateTime
  423.     {
  424.         return $this->createdAt;
  425.     }
  426.     /**
  427.      * @param \DateTime $createdAt
  428.      */
  429.     public function setCreatedAt(\DateTime $createdAt)
  430.     {
  431.         $this->createdAt $createdAt;
  432.     }
  433.     /**
  434.      * @return \DateTime
  435.      */
  436.     public function getUpdatedAt(): \DateTime
  437.     {
  438.         return $this->updatedAt;
  439.     }
  440.     /**
  441.      * @param \DateTime $updatedAt
  442.      */
  443.     public function setUpdatedAt(\DateTime $updatedAt)
  444.     {
  445.         $this->updatedAt $updatedAt;
  446.     }
  447.     /**
  448.      * @return mixed
  449.      */
  450.     public function getPetFriendly()
  451.     {
  452.         return $this->petFriendly;
  453.     }
  454.     /**
  455.      * @param mixed $petFriendly
  456.      */
  457.     public function setPetFriendly($petFriendly)
  458.     {
  459.         $this->petFriendly $petFriendly;
  460.     }
  461.     /**
  462.      * @return mixed
  463.      */
  464.     public function getGirlsOnly()
  465.     {
  466.         return $this->girlsOnly;
  467.     }
  468.     /**
  469.      * @param mixed $girlsOnly
  470.      */
  471.     public function setGirlsOnly($girlsOnly)
  472.     {
  473.         $this->girlsOnly $girlsOnly;
  474.     }
  475.     /**
  476.      * @return mixed
  477.      */
  478.     public function getSurface()
  479.     {
  480.         return $this->surface;
  481.     }
  482.     /**
  483.      * @param mixed $surface
  484.      */
  485.     public function setSurface($surface)
  486.     {
  487.         $this->surface $surface;
  488.     }
  489.     /**
  490.      * @return mixed
  491.      */
  492.     public function getType()
  493.     {
  494.         return $this->type;
  495.     }
  496.     /**
  497.      * @param mixed $type
  498.      */
  499.     public function setType($type)
  500.     {
  501.         $this->type $type;
  502.     }
  503.     /**
  504.      * @return mixed
  505.      */
  506.     public function getTotalBedrooms()
  507.     {
  508.         return $this->totalBedrooms;
  509.     }
  510.     /**
  511.      * @param mixed $totalBedrooms
  512.      */
  513.     public function setTotalBedrooms($totalBedrooms)
  514.     {
  515.         $this->totalBedrooms $totalBedrooms;
  516.     }
  517.     /**
  518.      * @return mixed
  519.      */
  520.     public function getTotalBathrooms()
  521.     {
  522.         return $this->totalBathrooms;
  523.     }
  524.     /**
  525.      * @param mixed $totalBathrooms
  526.      */
  527.     public function setTotalBathrooms($totalBathrooms)
  528.     {
  529.         $this->totalBathrooms $totalBathrooms;
  530.     }
  531.     /**
  532.      * @return mixed
  533.      */
  534.     public function getTotalKitchens()
  535.     {
  536.         return $this->totalKitchens;
  537.     }
  538.     /**
  539.      * @param mixed $totalKitchens
  540.      */
  541.     public function setTotalKitchens($totalKitchens)
  542.     {
  543.         $this->totalKitchens $totalKitchens;
  544.     }
  545.     /**
  546.      * @return mixed
  547.      */
  548.     public function getTotalToilets()
  549.     {
  550.         return $this->totalToilets;
  551.     }
  552.     /**
  553.      * @param mixed $totalToilets
  554.      */
  555.     public function setTotalToilets($totalToilets)
  556.     {
  557.         $this->totalToilets $totalToilets;
  558.     }
  559.     /**
  560.      * @return mixed
  561.      */
  562.     public function getGarden()
  563.     {
  564.         return $this->garden;
  565.     }
  566.     /**
  567.      * @param mixed $garden
  568.      */
  569.     public function setGarden($garden)
  570.     {
  571.         $this->garden $garden;
  572.     }
  573.     /**
  574.      * @return mixed
  575.      */
  576.     public function getAccess()
  577.     {
  578.         return $this->access;
  579.     }
  580.     /**
  581.      * @param mixed $access
  582.      */
  583.     public function setAccess($access)
  584.     {
  585.         $this->access $access;
  586.     }
  587.     /**
  588.      * @return mixed
  589.      */
  590.     public function getDistrict()
  591.     {
  592.         return $this->district;
  593.     }
  594.     /**
  595.      * @param mixed $district
  596.      */
  597.     public function setDistrict($district)
  598.     {
  599.         $this->district $district;
  600.     }
  601.     /**
  602.      * @return mixed
  603.      */
  604.     public function getUniversities()
  605.     {
  606.         return $this->universities;
  607.     }
  608.     /**
  609.      * @param mixed $universities
  610.      */
  611.     public function setUniversities($universities)
  612.     {
  613.         $this->universities $universities;
  614.     }
  615.     /**
  616.      * @return mixed
  617.      */
  618.     public function getTransports()
  619.     {
  620.         return $this->transports;
  621.     }
  622.     /**
  623.      * @param mixed $transports
  624.      */
  625.     public function setTransports($transports)
  626.     {
  627.         $this->transports $transports;
  628.     }
  629.     /**
  630.      * @return mixed
  631.      */
  632.     public function getEquipments()
  633.     {
  634.         return $this->equipments;
  635.     }
  636.     /**
  637.      * @param mixed $equipments
  638.      */
  639.     public function setEquipments($equipments)
  640.     {
  641.         $this->equipments $equipments;
  642.     }
  643.     /**
  644.      * @return mixed
  645.      */
  646.     public function getSecurity()
  647.     {
  648.         return $this->security;
  649.     }
  650.     /**
  651.      * @param mixed $security
  652.      */
  653.     public function setSecurity($security)
  654.     {
  655.         $this->security $security;
  656.     }
  657.     /**
  658.      * @return mixed
  659.      */
  660.     public function getServices()
  661.     {
  662.         return $this->services;
  663.     }
  664.     /**
  665.      * @param mixed $services
  666.      */
  667.     public function setServices($services)
  668.     {
  669.         $this->services $services;
  670.     }
  671.     /**
  672.      * @return mixed
  673.      */
  674.     public function getDisabled()
  675.     {
  676.         return $this->disabled;
  677.     }
  678.     /**
  679.      * @param mixed $disabled
  680.      */
  681.     public function setDisabled($disabled)
  682.     {
  683.         $this->disabled $disabled;
  684.     }
  685.     /**
  686.      * @return mixed
  687.      */
  688.     public function getRooms()
  689.     {
  690.         return $this->rooms;
  691.     }
  692.     /**
  693.      * @param mixed $rooms
  694.      */
  695.     public function setRooms($rooms)
  696.     {
  697.         $this->rooms $rooms;
  698.     }
  699.     /**
  700.      * @return mixed
  701.      */
  702.     public function getBookings()
  703.     {
  704.         return $this->bookings;
  705.     }
  706.     /**
  707.      * @param mixed $bookings
  708.      */
  709.     public function setBookings($bookings)
  710.     {
  711.         $this->bookings $bookings;
  712.     }
  713.     /**
  714.      * @return mixed
  715.      */
  716.     public function getZones()
  717.     {
  718.         return $this->zones;
  719.     }
  720.     /**
  721.      * @param mixed $zones
  722.      */
  723.     public function setZones($zones): void
  724.     {
  725.         $this->zones $zones;
  726.     }
  727.     /**
  728.      * @return mixed
  729.      */
  730.     public function getOwner()
  731.     {
  732.         return $this->owner;
  733.     }
  734.     /**
  735.      * @param mixed $owner
  736.      */
  737.     public function setOwner($owner): void
  738.     {
  739.         $this->owner $owner;
  740.     }
  741.     /**
  742.      * @return string
  743.      */
  744.     public function getOwnerType(): string
  745.     {
  746.         return $this->ownerType;
  747.     }
  748.     /**
  749.      * @param string $ownerType
  750.      */
  751.     public function setOwnerType(string $ownerType): void
  752.     {
  753.         $this->ownerType $ownerType;
  754.     }
  755.     /**
  756.      * @return mixed
  757.      */
  758.     public function getOwnerInfo()
  759.     {
  760.         return $this->ownerInfo;
  761.     }
  762.     /**
  763.      * @param mixed $ownerInfo
  764.      */
  765.     public function setOwnerInfo($ownerInfo): void
  766.     {
  767.         $this->ownerInfo $ownerInfo;
  768.     }
  769.     /**
  770.      * @return mixed
  771.      */
  772.     public function getInfo()
  773.     {
  774.         return $this->info;
  775.     }
  776.     /**
  777.      * @param mixed $info
  778.      */
  779.     public function setInfo($info): void
  780.     {
  781.         $this->info $info;
  782.     }
  783.     /**
  784.      * @return mixed
  785.      */
  786.     public function getSurveys()
  787.     {
  788.         return $this->surveys;
  789.     }
  790.     /**
  791.      * @param mixed $surveys
  792.      */
  793.     public function setSurveys($surveys): void
  794.     {
  795.         $this->surveys $surveys;
  796.     }
  797.     /**
  798.      * @return ArrayCollection
  799.      */
  800.     public function getCleaningDates()
  801.     {
  802.         return $this->cleaningDates;
  803.     }
  804.     /**
  805.      * @param ArrayCollection $cleaningDates
  806.      */
  807.     public function setCleaningDates($cleaningDates): void
  808.     {
  809.         $this->cleaningDates $cleaningDates;
  810.     }
  811.     /**
  812.      * @return mixed
  813.      */
  814.     public function getCleaningRecurrence()
  815.     {
  816.         return $this->cleaningRecurrence;
  817.     }
  818.     /**
  819.      * @param mixed $cleaningRecurrence
  820.      */
  821.     public function setCleaningRecurrence($cleaningRecurrence): void
  822.     {
  823.         $this->cleaningRecurrence $cleaningRecurrence;
  824.     }
  825.     /**
  826.      * @return string
  827.      */
  828.     public function getConstructionYear()
  829.     {
  830.         return $this->constructionYear;
  831.     }
  832.     /**
  833.      * @param string $constructionYear
  834.      */
  835.     public function setConstructionYear($constructionYear): void
  836.     {
  837.         $this->constructionYear $constructionYear;
  838.     }
  839.     /**
  840.      * @return mixed
  841.      */
  842.     public function getSquareMeterPrice()
  843.     {
  844.         return $this->squareMeterPrice 100;
  845.     }
  846.     /**
  847.      * @param mixed $squareMeterPrice
  848.      */
  849.     public function setSquareMeterPrice($squareMeterPrice): void
  850.     {
  851.         $this->squareMeterPrice $squareMeterPrice 100;
  852.     }
  853.     /**
  854.      * @return mixed
  855.      */
  856.     public function getMajoredSquareMeterPrice()
  857.     {
  858.         return $this->majoredSquareMeterPrice 100;
  859.     }
  860.     /**
  861.      * @param mixed $majoredSquareMeterPrice
  862.      */
  863.     public function setMajoredSquareMeterPrice($majoredSquareMeterPrice): void
  864.     {
  865.         $this->majoredSquareMeterPrice $majoredSquareMeterPrice 100;
  866.     }
  867.     /**
  868.      * @return mixed
  869.      */
  870.     public function getPlan()
  871.     {
  872.         return $this->plan;
  873.     }
  874.     /**
  875.      * @param mixed $plan
  876.      */
  877.     public function setPlan($plan): void
  878.     {
  879.         $this->plan $plan;
  880.     }
  881.     /**
  882.      * @return Collection
  883.      */
  884.     public function getMaintenances(): Collection
  885.     {
  886.         return $this->maintenances;
  887.     }
  888.     /**
  889.      * @param Collection $maintenances
  890.      */
  891.     public function setMaintenances(Collection $maintenances): void
  892.     {
  893.         $this->maintenances $maintenances;
  894.     }
  895.     /**
  896.      * @return Collection
  897.      */
  898.     public function getInsurances(): Collection
  899.     {
  900.         return $this->insurances;
  901.     }
  902.     /**
  903.      * @param Collection $insurances
  904.      */
  905.     public function setInsurances(Collection $insurances): void
  906.     {
  907.         $this->insurances $insurances;
  908.     }
  909.     /**
  910.      * @return mixed
  911.      */
  912.     public function getProject()
  913.     {
  914.         return $this->project;
  915.     }
  916.     /**
  917.      * @param mixed $project
  918.      */
  919.     public function setProject($project): void
  920.     {
  921.         $this->project $project;
  922.     }
  923. }