summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxjm2016-07-19 10:54:39 +0200
committerxjm2016-07-19 10:54:39 +0200
commit978b026958049a1ebd94aeb1540489279c23aec5 (patch)
tree5b44d1dead9e02ab8868bb807e553fb823a47058
parentfaef09eaef8b8138efdc50fffc125fc9e0291de8 (diff)
Issue #2752915 by mohit_aghera, davic, Haza, pashupathi nath gajawada, chr.fritsch, ifrik, webchick, j2r: Rename "Add page" to "Add search page"
-rw-r--r--core/modules/search/src/Form/SearchPageAddForm.php2
-rw-r--r--core/modules/search/src/SearchPageListBuilder.php2
-rw-r--r--core/modules/search/src/Tests/SearchConfigSettingsFormTest.php10
3 files changed, 7 insertions, 7 deletions
diff --git a/core/modules/search/src/Form/SearchPageAddForm.php b/core/modules/search/src/Form/SearchPageAddForm.php
index 7202502..a97f1fa 100644
--- a/core/modules/search/src/Form/SearchPageAddForm.php
+++ b/core/modules/search/src/Form/SearchPageAddForm.php
@@ -24,7 +24,7 @@ class SearchPageAddForm extends SearchPageFormBase {
*/
protected function actions(array $form, FormStateInterface $form_state) {
$actions = parent::actions($form, $form_state);
- $actions['submit']['#value'] = $this->t('Add search page');
+ $actions['submit']['#value'] = $this->t('Save');
return $actions;
}
diff --git a/core/modules/search/src/SearchPageListBuilder.php b/core/modules/search/src/SearchPageListBuilder.php
index afbf54c..c76a999 100644
--- a/core/modules/search/src/SearchPageListBuilder.php
+++ b/core/modules/search/src/SearchPageListBuilder.php
@@ -269,7 +269,7 @@ class SearchPageListBuilder extends DraggableListBuilder implements FormInterfac
);
$form['search_pages']['add_page']['add_search_submit'] = array(
'#type' => 'submit',
- '#value' => $this->t('Add new page'),
+ '#value' => $this->t('Add search page'),
'#validate' => array('::validateAddSearchPage'),
'#submit' => array('::submitAddSearchPage'),
'#limit_validation_errors' => array(array('search_type')),
diff --git a/core/modules/search/src/Tests/SearchConfigSettingsFormTest.php b/core/modules/search/src/Tests/SearchConfigSettingsFormTest.php
index c458b16..9ca87d6 100644
--- a/core/modules/search/src/Tests/SearchConfigSettingsFormTest.php
+++ b/core/modules/search/src/Tests/SearchConfigSettingsFormTest.php
@@ -237,26 +237,26 @@ class SearchConfigSettingsFormTest extends SearchTestBase {
// Add a search page.
$edit = array();
$edit['search_type'] = 'search_extra_type_search';
- $this->drupalPostForm(NULL, $edit, t('Add new page'));
+ $this->drupalPostForm(NULL, $edit, t('Add search page'));
$this->assertTitle('Add new search page | Drupal');
$first = array();
$first['label'] = $this->randomString();
$first_id = $first['id'] = strtolower($this->randomMachineName(8));
$first['path'] = strtolower($this->randomMachineName(8));
- $this->drupalPostForm(NULL, $first, t('Add search page'));
+ $this->drupalPostForm(NULL, $first, t('Save'));
$this->assertDefaultSearch($first_id, 'The default page matches the only search page.');
$this->assertRaw(t('The %label search page has been added.', array('%label' => $first['label'])));
// Attempt to add a search page with an existing path.
$edit = array();
$edit['search_type'] = 'search_extra_type_search';
- $this->drupalPostForm(NULL, $edit, t('Add new page'));
+ $this->drupalPostForm(NULL, $edit, t('Add search page'));
$edit = array();
$edit['label'] = $this->randomString();
$edit['id'] = strtolower($this->randomMachineName(8));
$edit['path'] = $first['path'];
- $this->drupalPostForm(NULL, $edit, t('Add search page'));
+ $this->drupalPostForm(NULL, $edit, t('Save'));
$this->assertText(t('The search page path must be unique.'));
// Add a second search page.
@@ -264,7 +264,7 @@ class SearchConfigSettingsFormTest extends SearchTestBase {
$second['label'] = $this->randomString();
$second_id = $second['id'] = strtolower($this->randomMachineName(8));
$second['path'] = strtolower($this->randomMachineName(8));
- $this->drupalPostForm(NULL, $second, t('Add search page'));
+ $this->drupalPostForm(NULL, $second, t('Save'));
$this->assertDefaultSearch($first_id, 'The default page matches the only search page.');
// Ensure both search pages have their tabs displayed.