TYPO3CMS  8
 All Classes Namespaces Files Functions Variables Pages
HelpButton Class Reference
Inheritance diagram for HelpButton:
ButtonInterface PositionInterface

Public Member Functions

 getModuleName ()
 
 setModuleName ($moduleName)
 
 getFieldName ()
 
 setFieldName ($fieldName)
 
 getPosition ()
 
 getGroup ()
 
 getType ()
 
 isValid ()
 
 __toString ()
 
 render ()
 

Protected Attributes

 $moduleName
 
 $fieldName = ''
 

Detailed Description

HelpButton

Renders a help button in the DocHeader which will be rendered to the right position using button group "99".

EXAMPLE USAGE TO ADD A HELP BUTTON:

$buttonBar = $this->moduleTemplate->getDocHeaderComponent()->getButtonBar(); $myButton = $buttonBar->makeHelpButton() ->setModuleName('xMOD_csh_corebe') ->setFieldName('list_module'); $buttonBar->addButton($myButton);

Definition at line 36 of file HelpButton.php.

Member Function Documentation

__toString ( )

Renders the button

Returns
string

Implements ButtonInterface.

Definition at line 138 of file HelpButton.php.

References HelpButton\render().

getFieldName ( )

Gets the name of the field.

Returns
string

Definition at line 75 of file HelpButton.php.

References HelpButton\$fieldName.

getGroup ( )

Gets the button group.

Returns
int

Implements PositionInterface.

Definition at line 107 of file HelpButton.php.

getModuleName ( )

Gets the name of the module.

Returns
string

Definition at line 53 of file HelpButton.php.

References HelpButton\$moduleName.

getPosition ( )

Gets the button position.

Returns
string

Implements PositionInterface.

Definition at line 97 of file HelpButton.php.

References ButtonBar\BUTTON_POSITION_RIGHT.

getType ( )

Gets the type of the button

Returns
string

Implements ButtonInterface.

Definition at line 117 of file HelpButton.php.

isValid ( )

Determines whether the button shall be rendered. Depends on the defined module and field name.

Returns
bool

Implements ButtonInterface.

Definition at line 128 of file HelpButton.php.

render ( )

Renders the button

Returns
string

Implements ButtonInterface.

Definition at line 148 of file HelpButton.php.

References BackendUtility\cshItem().

Referenced by HelpButton\__toString().

setFieldName (   $fieldName)

Sets the name of the field.

Parameters
string$fieldName
Returns
HelpButton

Definition at line 86 of file HelpButton.php.

References HelpButton\$fieldName.

setModuleName (   $moduleName)

Sets the name of the module.

Parameters
string$moduleName
Returns
HelpButton

Definition at line 64 of file HelpButton.php.

References HelpButton\$moduleName.

Member Data Documentation

$fieldName = ''
protected

Definition at line 46 of file HelpButton.php.

Referenced by HelpButton\getFieldName(), and HelpButton\setFieldName().

$moduleName
protected

Definition at line 41 of file HelpButton.php.

Referenced by HelpButton\getModuleName(), and HelpButton\setModuleName().