LeKoala\CmsActions\CustomAction
Custom actions to use in getCMSActions
Actions handlers are declared on the DataObject itself
Because it is an action, it will be submitted through ajax
If you want to create links that open files or show a new page, use CustomLink
Synopsis
class CustomAction
extends FormAction
{
- // members
- public boolean $useButtonTag = true;
- protected boolean $shouldRefresh = false;
- // methods
- public void __construct()
- public void actionName()
- public void Type()
- public void Field()
- public mixed getShouldRefresh()
- public $this setShouldRefresh()
- // Inherited methods from CustomButton
- public string getTitle()
- public $this setTitle()
- public bool getDropUp()
- public $this setDropUp()
- public void setButtonType()
- protected string getButtonTitle()
- public string getButtonIcon()
- public $this setButtonIcon()
- public void getConfirmation()
- public $this setConfirmation()
Hierarchy
Members
protected
- $confirmation
—
string
The confirmation message - $dropUp
—
LeKoala\CmsActions\bool
Whether to place the button in a dot-menu - $shouldRefresh
—
boolean
Used in ActionsGridFieldItemRequest::forwardActionToRecord
public
- $useButtonTag — boolean
Methods
public
- __construct()
- Field()
- Type()
- actionName()
- getShouldRefresh() — Get the value of shouldRefresh
- setShouldRefresh() — Set the value of shouldRefresh
Inherited from LeKoala\CmsActions\CustomButton
protected
- getButtonTitle() — Get the title with icon if set
public
- getButtonIcon() — Get an icon for this button
- getConfirmation() — Get the value of confirmation
- getDropUp() — Get the dropUp value Called by ActionsGridFieldItemRequest to determine placement
- getTitle() — Get the title of the link Called by ActionsGridFieldItemRequest to build default message
- setButtonIcon() — Set an icon for this button
- setButtonType()
- setConfirmation() — Set the value of confirmation
- setDropUp() — Set the value of dropUp
- setTitle() — Set the value of title