| @@ 150-159 (lines=10) @@ | ||
| 147 | /** |
|
| 148 | * {@inheritdoc} |
|
| 149 | */ |
|
| 150 | public function delete($id) |
|
| 151 | { |
|
| 152 | $this->logger->logCall(__METHOD__, array('language' => $id)); |
|
| 153 | $return = $this->persistenceHandler->contentLanguageHandler()->delete($id); |
|
| 154 | ||
| 155 | // As we don't have locale we clear cache by tag invalidation |
|
| 156 | $this->cache->invalidateTags(['language-' . $id]); |
|
| 157 | ||
| 158 | return $return; |
|
| 159 | } |
|
| 160 | } |
|
| 161 | ||
| @@ 318-326 (lines=9) @@ | ||
| 315 | /** |
|
| 316 | * {@inheritdoc} |
|
| 317 | */ |
|
| 318 | public function createDraft($modifierId, $typeId) |
|
| 319 | { |
|
| 320 | $this->logger->logCall(__METHOD__, array('modifier' => $modifierId, 'type' => $typeId)); |
|
| 321 | $draft = $this->persistenceHandler->contentTypeHandler()->createDraft($modifierId, $typeId); |
|
| 322 | ||
| 323 | $this->cache->deleteItems(['ez-content-type-' . $typeId . '-' . Type::STATUS_DRAFT]); |
|
| 324 | ||
| 325 | return $draft; |
|
| 326 | } |
|
| 327 | ||
| 328 | /** |
|
| 329 | * {@inheritdoc} |
|
| @@ 228-236 (lines=9) @@ | ||
| 225 | /** |
|
| 226 | * {@inheritdoc} |
|
| 227 | */ |
|
| 228 | public function delete($stateId) |
|
| 229 | { |
|
| 230 | $this->logger->logCall(__METHOD__, array('stateId' => $stateId)); |
|
| 231 | $return = $this->persistenceHandler->objectStateHandler()->delete($stateId); |
|
| 232 | ||
| 233 | $this->cache->invalidateTags(['state-' . $stateId]); |
|
| 234 | ||
| 235 | return $return; |
|
| 236 | } |
|
| 237 | ||
| 238 | /** |
|
| 239 | * {@inheritdoc} |
|
| @@ 94-102 (lines=9) @@ | ||
| 91 | /** |
|
| 92 | * {@inheritdoc} |
|
| 93 | */ |
|
| 94 | public function delete($id) |
|
| 95 | { |
|
| 96 | $this->logger->logCall(__METHOD__, array('section' => $id)); |
|
| 97 | $return = $this->persistenceHandler->sectionHandler()->delete($id); |
|
| 98 | ||
| 99 | $this->cache->invalidateTags(['section-' . $id]); |
|
| 100 | ||
| 101 | return $return; |
|
| 102 | } |
|
| 103 | ||
| 104 | /** |
|
| 105 | * {@inheritdoc} |
|
| @@ 214-221 (lines=8) @@ | ||
| 211 | /** |
|
| 212 | * {@inheritdoc} |
|
| 213 | */ |
|
| 214 | public function expireUserToken($hash) |
|
| 215 | { |
|
| 216 | $this->logger->logCall(__METHOD__, array('hash' => $hash)); |
|
| 217 | $return = $this->persistenceHandler->userHandler()->expireUserToken($hash); |
|
| 218 | $this->cache->deleteItems(['ez-user-' . $hash . '-by-account-key']); |
|
| 219 | ||
| 220 | return $return; |
|
| 221 | } |
|
| 222 | ||
| 223 | /** |
|
| 224 | * {@inheritdoc} |
|
| @@ 226-235 (lines=10) @@ | ||
| 223 | /** |
|
| 224 | * {@inheritdoc} |
|
| 225 | */ |
|
| 226 | public function delete($userId) |
|
| 227 | { |
|
| 228 | $this->logger->logCall(__METHOD__, array('user' => $userId)); |
|
| 229 | $return = $this->persistenceHandler->userHandler()->delete($userId); |
|
| 230 | ||
| 231 | // user id == content id == group id |
|
| 232 | $this->cache->invalidateTags(['content-fields-' . $userId, 'user-' . $userId]); |
|
| 233 | ||
| 234 | return $return; |
|
| 235 | } |
|
| 236 | ||
| 237 | /** |
|
| 238 | * {@inheritdoc} |
|
| @@ 451-459 (lines=9) @@ | ||
| 448 | /** |
|
| 449 | * {@inheritdoc} |
|
| 450 | */ |
|
| 451 | public function addPolicy($roleId, Policy $policy) |
|
| 452 | { |
|
| 453 | $this->logger->logCall(__METHOD__, array('role' => $roleId, 'struct' => $policy)); |
|
| 454 | $return = $this->persistenceHandler->userHandler()->addPolicy($roleId, $policy); |
|
| 455 | ||
| 456 | $this->cache->invalidateTags(['role-' . $roleId]); |
|
| 457 | ||
| 458 | return $return; |
|
| 459 | } |
|
| 460 | ||
| 461 | /** |
|
| 462 | * {@inheritdoc} |
|
| @@ 464-472 (lines=9) @@ | ||
| 461 | /** |
|
| 462 | * {@inheritdoc} |
|
| 463 | */ |
|
| 464 | public function updatePolicy(Policy $policy) |
|
| 465 | { |
|
| 466 | $this->logger->logCall(__METHOD__, array('struct' => $policy)); |
|
| 467 | $return = $this->persistenceHandler->userHandler()->updatePolicy($policy); |
|
| 468 | ||
| 469 | $this->cache->invalidateTags(['policy-' . $policy->id, 'role-' . $policy->roleId]); |
|
| 470 | ||
| 471 | return $return; |
|
| 472 | } |
|
| 473 | ||
| 474 | /** |
|
| 475 | * {@inheritdoc} |
|
| @@ 477-483 (lines=7) @@ | ||
| 474 | /** |
|
| 475 | * {@inheritdoc} |
|
| 476 | */ |
|
| 477 | public function deletePolicy($policyId, $roleId) |
|
| 478 | { |
|
| 479 | $this->logger->logCall(__METHOD__, array('policy' => $policyId)); |
|
| 480 | $this->persistenceHandler->userHandler()->deletePolicy($policyId, $roleId); |
|
| 481 | ||
| 482 | $this->cache->invalidateTags(['policy-' . $policyId, 'role-' . $roleId]); |
|
| 483 | } |
|
| 484 | ||
| 485 | /** |
|
| 486 | * {@inheritdoc} |
|
| @@ 530-538 (lines=9) @@ | ||
| 527 | /** |
|
| 528 | * {@inheritdoc} |
|
| 529 | */ |
|
| 530 | public function removeRoleAssignment($roleAssignmentId) |
|
| 531 | { |
|
| 532 | $this->logger->logCall(__METHOD__, array('assignment' => $roleAssignmentId)); |
|
| 533 | $return = $this->persistenceHandler->userHandler()->removeRoleAssignment($roleAssignmentId); |
|
| 534 | ||
| 535 | $this->cache->invalidateTags(['role-assignment-' . $roleAssignmentId]); |
|
| 536 | ||
| 537 | return $return; |
|
| 538 | } |
|
| 539 | } |
|
| 540 | ||
| @@ 222-230 (lines=9) @@ | ||
| 219 | /** |
|
| 220 | * {@inheritdoc} |
|
| 221 | */ |
|
| 222 | public function move($sourceId, $destinationParentId) |
|
| 223 | { |
|
| 224 | $this->logger->logCall(__METHOD__, array('source' => $sourceId, 'destination' => $destinationParentId)); |
|
| 225 | $return = $this->persistenceHandler->locationHandler()->move($sourceId, $destinationParentId); |
|
| 226 | ||
| 227 | $this->cache->invalidateTags(['location-path-' . $sourceId]); |
|
| 228 | ||
| 229 | return $return; |
|
| 230 | } |
|
| 231 | ||
| 232 | /** |
|
| 233 | * {@inheritdoc} |
|
| @@ 244-252 (lines=9) @@ | ||
| 241 | /** |
|
| 242 | * {@inheritdoc} |
|
| 243 | */ |
|
| 244 | public function hide($locationId) |
|
| 245 | { |
|
| 246 | $this->logger->logCall(__METHOD__, array('location' => $locationId)); |
|
| 247 | $return = $this->persistenceHandler->locationHandler()->hide($locationId); |
|
| 248 | ||
| 249 | $this->cache->invalidateTags(['location-path-data-' . $locationId]); |
|
| 250 | ||
| 251 | return $return; |
|
| 252 | } |
|
| 253 | ||
| 254 | /** |
|
| 255 | * {@inheritdoc} |
|