Skip to content
Snippets Groups Projects

Issue #3497021: Removed getFormName()

4 unresolved threads

Closes #3497021

Merge request reports

Members who can merge are allowed to add commits.
Approval is optional
Code Quality is loading
Test summary results are being parsed
Ready to merge by members who can write to the target branch.
  • The source branch is 486 commits behind the target branch.
  • 1 commit will be added to 11.x.
  • Source branch will not be deleted.

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
59 59 * {@inheritdoc}
60 60 */
61 61 public function submitForm(array &$form, FormStateInterface $form_state) {
62 if ($form['confirm']) {
63 // Ask each active search page to mark itself for re-index.
64 $search_page_repository = \Drupal::service('search.search_page_repository');
65 foreach ($search_page_repository->getIndexableSearchPages() as $entity) {
66 $entity->getPlugin()->markForReindex();
67 }
68 $this->messenger()->addStatus($this->t('All search indexes will be rebuilt.'));
69 $form_state->setRedirectUrl($this->getCancelUrl());
62 // Ask each active search page to mark itself for re-index.
  • 211 $admin_form_mock = [];
    212 $admin_form_state = $form_state;
    213 $admin_form_state->unsetValue('user_cancel_confirm');
    214 // The $user global is not a complete user entity, so load the full
    215 // entity.
    216 $account = $this->userStorage->load($uid);
    217 $admin_form = $this->entityTypeManager->getFormObject('user', 'cancel');
    218 $admin_form->setEntity($account);
    219 // Calling this directly required to init form object with $account.
    220 $admin_form->buildForm($admin_form_mock, $admin_form_state);
    221 $admin_form->submitForm($admin_form_mock, $admin_form_state);
    222 }
    223 else {
    224 user_cancel($form_state->getValues(), $uid, $form_state->getValue('user_cancel_method'));
    225 }
    203 foreach ($form_state->getValue('accounts') as $uid => $value) {
  • added 3 commits

    • 8fc5771e...b23f4270 - 2 commits from branch project:11.x
    • 66aac499 - Merge branch drupal:11.x into 3497021-confirmforminterfacegetformname-serves-no

    Compare with previous version

  • added 1 commit

    • 404a2a86 - Issue #3497021: ConfirmFormInterface::getFormName() serves no purpose in ConfirmFormBase

    Compare with previous version

  • godotislate added 24 commits

    added 24 commits

    Compare with previous version

  • Arun Sahijpal added 53 commits

    added 53 commits

    • 40dd3cc0...6dd918c9 - 52 commits from branch project:11.x
    • 451212c1 - Merge branch '11.x' into '3497021-confirmforminterfacegetformname-serves-no'

    Compare with previous version

  • 40 40 }
    41 41
    42 42 /**
    43 * {@inheritdoc}
    43 * Returns the internal name used to refer to the confirmation item.
    44 *
    45 * @return string
    46 * The internal form name.
    44 47 */
    45 48 public function getFormName() {
    49 @trigger_error('ConfirmFormBase::getFormName() is deprecated in drupal:11.2.0 and will be removed in drupal:12.0.0. Implementations should remove this method. See https://www.drupal.org/node/3505037', E_USER_DEPRECATED);
  • 42 42 }
    43 43
    44 44 /**
    45 * {@inheritdoc}
    45 * Returns the internal name used to refer to the confirmation item.
    46 *
    47 * @return string
    48 * The internal form name.
    46 49 */
    47 50 public function getFormName() {
    51 @trigger_error('ConfirmFormBase::getFormName() is deprecated in drupal:11.2.0 and will be removed in drupal:12.0.0. Implementations should remove this method. See https://www.drupal.org/node/3505037', E_USER_DEPRECATED);
  • Arun Sahijpal added 1 commit

    added 1 commit

    Compare with previous version

  • Please register or sign in to reply
    Loading