protected function SocialAlbumPostForm::actionsElement in Open Social 10.1.x
Same name and namespace in other branches
- 10.3.x modules/social_features/social_album/src/Form/SocialAlbumPostForm.php \Drupal\social_album\Form\SocialAlbumPostForm::actionsElement()
- 10.0.x modules/social_features/social_album/src/Form/SocialAlbumPostForm.php \Drupal\social_album\Form\SocialAlbumPostForm::actionsElement()
- 10.2.x modules/social_features/social_album/src/Form/SocialAlbumPostForm.php \Drupal\social_album\Form\SocialAlbumPostForm::actionsElement()
Returns the action form element for the current entity form.
Overrides EntityForm::actionsElement
File
- modules/
social_features/ social_album/ src/ Form/ SocialAlbumPostForm.php, line 71
Class
- SocialAlbumPostForm
- Provides form for creating a post in an album.
Namespace
Drupal\social_album\FormCode
protected function actionsElement(array $form, FormStateInterface $form_state) {
$element = parent::actionsElement($form, $form_state);
if ($this->node) {
$element['cancel'] = $this->node
->toLink($this
->t('Go to album'))
->toRenderable();
}
return $element;
}