/**
  * Updates the button to be disabled if there is no previous record
  * @return FormAction
  */
 public function baseTransform()
 {
     parent::baseTransform();
     $disabled = !$this->gridFieldRequest->getPreviousRecordID();
     return $this->setDisabled($disabled);
 }
 /**
  * Adds a class to identify this as a destructive action
  * @return void
  */
 public function baseTransform()
 {
     parent::baseTransform();
     return $this->addExtraClass('ss-ui-action-destructive');
 }
 /**
  * Add the necessary classes and icons
  * @return FormAction
  */
 public function baseTransform()
 {
     parent::baseTransform();
     return $this->addExtraClass("ss-ui-action-constructive")->setAttribute('data-icon', 'add');
 }
 /**
  * Updates the button to use appropriate icons
  * @return FormAction
  */
 public function baseTransform()
 {
     parent::baseTransform();
     return $this->setAttribute('data-icon', 'accept')->setAttribute('data-icon-alternate', 'disk')->setAttribute('data-text-alternate', _t('SiteTree.BUTTONSAVEPUBLISH', 'Save & publish'));
 }
 /**
  * Adds the JS, sets up necessary HTML attributes
  * @return FormAction
  */
 public function baseTransform()
 {
     parent::baseTransform();
     Requirements::javascript(BETTER_BUTTONS_DIR . '/javascript/gridfield_betterbuttons_delete.js');
     return $this->setUseButtonTag(true)->addExtraClass('gridfield-better-buttons-delete')->setAttribute("data-toggletext", _t('GridFieldBetterButtons.AREYOUSURE', 'Yes. Delete this item.'))->setAttribute("data-confirmtext", _t('GridFieldDetailForm.CANCELDELETE', 'No. Don\'t delete.'));
 }
 /**
  * Updates the button to have the correct style and icon
  * @return FormAction
  */
 public function baseTransform()
 {
     parent::baseTransform();
     return $this->setAttribute('data-icon', 'accept')->setAttribute('data-icon-alternate', 'addpage')->setAttribute('data-text-alternate', _t('CMSMain.SAVEDRAFT', 'Save draft'));
 }
 /**
  * Update the button to show a description
  * @return [type] [description]
  */
 public function baseTransform()
 {
     parent::baseTransform();
     return $this->setDescription(_t('SiteTree.BUTTONCANCELDRAFTDESC', 'Delete your draft and revert to the currently published page'));
 }