Source of file BetterButtonCancelAction.php
Size: 0,915 Bytes - Last Modified: 2021-12-23T10:56:01+00:00
/var/www/docs.ssmods.com/process/src/src/Actions/BetterButtonCancelAction.php
12345678910111213141516171819202122232425262728293031323334353637383940414243 | <?php namespace UncleCheese\BetterButtons\Actions; use UncleCheese\BetterButtons\Actions\BetterButtonAction; /** * Defines a button that cancels out of the form * * @author Uncle Cheese <unclecheese@leftandmain.com> * @package silverstripe-gridfield-betterbuttons */ class BetterButtonCancelAction extends BetterButtonAction { /** * Builds the button */ public function __construct() { parent::__construct(_t('GridFieldBetterButtons.CANCEL', 'Cancel')); } /** * Gets the link for the button * @return string */ public function getButtonLink() { return $this->gridFieldRequest->Link("cancel"); } /** * Gets the HTML that represents the button * @return string */ public function getButtonHTML() { $this->addExtraClass("btn btn-default backlink"); return parent::getButtonHTML(); } } |