/**
  * @return mixed|void
  */
 public function createFormRows()
 {
     /**@var $dto \Tixi\ApiBundle\Interfaces\PassengerRegisterDTO */
     $dto = $this->dto;
     $this->basicFormRows[] = new FormRowView('id', 'passenger.field.id', $dto->person_id);
     $this->basicFormRows[] = new FormRowView('gender', 'person.field.gender', Person::constructGenderString($dto->gender));
     $this->basicFormRows[] = new FormRowView('firstname', 'person.field.firstname', $dto->firstname);
     $this->basicFormRows[] = new FormRowView('lastname', 'person.field.lastname', $dto->lastname);
     $this->basicFormRows[] = new FormRowView('telephone', 'person.field.telephone', $dto->telephone);
     if (!empty($dto->building)) {
         $this->basicFormRows[] = new FormRowView('building', 'address.field.building', $dto->building);
     }
     $this->basicFormRows[] = new FormRowView('address', 'address.field.lookahead', $dto->lookaheadaddress->addressDisplayName);
     $this->basicFormRows[] = new FormRowView('isInWheelChair', 'passenger.field.isinwheelchair', Passenger::constructIsInWheelChairString($dto->isInWheelChair));
     $this->basicFormRows[] = new FormRowView('hasMonthlyBilling', 'passenger.field.payment', Passenger::constructMonthlyBillingString($dto->hasMonthlyBilling));
     $this->basicFormRows[] = new FormRowView('insurances', 'passenger.field.insurance', Passenger::constructInsurancesString($dto->insurances));
     $this->basicFormRows[] = new FormRowView('notice', 'passenger.field.notice', $dto->notice);
     if (!empty($dto->entryDate)) {
         $this->expandedFormRows[] = new FormRowView('entrydate', 'person.field.entrydate', $dto->entryDate->format('d.m.Y'));
     }
     if (!empty($dto->birthday)) {
         $this->expandedFormRows[] = new FormRowView('birthday', 'person.field.birthday', $dto->birthday->format('d.m.Y'));
     }
     if (!empty($dto->birthday)) {
         $this->expandedFormRows[] = new FormRowView('age', 'person.field.age', $this->getAge($dto->birthday));
     }
     $this->expandedFormRows[] = new FormRowView('extraminutes', 'person.field.extraminutes', $dto->extraMinutes);
 }
 /**
  * @return mixed|void
  */
 public function createFormRows()
 {
     /**@var $dto \Tixi\ApiBundle\Interfaces\DriverRegisterDTO */
     $dto = $this->dto;
     $this->basicFormRows[] = new FormRowView('id', 'driver.field.id', $dto->person_id);
     $this->basicFormRows[] = new FormRowView('gender', 'person.field.gender', Person::constructGenderString($dto->gender));
     $this->basicFormRows[] = new FormRowView('firstname', 'person.field.firstname', $dto->firstname);
     $this->basicFormRows[] = new FormRowView('lastname', 'person.field.lastname', $dto->lastname);
     $this->basicFormRows[] = new FormRowView('telephone', 'person.field.telephone', $dto->telephone);
     $this->basicFormRows[] = new FormRowView('email', 'person.field.email', $dto->email);
     $this->basicFormRows[] = new FormRowView('wheelChairAttendance', 'driver.field.wheelchair', Driver::constructWheelChairAttendanceString($dto->wheelChairAttendance));
     $this->expandedFormRows[] = new FormRowView('address', 'address.field.lookahead', $dto->lookaheadaddress->addressDisplayName);
     if (!empty($dto->entryDate)) {
         $this->expandedFormRows[] = new FormRowView('entrydate', 'person.field.entrydate', $dto->entryDate->format('d.m.Y'));
     }
     if (!empty($dto->birthday)) {
         $this->expandedFormRows[] = new FormRowView('birthday', 'person.field.birthday', $dto->birthday->format('d.m.Y'));
     }
     if (!empty($dto->birthday)) {
         $this->expandedFormRows[] = new FormRowView('age', 'person.field.age', $this->getAge($dto->birthday));
     }
     $this->expandedFormRows[] = new FormRowView('extraminutes', 'person.field.extraminutes', $dto->extraMinutes);
 }
Exemple #3
0
 /**
  * @param null $gender
  * @param null $firstname
  * @param null $lastname
  * @param null $telephone
  * @param Address $address
  * @param null $licenceNumber
  * @param DriverCategory $driverCategory
  * @param null $wheelChairAttendance
  * @param null $title
  * @param null $email
  * @param null $entryDate
  * @param null $birthday
  * @param null $extraMinutes
  * @param null $details
  * @param null $operationWish
  * @param null $fax
  * @param VehicleCategory[] $contradictVehicleCategories
  */
 public function updateDriverData($gender = null, $firstname = null, $lastname = null, $telephone = null, Address $address = null, $licenceNumber = null, DriverCategory $driverCategory = null, $wheelChairAttendance = null, $title = null, $email = null, $entryDate = null, $birthday = null, $extraMinutes = null, $details = null, $operationWish = null, $fax = null, $contradictVehicleCategories)
 {
     parent::updatePersonData($gender, $firstname, $lastname, $telephone, $address, $title, $email, $entryDate, $birthday, $extraMinutes, $details, null, null, null, $fax);
     if (!empty($licenceNumber)) {
         $this->setLicenceNumber($licenceNumber);
     }
     if (!empty($driverCategory)) {
         $this->setDriverCategory($driverCategory);
     }
     $this->setWheelChairAttendance($wheelChairAttendance);
     $this->setOperationWish($operationWish);
     $this->setContradictVehicleCategories($contradictVehicleCategories);
 }
Exemple #4
0
 /**
  * @param null $gender
  * @param null $firstname
  * @param null $lastname
  * @param null $telephone
  * @param Address $address
  * @param null $title
  * @param bool $isInWheelChair
  * @param null $gotMonthlyBilling
  * @param null $email
  * @param null $entryDate
  * @param null $birthday
  * @param null $extraMinutes
  * @param null $details
  * @param null $notice
  * @param bool $isAuthorizedToRide
  */
 public function updatePassengerData($gender = null, $firstname = null, $lastname = null, $telephone = null, Address $address, $title = null, $isInWheelChair = false, $gotMonthlyBilling = null, $email = null, $entryDate = null, $birthday = null, $extraMinutes = null, $details = null, $notice = null, $isAuthorizedToRide = true)
 {
     parent::updatePersonData($gender, $firstname, $lastname, $telephone, $address, $title, $email, $entryDate, $birthday, $extraMinutes, $details, $isAuthorizedToRide);
     $this->setIsInWheelChair($isInWheelChair);
     $this->setHasMonthlyBilling($gotMonthlyBilling);
     $this->setNotice($notice);
 }
Exemple #5
0
 /**
  * @param null $gender
  * @param null $firstname
  * @param null $lastname
  * @param null $telephone
  * @param Address $address
  * @param null $title
  * @param null $email
  * @param null $entryDate
  * @param null $birthday
  * @param null $extraMinutes
  * @param null $details
  * @param bool $isAuthorizedToRide
  */
 public function updateCustodianData($gender = null, $firstname = null, $lastname = null, $telephone = null, Address $address, $title = null, $email = null, $entryDate = null, $birthday = null, $extraMinutes = null, $details = null, $isAuthorizedToRide = true)
 {
     parent::updatePersonData($gender, $firstname, $lastname, $telephone, $address, $title, $email, $entryDate, $birthday, $extraMinutes, $details, $isAuthorizedToRide);
 }