public function ConsentAgreementController::revisionShow in General Data Protection Regulation 8
Same name and namespace in other branches
- 8.2 modules/gdpr_consent/src/Controller/ConsentAgreementController.php \Drupal\gdpr_consent\Controller\ConsentAgreementController::revisionShow()
- 3.0.x modules/gdpr_consent/src/Controller/ConsentAgreementController.php \Drupal\gdpr_consent\Controller\ConsentAgreementController::revisionShow()
Displays a Consent Agreement revision.
Parameters
int $gdpr_consent_agreement_revision: The Consent Agreement revision ID.
Return value
array An array suitable for drupal_render().
Throws
\Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
File
- modules/
gdpr_consent/ src/ Controller/ ConsentAgreementController.php, line 87
Class
- ConsentAgreementController
- Class ConsentAgreementController.
Namespace
Drupal\gdpr_consent\ControllerCode
public function revisionShow($gdpr_consent_agreement_revision) {
$gdprConsentAgreement = $this->entityTypeManager
->getStorage('gdpr_consent_agreement')
->loadRevision($gdpr_consent_agreement_revision);
$viewBuilder = $this->entityTypeManager
->getViewBuilder('gdpr_consent_agreement');
return $viewBuilder
->view($gdprConsentAgreement);
}