Skip to content
Snippets Groups Projects
Commit f1fd0708 authored by Dries Buytaert's avatar Dries Buytaert
Browse files

Issue #1923512 by damiankloip: Remove view edit message to discard a view.

parent 957b5564
No related branches found
No related tags found
No related merge requests found
......@@ -41,7 +41,7 @@ public function testCacheData() {
$this->drupalGet('admin/structure/views/view/test_view/edit');
// Make sure we have 'changes' to the view.
$this->drupalPost('admin/structure/views/nojs/display/test_view/default/title', array(), t('Apply'));
$this->assertText('* All changes are stored temporarily. Click Save to make your changes permanent. Click Cancel to discard your changes.', 'The view has been changed.');
$this->assertText('All changes are stored temporarily.', 'The view has been changed.');
$view_cache = $temp_store->get('test_view');
// The view should be enabled.
......
......@@ -96,17 +96,10 @@ public function form(array $form, array &$form_state, EntityInterface $view) {
);
}
else {
if (isset($view->vid) && $view->vid == 'new') {
$message = t('* All changes are stored temporarily. Click Save to make your changes permanent. Click Cancel to discard the view.');
}
else {
$message = t('* All changes are stored temporarily. Click Save to make your changes permanent. Click Cancel to discard your changes.');
}
$form['changed'] = array(
'#type' => 'container',
'#attributes' => array('class' => array('view-changed', 'messages', 'warning')),
'#children' => $message,
'#children' => t('All changes are stored temporarily. Click "Save" to make your changes permanent. Click "Cancel" to discard your changes.'),
'#weight' => -10,
);
if (empty($view->changed)) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment