| @@ 45-53 (lines=9) @@ | ||
| 42 | /** |
|
| 43 | * {@inheritdoc} |
|
| 44 | */ |
|
| 45 | public function recover($trashedId, $newParentId) |
|
| 46 | { |
|
| 47 | $this->logger->logCall(__METHOD__, array('id' => $trashedId, 'newParentId' => $newParentId)); |
|
| 48 | $return = $this->persistenceHandler->trashHandler()->recover($trashedId, $newParentId); |
|
| 49 | ||
| 50 | $this->cache->invalidateTags(['location-' . $trashedId, 'location-path-' . $trashedId]); |
|
| 51 | ||
| 52 | return $return; |
|
| 53 | } |
|
| 54 | ||
| 55 | /** |
|
| 56 | * {@inheritdoc} |
|
| @@ 231-247 (lines=17) @@ | ||
| 228 | /** |
|
| 229 | * {@inheritdoc} |
|
| 230 | */ |
|
| 231 | public function locationMoved($locationId, $oldParentId, $newParentId) |
|
| 232 | { |
|
| 233 | $this->logger->logCall( |
|
| 234 | __METHOD__, |
|
| 235 | array( |
|
| 236 | 'location' => $locationId, |
|
| 237 | 'oldParent' => $oldParentId, |
|
| 238 | 'newParent' => $newParentId, |
|
| 239 | ) |
|
| 240 | ); |
|
| 241 | ||
| 242 | $return = $this->persistenceHandler->urlAliasHandler()->locationMoved($locationId, $oldParentId, $newParentId); |
|
| 243 | ||
| 244 | $this->cache->invalidateTags(['urlAlias-location-' . $locationId, 'urlAlias-location-path-' . $locationId]); |
|
| 245 | ||
| 246 | return $return; |
|
| 247 | } |
|
| 248 | ||
| 249 | /** |
|
| 250 | * {@inheritdoc} |
|
| @@ 252-271 (lines=20) @@ | ||
| 249 | /** |
|
| 250 | * {@inheritdoc} |
|
| 251 | */ |
|
| 252 | public function locationCopied($locationId, $newLocationId, $newParentId) |
|
| 253 | { |
|
| 254 | $this->logger->logCall( |
|
| 255 | __METHOD__, |
|
| 256 | array( |
|
| 257 | 'oldLocation' => $locationId, |
|
| 258 | 'newLocation' => $newLocationId, |
|
| 259 | 'newParent' => $newParentId, |
|
| 260 | ) |
|
| 261 | ); |
|
| 262 | ||
| 263 | $return = $this->persistenceHandler->urlAliasHandler()->locationCopied( |
|
| 264 | $locationId, |
|
| 265 | $newLocationId, |
|
| 266 | $newParentId |
|
| 267 | ); |
|
| 268 | $this->cache->invalidateTags(['urlAlias-location-' . $locationId, 'urlAlias-location-' . $newLocationId]); |
|
| 269 | ||
| 270 | return $return; |
|
| 271 | } |
|
| 272 | ||
| 273 | /** |
|
| 274 | * {@inheritdoc} |
|
| @@ 344-362 (lines=19) @@ | ||
| 341 | /** |
|
| 342 | * {@inheritdoc} |
|
| 343 | */ |
|
| 344 | public function archiveUrlAliasesForDeletedTranslations($locationId, $parentLocationId, array $languageCodes) |
|
| 345 | { |
|
| 346 | $this->logger->logCall( |
|
| 347 | __METHOD__, |
|
| 348 | [ |
|
| 349 | 'locationId' => $locationId, |
|
| 350 | 'parentLocationId' => $parentLocationId, |
|
| 351 | 'languageCodes' => implode(',', $languageCodes), |
|
| 352 | ] |
|
| 353 | ); |
|
| 354 | ||
| 355 | $this->persistenceHandler->urlAliasHandler()->archiveUrlAliasesForDeletedTranslations( |
|
| 356 | $locationId, |
|
| 357 | $parentLocationId, |
|
| 358 | $languageCodes |
|
| 359 | ); |
|
| 360 | ||
| 361 | $this->cache->invalidateTags(['urlAlias-location-' . $locationId, 'urlAlias-location-path-' . $locationId]); |
|
| 362 | } |
|
| 363 | ||
| 364 | /** |
|
| 365 | * Return relevant UrlAlias and optionally UrlAlias location tags so cache can be purged reliably. |
|
| @@ 410-418 (lines=9) @@ | ||
| 407 | /** |
|
| 408 | * {@inheritdoc} |
|
| 409 | */ |
|
| 410 | public function assignRole($contentId, $roleId, array $limitation = null) |
|
| 411 | { |
|
| 412 | $this->logger->logCall(__METHOD__, array('group' => $contentId, 'role' => $roleId, 'limitation' => $limitation)); |
|
| 413 | $return = $this->persistenceHandler->userHandler()->assignRole($contentId, $roleId, $limitation); |
|
| 414 | ||
| 415 | $this->cache->invalidateTags(['role-assignment-group-list-' . $contentId, 'role-assignment-role-list-' . $roleId]); |
|
| 416 | ||
| 417 | return $return; |
|
| 418 | } |
|
| 419 | ||
| 420 | /** |
|
| 421 | * {@inheritdoc} |
|
| @@ 423-431 (lines=9) @@ | ||
| 420 | /** |
|
| 421 | * {@inheritdoc} |
|
| 422 | */ |
|
| 423 | public function unassignRole($contentId, $roleId) |
|
| 424 | { |
|
| 425 | $this->logger->logCall(__METHOD__, array('group' => $contentId, 'role' => $roleId)); |
|
| 426 | $return = $this->persistenceHandler->userHandler()->unassignRole($contentId, $roleId); |
|
| 427 | ||
| 428 | $this->cache->invalidateTags(['role-assignment-group-list-' . $contentId, 'role-assignment-role-list-' . $roleId]); |
|
| 429 | ||
| 430 | return $return; |
|
| 431 | } |
|
| 432 | ||
| 433 | /** |
|
| 434 | * {@inheritdoc} |
|