| @@ 221-232 (lines=12) @@ | ||
| 218 | * @todo This is a workaround for GeoJSON data insertion |
|
| 219 | * until we figured out, what we really want it to be. |
|
| 220 | */ |
|
| 221 | if ('general.locationForm' == $formIdentifier) { |
|
| 222 | $locElem = $instanceForm->getBaseFieldset()->get('geo-location'); |
|
| 223 | if ($locElem instanceof \Geo\Form\GeoText) { |
|
| 224 | $loc = $locElem->getValue('entity'); |
|
| 225 | $locations = $jobEntity->getLocations(); |
|
| 226 | if (count($locations)) { |
|
| 227 | $locations->clear(); |
|
| 228 | } |
|
| 229 | $locations->add($loc); |
|
| 230 | $jobEntity->setLocation($locElem->getValue()); |
|
| 231 | } |
|
| 232 | } |
|
| 233 | ||
| 234 | $title = $jobEntity->getTitle(); |
|
| 235 | $templateTitle = $jobEntity->getTemplateValues()->getTitle(); |
|
| @@ 86-97 (lines=12) @@ | ||
| 83 | * until we figured out, what we really want it to be. |
|
| 84 | */ |
|
| 85 | $formId = $params->fromQuery('form'); |
|
| 86 | if ('preferredJob' == $formId) { |
|
| 87 | $locElem = $form->getBaseFieldset()->get('geo-location'); |
|
| 88 | if ($locElem instanceof GeoText) { |
|
| 89 | $loc = $locElem->getValue('entity'); |
|
| 90 | $locations = $cv->getPreferredJob()->getDesiredLocations(); |
|
| 91 | if (count($locations)) { |
|
| 92 | $locations->clear(); |
|
| 93 | } |
|
| 94 | $locations->add($loc); |
|
| 95 | $cv->getPreferredJob()->setDesiredLocation($locElem->getValue()); |
|
| 96 | } |
|
| 97 | } |
|
| 98 | ||
| 99 | $repositories->store($cv); |
|
| 100 | ||