All Data Structures Functions Variables Pages
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
CommentsElement Class Reference
Inheritance diagram for CommentsElement:
Element DerivedElementInterface CommentsForModelCommentsFeedPortletElement TaskCommentsElement

Public Member Functions

 __construct ($model, $attribute, $form=null, array $params=array())
 
- Public Member Functions inherited from Element
 __construct ($model, $attribute, $form=null, array $params=array())
 
 render ()
 
 getEditableNameIds ()
 
 getAttribute ()
 
 renderAsControlNonEditable ()
 

Static Public Member Functions

static getModelAttributeNames ()
 
static getRelatedModelCommentInlineEditView ($id, $relatedModelId, $relatedModelClassName, $relatedModelRelationName, $uniquePageId=null)
 
- Static Public Member Functions inherited from Element
static getDisplayName ()
 
static isReadOnly ()
 
static resolveInputNameForEditableInput ($attributeName)
 
static resolveInputNamePrefixIntoString ($inputNamePrefix)
 
static resolveInputIdPrefixIntoString ($inputIdPrefix)
 

Protected Member Functions

 getCommentsWrappingCssClass ()
 
 renderControlEditable ()
 
 renderControlNonEditable ()
 
 renderLabel ()
 
 renderRelatedModelCommentsContent ()
 
 renderRelatedModelCreateCommentContent ()
 
- Protected Member Functions inherited from Element
 renderLabel ()
 
 resolveIdForLabel ()
 
 getFormattedAttributeLabel ()
 
 resolveNonActiveFormFormattedLabel ($label)
 
 renderError ()
 
 renderScopedErrorId ($inputNameIdPrefix, $attribute)
 
 renderEditable ()
 
 renderNonEditable ()
 
 renderControlEditable ()
 
 renderControlNonEditable ()
 
 getColumnSpan ()
 
 getDisabledValue ()
 
 getHtmlOptions ()
 
 resolveContentTemplate ($template, $data)
 
 getEditableInputId ($attributeName=null, $relationAttributeName=null)
 
 getEditableInputName ($attributeName=null, $relationAttributeName=null)
 
 resolveInputPrefix ()
 
 resolveInputIdPrefix ()
 
 resolveInputNamePrefix ()
 
 getListViewGridId ()
 

Protected Attributes

 $relatedModelRelationName
 
 $moduleId
 
- Protected Attributes inherited from Element
 $model
 
 $attribute
 
 $form
 

Additional Inherited Members

- Data Fields inherited from Element
 $params
 
 $editableTemplate = '<th>{label}</th><td colspan="{colspan}">{content}{error}</td>'
 
 $nonEditableTemplate = '<th>{label}</th><td colspan="{colspan}">{content}</td>'
 

Detailed Description

Displays the comments list for related model along with input text area

Definition at line 40 of file CommentsElement.php.

Constructor & Destructor Documentation

__construct (   $model,
  $attribute,
  $form = null,
array  $params = array() 
)

Constructs the element specifying the model and attribute. In the case of needing to show editable information, a form is also provided.

Parameters
$formOptional. If supplied an editable element will be rendered.
$paramsCan have additional parameters for use

Definition at line 60 of file CommentsElement.php.

Member Function Documentation

renderControlEditable ( )
protected
Exceptions
NotImplementedException

Definition at line 91 of file CommentsElement.php.

renderControlNonEditable ( )
protected

Renders the attribute from the model.

Returns
The element's content.

Definition at line 100 of file CommentsElement.php.

static getModelAttributeNames ( )
static

Get the attributeNames of attributes used in the derived element. For this element, there are no attributes from the model.

Returns
array - empty

Implements DerivedElementInterface.

Definition at line 115 of file CommentsElement.php.

renderLabel ( )
protected
Returns
string

Definition at line 123 of file CommentsElement.php.

renderRelatedModelCommentsContent ( )
protected

Renders related model comments

Returns
string

Definition at line 132 of file CommentsElement.php.

renderRelatedModelCreateCommentContent ( )
protected

Renders related model create comment form

Returns
string

Definition at line 149 of file CommentsElement.php.

static getRelatedModelCommentInlineEditView (   $id,
  $relatedModelId,
  $relatedModelClassName,
  $relatedModelRelationName,
  $uniquePageId = null 
)
static

Used for inline comments edit Get view and set parameters for comment inline edit

Parameters
$id
$relatedModelId
$relatedModelClassName
$relatedModelRelationName
null$uniquePageId
Returns
CommentInlineEditView
Exceptions
NotFoundException

Definition at line 198 of file CommentsElement.php.


The documentation for this class was generated from the following file:
Generated on Wed Apr 1 2020 07:10:51