Skip to content
Snippets Groups Projects
Commit 8f9ece97 authored by Alex Pott's avatar Alex Pott
Browse files

Issue #1949032 by irfworld, geertvd, dawehner: Add a message when a view saved...

Issue #1949032 by irfworld, geertvd, dawehner: Add a message when a view saved during wizard creation
parent 151da1a2
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
...@@ -158,6 +158,7 @@ function testViewsWizardAndListing() { ...@@ -158,6 +158,7 @@ function testViewsWizardAndListing() {
$view4['rest_export[create]'] = 1; $view4['rest_export[create]'] = 1;
$view4['rest_export[path]'] = $this->randomMachineName(16); $view4['rest_export[path]'] = $this->randomMachineName(16);
$this->drupalPostForm('admin/structure/views/add', $view4, t('Save and edit')); $this->drupalPostForm('admin/structure/views/add', $view4, t('Save and edit'));
$this->assertRaw(t('The view %view has been saved.', array('%view' => $view4['label'])));
// Check that the REST export path works. // Check that the REST export path works.
$this->drupalGet($view4['rest_export[path]']); $this->drupalGet($view4['rest_export[path]']);
......
...@@ -192,7 +192,7 @@ public function submitForm(array &$form, FormStateInterface $form_state) { ...@@ -192,7 +192,7 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
return; return;
} }
$this->entity->save(); $this->entity->save();
drupal_set_message($this->t('The view %name has been saved.', array('%name' => $form_state->getValue('label'))));
$form_state->setRedirectUrl($this->entity->urlInfo('edit-form')); $form_state->setRedirectUrl($this->entity->urlInfo('edit-form'));
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment