Portlet Class Reference

Inheritance diagram for Portlet:
RedBeanModel BeanModel ObservableComponent

Public Member Functions

 getView ()
 getUniquePortletPageId ()
 getCssClasses ()
 getTitle ()
 renderContent ()
 renderHeadContent ()
 getPortletParams ()
 isEditable ()
 beforeDelete ()

Static Public Member Functions

static getByLayoutIdAndUserSortedByColumnIdAndPosition ($layoutId, $userId, $params)
static getByLayoutIdAndUserSortedById ($layoutId, $userId)
static makePortletsUsingMetadataSortedByColumnIdAndPosition ($layoutId, $metadata, $user, $params)
static savePortlets ($portletCollection)
static shiftPositionsBasedOnColumnReduction ($portletCollection, $newColumnCount)
static makePortletUsingViewType ($viewType, $uniqueLayoutId, $user, $numberOfColumns)
static getDefaultMetadata ()
static doesPortletExistByViewTypeLayoutIdAndUser ($viewType, $uniqueLayoutId, $userId)
static getPlacedViewTypesByLayoutIdAndUser ($uniqueLayoutId, $userId)
static resolvePortletCollectionColumnIndexes ($layoutId)

Data Fields

 $params

Protected Attributes

 $view

Detailed Description

Portlets is a model utilized by some view types to display information. Portlets have display states on a per user basis including hide/collapse and portlet position. The home page dashboard and subviews are comprised of portlets. A portlet contains 2 views, a display view and a configuration view.

Definition at line 44 of file Portlet.php.


Member Function Documentation

static makePortletUsingViewType ( viewType,
uniqueLayoutId,
user,
numberOfColumns 
) [static]

Make a portlet with default values and maximum number of columns in a layout

Parameters:
string $viewType
string $uniqueLayoutId
User $user
int $numberOfColumns

Definition at line 158 of file Portlet.php.

static getDefaultMetadata (  )  [static]

Returns the default meta data for the class. It must be appended to the meta data from the parent model, if any.

Reimplemented from RedBeanModel.

Definition at line 170 of file Portlet.php.

getUniquePortletPageId (  ) 

Gets a unique identifier to allow for multiple portlets on the same page.

Definition at line 214 of file Portlet.php.

beforeDelete (  ) 

This method is invoked before deleting a record. The default implementation raises the onBeforeDelete event. You may override this method to do any preparation work for record deletion. Make sure you call the parent implementation so that the event is raised properly.

Returns:
boolean whether the record should be deleted. Defaults to true.

Reimplemented from RedBeanModel.

Definition at line 251 of file Portlet.php.

static doesPortletExistByViewTypeLayoutIdAndUser ( viewType,
uniqueLayoutId,
userId 
) [static]

Check if the portlet is already added to the detail view. This would take care of the case where user click on the link in select portlet list more than one time

Parameters:
string $viewType
string $uniqueLayoutId
int $userId
Returns:
boolean

Definition at line 274 of file Portlet.php.

static resolvePortletCollectionColumnIndexes ( layoutId  )  [static]
Parameters:
$layoutId Resolve portlet collection items sequence. Exclude missing indexes. This method is used as patch fix for ambiguous portlet items, that exist in database.

Definition at line 308 of file Portlet.php.


Field Documentation

$params

TODO

Definition at line 51 of file Portlet.php.


The documentation for this class was generated from the following file:
 All Data Structures Functions Variables
Generated on Mon Sep 25 07:10:28 2017