Contentserv PHP API

CSGuiPopup
in package

Derived sample class to demonstrate coding style rules

Tags
since

CS13.0.0

Table of Contents

GROUP_IDENTIFIER_ACTIONS  = 'Actions'
GROUP_IDENTIFIER_BEHAVIOUR  = 'Behaviour'
GROUP_IDENTIFIER_EXPORT_IMPORT  = 'ExportImport'
GROUP_IDENTIFIER_HELP  = 'Help'
The default group identifier, which are used in the default popups.
GROUP_IDENTIFIER_OBJECT  = 'Object'
GROUP_IDENTIFIER_PROCESS  = 'Process'
GROUP_IDENTIFIER_SUBMENU  = 'Submenu'
GROUP_INDEX_ACTIONS  = 40
GROUP_INDEX_BEHAVIOUR  = 5
GROUP_INDEX_EXPORT_IMPORT  = 10
GROUP_INDEX_HELP  = 0
The default group indexes, which are used in the default popups.
GROUP_INDEX_OBJECT  = 20
GROUP_INDEX_PROCESS  = 30
GROUP_INDEX_SUBMENU  = 999
$debugMode  : mixed
$hasPopup  : mixed
$items  : mixed
$popup  : Popup
addCheckboxItem()  : void
Adds a checkbox popup item to the end of the current component's popup
addHelpItems()  : mixed
addItem()  : void
Adds a popup item to the end of the current component's popup
addSeparator()  : mixed
addSubMenuDefinition()  : void
Adds a definition (Icon, GroupIdentifier, GroupIndex) for a sub menu entry.
enableDebugMode()  : mixed
evaluateCode()  : mixed
getPopup()  : mixed
hasPopup()  : mixed
insertItem()  : void
Adds a popup item into a specified location of the current component's popup
makeHtml()  : mixed
removeAllItems()  : mixed
removeItem()  : mixed
removeItemsByNamespace()  : mixed
setCharset()  : mixed
setDefaultPopup()  : mixed
setPopupVisible()  : mixed
useDefaultItem()  : mixed

Constants

GROUP_IDENTIFIER_ACTIONS

public mixed GROUP_IDENTIFIER_ACTIONS = 'Actions'
Tags

GROUP_IDENTIFIER_BEHAVIOUR

public mixed GROUP_IDENTIFIER_BEHAVIOUR = 'Behaviour'
Tags

GROUP_IDENTIFIER_EXPORT_IMPORT

public mixed GROUP_IDENTIFIER_EXPORT_IMPORT = 'ExportImport'
Tags

GROUP_IDENTIFIER_HELP

The default group identifier, which are used in the default popups.

public string GROUP_IDENTIFIER_HELP = 'Help'
Tags

GROUP_IDENTIFIER_OBJECT

public mixed GROUP_IDENTIFIER_OBJECT = 'Object'
Tags

GROUP_IDENTIFIER_PROCESS

public mixed GROUP_IDENTIFIER_PROCESS = 'Process'
Tags

GROUP_IDENTIFIER_SUBMENU

public mixed GROUP_IDENTIFIER_SUBMENU = 'Submenu'
Tags

GROUP_INDEX_ACTIONS

public mixed GROUP_INDEX_ACTIONS = 40
Tags

GROUP_INDEX_BEHAVIOUR

public mixed GROUP_INDEX_BEHAVIOUR = 5
Tags

GROUP_INDEX_EXPORT_IMPORT

public mixed GROUP_INDEX_EXPORT_IMPORT = 10
Tags

GROUP_INDEX_HELP

The default group indexes, which are used in the default popups.

public string GROUP_INDEX_HELP = 0
Tags

GROUP_INDEX_OBJECT

public mixed GROUP_INDEX_OBJECT = 20
Tags

GROUP_INDEX_PROCESS

public mixed GROUP_INDEX_PROCESS = 30
Tags

GROUP_INDEX_SUBMENU

public mixed GROUP_INDEX_SUBMENU = 999
Tags

Properties

$debugMode

public mixed $debugMode = \false
Tags
access

private

$hasPopup

public mixed $hasPopup = \null
Tags
access

private

$items

public mixed $items = array()
Tags
access

private

$popup

public Popup $popup = \null
Tags
access

private

Methods

addCheckboxItem()

Adds a checkbox popup item to the end of the current component's popup

public addCheckboxItem(string $sLabel, string $sJavascript[, bool $bIsEnabled = true ][, bool $bIsSelected = false ][, string $sAccessKey = '' ][, bool $bEvalCondition = true ][, array<string|int, mixed>|string $mNamespaces = array() ][, string $sGroupIdentifier = '' ], int $iGroupIndex) : void
Parameters
$sLabel : string

label of the popup item. It can use '//' to create a submenu, e.g. 'submenu_label//sub_submenu_label//label'

$sJavascript : string

Javascript code to call with the popup item

$bIsEnabled : bool = true

can be false if the popup item should be visible but disabled

$bIsSelected : bool = false

whether the checkbox should be selected

$sAccessKey : string = ''

Keyboard access key of the popup item

$bEvalCondition : bool = true

If the condition should be evaluated.

$mNamespaces : array<string|int, mixed>|string = array()

The namespace for the button like "workflow"

$sGroupIdentifier : string = ''

The identifier to add the popup item to a group, which has separator at the beginning and at the end.

$iGroupIndex : int

The index of the group. The index will be used to order the groups. The lowest index will be taken of all popup items inside of a group.

Tags
access

public

Return values
void

addHelpItems()

public addHelpItems([mixed $module = null ][, mixed $evalCondition = true ]) : mixed
Parameters
$module : mixed = null
$evalCondition : mixed = true
Tags
Return values
mixed

addItem()

Adds a popup item to the end of the current component's popup

public addItem(string $sLabel, string $sJavascript[, int $bIsEnabled = true ][, string $sIconPath = '' ][, string $sAccessKey = '' ][, bool $bEvalCondition = true ][, array<string|int, mixed>|string $mNamespaces = array() ][, string $sGroupIdentifier = '' ], int $iGroupIndex) : void
Parameters
$sLabel : string

label of the popup item. It can use '//' to create a submenu, e.g. 'submenu_label//sub_submenu_label//label'

$sJavascript : string

Javascript code to call with the popup item

$bIsEnabled : int = true

can be false if the popup item should be visible but disabled

$sIconPath : string = ''

Image of the item relative to the admin/images/popup/ directory

$sAccessKey : string = ''

Keyboard access key of the popup item

$bEvalCondition : bool = true

If the condition should be evaluated.

$mNamespaces : array<string|int, mixed>|string = array()

The namespace for the button like "workflow"

$sGroupIdentifier : string = ''

The identifier to add the popup item to a group, which has separator at the beginning and at the end.

$iGroupIndex : int

The index of the group. The index will be used to order the groups. The lowest index will be taken of all popup items inside of a group.

Tags
access

public

Return values
void

addSeparator()

public addSeparator([mixed $mEvalCondition = true ][, mixed $sSubMenu = '' ]) : mixed
Parameters
$mEvalCondition : mixed = true
$sSubMenu : mixed = ''
Tags
access

private

Return values
mixed

addSubMenuDefinition()

Adds a definition (Icon, GroupIdentifier, GroupIndex) for a sub menu entry.

public addSubMenuDefinition(string $sSubMenuLabel, string $sIcon[, string $sGroupIdentifier = '' ], int $iGroupIndex[, mixed $bEvalCondition = true ]) : void
Parameters
$sSubMenuLabel : string

The target sub menu label

$sIcon : string

THe icon of the sub menu.

$sGroupIdentifier : string = ''

The group identifier

$iGroupIndex : int

The index of the group.

$bEvalCondition : mixed = true
Tags
Return values
void

enableDebugMode()

public enableDebugMode() : mixed
Tags
access

private

Return values
mixed

evaluateCode()

public evaluateCode(mixed $evalCode) : mixed
Parameters
$evalCode : mixed
Tags
access

private

Return values
mixed

getPopup()

public getPopup(mixed $PopupID) : mixed
Parameters
$PopupID : mixed
Tags
access

private

Return values
mixed

hasPopup()

public hasPopup() : mixed
Tags
access

protected

Return values
mixed

insertItem()

Adds a popup item into a specified location of the current component's popup

public insertItem(string|int $mIndex, string $sLabel, string $sJavascript[, int $bIsEnabled = true ][, string $sIconPath = '' ][, string $sAccessKey = '' ][, bool $bEvalCondition = true ][, array<string|int, mixed>|string $mNamespaces = array() ][, string $sGroupIdentifier = '' ], int $iGroupIndex) : void
Parameters
$mIndex : string|int

index number where the popup item should be inserted

$sLabel : string

label of the popup item. It can use '//' to create a submenu, e.g. 'submenu_label//sub_submenu_label//label'

$sJavascript : string

javascript code to call with the popup item

$bIsEnabled : int = true

can be false if the popup item should be visible but disabled

$sIconPath : string = ''

image of the item relative to the admin/images/popup/ directory

$sAccessKey : string = ''

keyboard access key of the popup item

$bEvalCondition : bool = true

If the condition should be evaluated.

$mNamespaces : array<string|int, mixed>|string = array()

The namespace for the button like "workflow"

$sGroupIdentifier : string = ''

The identifier to add the popup item to a group, which has separator at the beginning and at the end.

$iGroupIndex : int

The index of the group. The index will be used to order the groups. The lowest index will be taken of all popup items inside of a group.

Tags
access

public

Return values
void

makeHtml()

public makeHtml(mixed $PopupID) : mixed
Parameters
$PopupID : mixed
Tags
Return values
mixed

removeAllItems()

public removeAllItems([mixed $keep = array() ]) : mixed
Parameters
$keep : mixed = array()
Tags
access

private

Return values
mixed

removeItem()

public removeItem(mixed $label[, mixed $evalCondition = true ][, mixed $aNamespaces = array() ]) : mixed
Parameters
$label : mixed
$evalCondition : mixed = true
$aNamespaces : mixed = array()
Tags
access

private

Return values
mixed

removeItemsByNamespace()

public removeItemsByNamespace(mixed $aNamespaces) : mixed
Parameters
$aNamespaces : mixed
Tags
inheritdoc
Return values
mixed

setCharset()

public setCharset(mixed $charset) : mixed
Parameters
$charset : mixed
Tags
access

private

Return values
mixed

setDefaultPopup()

public setDefaultPopup(mixed $popup) : mixed
Parameters
$popup : mixed
Tags
access

private

Return values
mixed

setPopupVisible()

public setPopupVisible(mixed $visible) : mixed
Parameters
$visible : mixed
Tags
access

private

Return values
mixed

useDefaultItem()

public useDefaultItem(mixed $label[, mixed $evalCondition = true ]) : mixed
Parameters
$label : mixed
$evalCondition : mixed = true
Tags
access

private

Return values
mixed

        

Search results