diff --git a/admin/code/ModelAdmin.php b/admin/code/ModelAdmin.php index 9c6bfec09..3dfcc2d73 100644 --- a/admin/code/ModelAdmin.php +++ b/admin/code/ModelAdmin.php @@ -115,7 +115,7 @@ abstract class ModelAdmin extends LeftAndMain { function getEditForm($id = null) { $list = $this->getList(); - $exportButton = new GridFieldExportButton(); + $exportButton = new GridFieldExportButton('before'); $exportButton->setExportColumns($this->getExportFields()); $listField = Object::create('GridField', $this->modelClass, @@ -124,7 +124,7 @@ abstract class ModelAdmin extends LeftAndMain { $fieldConfig = GridFieldConfig_RecordEditor::create($this->stat('page_length')) ->addComponent($exportButton) ->removeComponentsByType('GridFieldFilterHeader') - ->addComponents(new GridFieldPrintButton()) + ->addComponents(new GridFieldPrintButton('before')) ); // Validation diff --git a/forms/gridfield/GridFieldPrintButton.php b/forms/gridfield/GridFieldPrintButton.php index 748ef9ef9..d4fcc4483 100644 --- a/forms/gridfield/GridFieldPrintButton.php +++ b/forms/gridfield/GridFieldPrintButton.php @@ -52,7 +52,7 @@ class GridFieldPrintButton implements GridField_HTMLProvider, GridField_ActionPr $button->addExtraClass('gridfield-button-print'); //$button->addExtraClass('no-ajax'); return array( - $this->targetFragment => '
', + $this->targetFragment => ' ', ); } diff --git a/security/Group.php b/security/Group.php index 4e1b78f78..69acefab9 100755 --- a/security/Group.php +++ b/security/Group.php @@ -96,8 +96,8 @@ class Group extends DataObject { if($this->ID) { $config = new GridFieldConfig_RelationEditor(); - $config->addComponents(new GridFieldExportButton()); - $config->addComponents(new GridFieldPrintButton()); + $config->addComponents(new GridFieldExportButton('before')); + $config->addComponents(new GridFieldPrintButton('before')); $config->getComponentByType('GridFieldAddExistingAutocompleter') ->setResultsFormat('$Title ($Email)')->setSearchFields(array('FirstName', 'Surname', 'Email')); $config->getComponentByType('GridFieldDetailForm')->setValidator(new Member_Validator());