diff --git a/Classes/Domain/Model/Company.php b/Classes/Domain/Model/Company.php index 64c16e50848ed9c6bded1d93b387c68e220b3d42..c27621410723c3ce23ef62a53ba814e444ad07ea 100644 --- a/Classes/Domain/Model/Company.php +++ b/Classes/Domain/Model/Company.php @@ -33,24 +33,24 @@ use TYPO3\CMS\Extbase\DomainObject\AbstractEntity; */ class Company extends AbstractEntity { /** - * @var string $zip + * @var string $jobId */ - protected $zip = ''; + protected $jobId = ''; /** - * @var string $city + * @var string $name */ - protected $city = ''; + protected $name = ''; /** - * @var string $jobId + * @var string $zip */ - protected $jobId = ''; + protected $zip = ''; /** - * @var string $name + * @var string $city */ - protected $name = ''; + protected $city = ''; /** * @var string $street diff --git a/Classes/Domain/Model/Contact.php b/Classes/Domain/Model/Contact.php index 1c30a1d480097765c1ec686ce98ddf68f31c9658..065c5de305fb0f1b5eb6def3da718b52c4c5f4b1 100644 --- a/Classes/Domain/Model/Contact.php +++ b/Classes/Domain/Model/Contact.php @@ -59,6 +59,31 @@ class Contact extends AbstractEntity { */ protected $phone = ''; + /** + * @var string $zip + */ + protected $zip = ''; + + /** + * @var string $city + */ + protected $city = ''; + + /** + * @var string $street + */ + protected $street = ''; + + /** + * @var string $state + */ + protected $state = ''; + + /** + * @var string $country + */ + protected $country = ''; + /** * @TYPO3\CMS\Extbase\Annotation\ORM\Lazy * @var FileReference @@ -152,4 +177,74 @@ class Contact extends AbstractEntity { return $this->image; } + + /** + * @return string + */ + public function getCity() { + return $this->city; + } + + /** + * @param string $city + */ + public function setCity(string $city) { + $this->city = $city; + } + + /** + * @return string + */ + public function getState() { + return $this->state; + } + + /** + * @param string $state + */ + public function setState(string $state) { + $this->state = $state; + } + + /** + * @return string + */ + public function getCountry() { + return $this->country; + } + + /** + * @param string $country + */ + public function setCountry(string $country) { + $this->country = $country; + } + + /** + * @return string + */ + public function getStreet() { + return $this->street; + } + + /** + * @param string $street + */ + public function setStreet(string $street) { + $this->street = $street; + } + + /** + * @return string + */ + public function getZip() { + return $this->zip; + } + + /** + * @param string $zip + */ + public function setZip($zip) { + $this->zip = $zip; + } } diff --git a/Resources/Private/Templates/Joblist/ApplyForm.html b/Resources/Private/Templates/Joblist/ApplyForm.html index 9b395b300a157ffd6521526b408ee1bbf504dc52..28163f2b849caceea636e29273c21a302d0acf32 100644 --- a/Resources/Private/Templates/Joblist/ApplyForm.html +++ b/Resources/Private/Templates/Joblist/ApplyForm.html @@ -100,11 +100,42 @@ {job.company.contact.title} {job.company.contact.firstName} {job.company.contact.lastName}<br> </f:else> </f:if> - {job.company.street}<br> - <f:if condition="{job.company.state}"> - {job.company.state}<br> + <f:if condition="{job.contact} && {job.contact.street}"> + <f:then> + {job.contact.street}<br> + <f:if condition="{job.contact.state}"> + {job.contact.state}<br> + </f:if> + {job.contact.zip} {job.contact.city} + <f:if condition="{job.contact.country}"> + <br>{job.contact.country} + </f:if> + </f:then> + <f:else> + <f:if condition="{job.company.contact} && {job.company.contact.street}"> + <f:then> + {job.company.contact.street}<br> + <f:if condition="{job.company.contact.state}"> + {job.company.contact.state}<br> + </f:if> + {job.company.contact.zip} {job.company.contact.city} + <f:if condition="{job.company.contact.country}"> + <br>{job.company.contact.country} + </f:if> + </f:then> + <f:else> + {job.company.street}<br> + <f:if condition="{job.company.state}"> + {job.company.state}<br> + </f:if> + {job.company.zip} {job.company.city} + <f:if condition="{job.company.country}"> + <br>{job.company.country} + </f:if> + </f:else> + </f:if> + </f:else> </f:if> - {job.company.zip} {job.company.city} </p> </f:if>