| @@ 49-65 (lines=17) @@ | ||
| 46 | * Handle an update the major info command. |
|
| 47 | * @param UpdateMajorInfo $updateMajorInfo |
|
| 48 | */ |
|
| 49 | public function handleUpdateMajorInfo(UpdateMajorInfo $updateMajorInfo) |
|
| 50 | { |
|
| 51 | /** @var Event $event */ |
|
| 52 | $event = $this->offerRepository->load($updateMajorInfo->getItemId()); |
|
| 53 | ||
| 54 | $event->updateMajorInfo( |
|
| 55 | $updateMajorInfo->getTitle(), |
|
| 56 | $updateMajorInfo->getEventType(), |
|
| 57 | $updateMajorInfo->getLocation(), |
|
| 58 | $updateMajorInfo->getCalendar(), |
|
| 59 | $updateMajorInfo->getTheme() |
|
| 60 | ); |
|
| 61 | ||
| 62 | $this->offerRepository->save($event); |
|
| 63 | ||
| 64 | } |
|
| 65 | ||
| 66 | /** |
|
| 67 | * @param UpdateLocation $updateLocation |
|
| 68 | */ |
|
| @@ 219-235 (lines=17) @@ | ||
| 216 | * Handle an update the major info command. |
|
| 217 | * @param UpdateMajorInfo $updateMajorInfo |
|
| 218 | */ |
|
| 219 | public function handleUpdateMajorInfo(UpdateMajorInfo $updateMajorInfo) |
|
| 220 | { |
|
| 221 | ||
| 222 | /** @var Place $place */ |
|
| 223 | $place = $this->offerRepository->load($updateMajorInfo->getItemId()); |
|
| 224 | ||
| 225 | $place->updateMajorInfo( |
|
| 226 | $updateMajorInfo->getTitle(), |
|
| 227 | $updateMajorInfo->getEventType(), |
|
| 228 | $updateMajorInfo->getAddress(), |
|
| 229 | $updateMajorInfo->getCalendar(), |
|
| 230 | $updateMajorInfo->getTheme() |
|
| 231 | ); |
|
| 232 | ||
| 233 | $this->offerRepository->save($place); |
|
| 234 | ||
| 235 | } |
|
| 236 | ||
| 237 | protected function getUpdateTypeClassName() |
|
| 238 | { |
|