ePages 7.25.0 - DE_EPAGES/Presentation/API/Object/Menu.pm

Package DE_EPAGES::Presentation::API::Object::Menu

object interface for Menu.

Base
DE_EPAGES::Object::API::Object::DALObject

Functions

action
baseMenu
className
dbPackage
derivedMenus
directSubMenus
insertSubMenu
name
pageType
parentMenu
position
subMenus
template
templateName

action

Returns the action of the menu or undef if the menu has no action.

Syntax
$Action = $Menu->action;
Return
$Action (object)
Action object or undef

baseMenu

Returns the base menu of this menu or undef if the menu has no base menu.

Syntax
$BaseMenu = $Menu->baseMenu;
Return
$BaseMenu (object)
base menu object

className

Returns the class name, used for DAL access.

Syntax
$ClassName = $Menu->className;
Return
$ClassName (String)
class name

dbPackage

Returns the database package, used for DAL access.

Syntax
$DbPackage = $Menu->dbPackage;
Return
$DbPackage (String)
database package name

derivedMenus

Returns the direct derived menus of this menu ordered by position.

Syntax
$aDerivedMenus = $Menu->derivedMenus;
Return
$aDerivedMenus (ref.array.object)
list derived menu objects

directSubMenus

Returns the direct sub menus of this menu ordered by position.

Syntax
$aSubMenus = $Menu->directSubMenus;
Return
$aSubMenus (ref.array.object)
list sub menu objects

insertSubMenu

Inserts a new sub menu into the database.

Syntax
$SubMenu = $Menu->insertSubMenu( $hMenu );
Input
$hMenu (ref.hash.string)
menu parameters
  • Template - template name - string
  • PageTypeID - page type id - integer
  • BaseMenuID - (optional) base menu id - integer
  • ActionID - (optional) action id - integer
  • Position - sort order position - integer

Return
$SubMenu (object)
sub menu object

name

Returns the menu name

Syntax
$Name = $Menu->name;
Return
$Name (int)
menu name

pageType

Returns the page type of the menu.

Syntax
$PageType = $Menu->pageType;
Return
$PageType (object)
PageType object

parentMenu

Returns the parent menu of this menu or undef if the menu has no parent.

Syntax
$ParentMenu = $Menu->parentMenu;
Return
$ParentMenu (object)
parent menu object

position

Returns the sort order position of this sub menu within the parent menu

Syntax
$Position = $Menu->position;
Return
$Position (int)
menu position

subMenus

Returns the sub menus of this menu ordered by position. If the menu has a base menu, then it inherits all sub menus of the base menu, but it can override the positions and actions and add additional sub menus.

Syntax
$aSubMenus = $Menu->subMenus;
Return
$aSubMenus (ref.array.object)
list sub menu objects

template

Returns the template name

Syntax
$Template = $Menu->template;
Return
$Template (int)
template name

templateName

obsolete. Use $Menu->get('Template') or $Menu->get('Name') instead.

Syntax
$Template = $Menu->templateName;
Return
$Template (string)
template name