Issue #2119881 by damiankloip, dawehner | joachim: Fixed views BulkFormBase shows 'Apply' button twice.

8.0.x
webchick 2013-10-30 17:03:21 -07:00
parent 4399709181
commit e0d8e66bf4
2 changed files with 7 additions and 2 deletions

View File

@ -49,6 +49,10 @@ class BulkFormTest extends WebTestBase {
$this->drupalGet('test_bulk_form');
// Test that the views edit header appears first.
$first_form_element = $this->xpath('//form/div/div[1][@id = :id]', array(':id' => 'edit-header'));
$this->assertTrue($first_form_element, 'The views form edit header appears first.');
$this->assertFieldById('edit-action', NULL, 'The action select field appears.');
// Make sure a checkbox appears on all rows.

View File

@ -1234,8 +1234,9 @@ function views_pre_render_views_form_views_form($element) {
// Apply substitutions to the rendered output.
$element['output']['#markup'] = str_replace($search, $replace, $element['output']['#markup']);
// Render and add remaining form fields.
$element['#children'] = drupal_render_children($element);
// Sort, render and add remaining form fields.
$children = element_children($element, TRUE);
$element['#children'] = drupal_render_children($element, $children);
return $element;
}