Exemple #1
0
 public function toArray(ObjectManager $om)
 {
     $data = array();
     $roomsTransformer = new RoomsToStringTransformer();
     $servicesTransformer = new ServicesToStringTransformer($om);
     $data['searchcriteria'] = $this->searchString;
     $data['startdate'] = $this->datePax->startingDate->format('Y-m-d');
     $data['enddate'] = $this->datePax->endingDate->format('Y-m-d');
     $data['roomsstring'] = $roomsTransformer->transform($this->datePax->getSelectedRooms());
     $data['accentCard'] = $this->accentCard;
     $data['flexible'] = $this->flexible_dates ? 1 : 0;
     $data['servicesstring'] = $servicesTransformer->transform($this->services);
     $data['budgetmin'] = $this->budget_min;
     $data['budgetmax'] = $this->budget_max;
     $data['brands'] = $this->brands;
     $data['radius'] = $this->radius;
     $data['nbAdults'] = $this->getNbAdults();
     $data['nbChildren'] = $this->getNbChildren();
     $data['nbRooms'] = $this->datePax->getNbRooms();
     $data['geolocationLat'] = $this->geolocationLat;
     $data['geolocationLng'] = $this->geolocationLng;
     return $data;
 }