| @@ 264-277 (lines=14) @@ | ||
| 261 | * Apply the description updated event to the place repository. |
|
| 262 | * @param DescriptionUpdated $descriptionUpdated |
|
| 263 | */ |
|
| 264 | protected function applyDescriptionUpdated( |
|
| 265 | DescriptionUpdated $descriptionUpdated |
|
| 266 | ) { |
|
| 267 | ||
| 268 | $document = $this->loadPlaceDocumentFromRepository($descriptionUpdated); |
|
| 269 | ||
| 270 | $placeLD = $document->getBody(); |
|
| 271 | if (empty($placeLD->description)) { |
|
| 272 | $placeLD->description = new \stdClass(); |
|
| 273 | } |
|
| 274 | $placeLD->description->{'nl'} = $descriptionUpdated->getDescription(); |
|
| 275 | ||
| 276 | $this->repository->save($document->withBody($placeLD)); |
|
| 277 | } |
|
| 278 | ||
| 279 | /** |
|
| 280 | * Apply the booking info updated event to the place repository. |
|
| @@ 688-700 (lines=13) @@ | ||
| 685 | * Apply the description updated event to the event repository. |
|
| 686 | * @param DescriptionUpdated $descriptionUpdated |
|
| 687 | */ |
|
| 688 | protected function applyDescriptionUpdated( |
|
| 689 | DescriptionUpdated $descriptionUpdated |
|
| 690 | ) { |
|
| 691 | $document = $this->loadDocumentFromRepository($descriptionUpdated); |
|
| 692 | ||
| 693 | $eventLd = $document->getBody(); |
|
| 694 | if (empty($eventLd->description)) { |
|
| 695 | $eventLd->description = new \stdClass(); |
|
| 696 | } |
|
| 697 | $eventLd->description->{'nl'} = $descriptionUpdated->getDescription(); |
|
| 698 | ||
| 699 | $this->repository->save($document->withBody($eventLd)); |
|
| 700 | } |
|
| 701 | ||
| 702 | /** |
|
| 703 | * Apply the typical age range updated event to the event repository. |
|