ContentEntityForm::copyFormValuesToEntity

protected ContentEntityForm::copyFormValuesToEntity(EntityInterface $entity, array $form, FormStateInterface $form_state) Copies top-level form values to entity properties This should not change existing entity properties that are not being edited by this form. Parameters \Drupal\Core\Entity\EntityInterface $entity: The entity the current form should operate upon. array $form: A nested array of form elements comprising the form. \Drupal\Core\Form\FormStateInterface $form_state: The current sta

ContentEntityForm::buildEntity

public ContentEntityForm::buildEntity(array $form, FormStateInterface $form_state) Builds an updated entity object based upon the submitted form values. For building the updated entity object the form's entity is cloned and the submitted form values are copied to entity properties. The form's entity remains unchanged. Parameters array $form: A nested array form elements comprising the form. \Drupal\Core\Form\FormStateInterface $form_state: The current state of the form. Return value \Drupal\C

ContentEntityForm::$entityManager

The entity manager. Type: \Drupal\Core\Entity\EntityManagerInterface Overrides EntityForm::$entityManager File core/lib/Drupal/Core/Entity/ContentEntityForm.php, line 22 Class ContentEntityForm Entity form variant for content entity types. Namespace Drupal\Core\Entity Code protected $entityManager;

ContentEntityForm

Entity form variant for content entity types. Hierarchy class \Drupal\Core\Form\FormBase implements ContainerInjectionInterface, FormInterface uses DependencySerializationTrait, LoggerChannelTrait, LinkGeneratorTrait, RedirectDestinationTrait, UrlGeneratorTrait, StringTranslationTraitclass \Drupal\Core\Entity\EntityForm implements EntityFormInterfaceclass \Drupal\Core\Entity\ContentEntityForm implements ContentEntityFormInterface See also \Drupal\Core\ContentEntityBase File core/lib/Drupa

ContentEntityDeleteForm::submitForm

public ContentEntityDeleteForm::submitForm(array &$form, FormStateInterface $form_state) This is the default entity object builder function. It is called before any other submit handler to build the new entity object to be used by the following submit handlers. At this point of the form workflow the entity is validated and the form state can be updated, this way the subsequently invoked handlers can retrieve a regular entity object to act on. Generally this method should not be overridden

ContentEntityDeleteForm::logDeletionMessage

protected ContentEntityDeleteForm::logDeletionMessage() File core/lib/Drupal/Core/Entity/ContentEntityDeleteForm.php, line 108 Class ContentEntityDeleteForm Provides a generic base class for a content entity deletion form. Namespace Drupal\Core\Entity Code protected function logDeletionMessage() { /** @var \Drupal\Core\Entity\ContentEntityInterface $entity */ $entity = $this->getEntity(); if (!$entity->isDefaultTranslation()) { $this->logger($entity->getEntityTyp

ContentEntityDeleteForm::getQuestion

public ContentEntityDeleteForm::getQuestion() Returns the question to ask the user. Return value string The form question. The page title will be set to this value. Overrides ConfirmFormInterface::getQuestion File core/lib/Drupal/Core/Entity/ContentEntityDeleteForm.php, line 127 Class ContentEntityDeleteForm Provides a generic base class for a content entity deletion form. Namespace Drupal\Core\Entity Code public function getQuestion() { /** @var \Drupal\Core\Entity\ContentEntityInt

ContentEntityDeleteForm::getDeletionMessage

protected ContentEntityDeleteForm::getDeletionMessage() File core/lib/Drupal/Core/Entity/ContentEntityDeleteForm.php, line 90 Class ContentEntityDeleteForm Provides a generic base class for a content entity deletion form. Namespace Drupal\Core\Entity Code protected function getDeletionMessage() { /** @var \Drupal\Core\Entity\ContentEntityInterface $entity */ $entity = $this->getEntity(); if (!$entity->isDefaultTranslation()) { return $this->t('The @entity-type %labe

ContentEntityDeleteForm::getCancelUrl

public ContentEntityDeleteForm::getCancelUrl() Returns the route to go to if the user cancels the action. Return value \Drupal\Core\Url A URL object. Overrides ConfirmFormInterface::getCancelUrl File core/lib/Drupal/Core/Entity/ContentEntityDeleteForm.php, line 81 Class ContentEntityDeleteForm Provides a generic base class for a content entity deletion form. Namespace Drupal\Core\Entity Code public function getCancelUrl() { /** @var \Drupal\Core\Entity\ContentEntityInterface $entity

ContentEntityDeleteForm::buildForm

public ContentEntityDeleteForm::buildForm(array $form, FormStateInterface $form_state) Form constructor. Parameters array $form: An associative array containing the structure of the form. \Drupal\Core\Form\FormStateInterface $form_state: The current state of the form. Return value array The form structure. Overrides ContentEntityConfirmFormBase::buildForm File core/lib/Drupal/Core/Entity/ContentEntityDeleteForm.php, line 25 Class ContentEntityDeleteForm Provides a generic base class for