PHP Class BaseEventTypeElement

Inheritance: extends BaseElement
Mostrar archivo Open project: openeyes/openeyes Class Usage Examples

Public Properties

Property Type Description
$firm
$patientId
$useContainerView
$userId

Protected Properties

Property Type Description
$_children
$_element_type
$errorExceptions
$frontEndErrors

Public Methods

Method Description
addError ( $attribute, $message )
canCopy ( ) : boolean Can this element be copied (cloned/duplicated) Override to return true if you want an element to be copyable.
canViewPrevious ( ) : boolean Can we view the previous version of this element.
getChildElementTypes ( ) : ElementType[] get the child element types for this BaseEventElementType.
getChildren ( ) : array Return this elements children.
getContainer_create_view ( )
getContainer_form_view ( )
getContainer_print_view ( )
getContainer_update_view ( )
getContainer_view_view ( )
getCreate_view ( )
getDefaultContainerView ( )
getDefaultView ( )
getElementType ( ) : ElementType Get the ElementType for this element.
getElementTypeName ( ) : string Return the element type name.
getForm_View ( )
getFrontEndErrors ( ) returns the front-end attributes with errors.
getInfoText ( )
getPrint_view ( )
getSetting ( $key )
getUpdate_view ( )
getView_view ( )
hasMultiSelectValue ( $relation, $value_string ) Returns true if the specified multiselect relation has the value $value_string.
isEditable ( )
isHiddenInUI ( ) : boolean Is this element to be hidden in the UI? (Prevents the elements from being displayed on page load.).
isRequired ( ) : boolean Is this a required element?
isRequiredInUI ( ) : boolean Is this element required in the UI? (Prevents the user from being able to remove the element.).
loadFromExisting ( BaseEventTypeElement $element ) Load an existing element's data into this one The base implementation simply uses copiedFields(), but it may be overridden to allow for more complex relationships.
render ( $action )
requiredIfSide ( $attribute, $params )
setChildren ( BaseEventTypeElement[] $children ) set the children for this element - allows external definition of what the children should be (for workflows determined by controllers and the like.
setDefaultOptions ( ) Stubbed method to set default options Used by child objects to set defaults for forms on create.
setUpdateOptions ( ) Stubbed method to set update options Used by child objects to override null values for forms on update.
softDelete ( ) stub method to allow elements to carry out actions related to being a part of a soft deleted event.
updateMultiSelectData ( $model, $ids, $relation_field ) Updates multiselect items in the database, deleting items not passed in $ids.

Protected Methods

Method Description
copiedFields ( ) : array: Fields which are copied by the loadFromExisting() method By default these are taken from the "safe" scenario of the model rules, but should be overridden for more complex requirements.
errorAttributeException ( $attribute ) : mixed Allows for exceptions where the element displayed is not the one required. eg for ajax control elements.

Method Details

addError() public method

public addError ( $attribute, $message )

canCopy() public method

Can this element be copied (cloned/duplicated) Override to return true if you want an element to be copyable.
public canCopy ( ) : boolean
return boolean

canViewPrevious() public method

Can we view the previous version of this element.
public canViewPrevious ( ) : boolean
return boolean

copiedFields() protected method

Fields which are copied by the loadFromExisting() method By default these are taken from the "safe" scenario of the model rules, but should be overridden for more complex requirements.
protected copiedFields ( ) : array:
return array:

errorAttributeException() protected method

Allows for exceptions where the element displayed is not the one required. eg for ajax control elements.
protected errorAttributeException ( $attribute ) : mixed
$attribute
return mixed

getChildElementTypes() public method

get the child element types for this BaseEventElementType.
public getChildElementTypes ( ) : ElementType[]
return ElementType[]

getChildren() public method

Return this elements children.
public getChildren ( ) : array
return array

getContainer_create_view() public method

getContainer_form_view() public method

getContainer_print_view() public method

getContainer_update_view() public method

getContainer_view_view() public method

getCreate_view() public method

public getCreate_view ( )

getDefaultContainerView() public method

getDefaultView() public method

public getDefaultView ( )

getElementType() public method

Get the ElementType for this element.
public getElementType ( ) : ElementType
return ElementType

getElementTypeName() public method

Return the element type name.
public getElementTypeName ( ) : string
return string $name

getForm_View() public method

public getForm_View ( )

getFrontEndErrors() public method

returns the front-end attributes with errors.
public getFrontEndErrors ( )

getInfoText() public method

public getInfoText ( )

getPrint_view() public method

public getPrint_view ( )

getSetting() public method

public getSetting ( $key )

getUpdate_view() public method

public getUpdate_view ( )

getView_view() public method

public getView_view ( )

hasMultiSelectValue() public method

Returns true if the specified multiselect relation has the value $value_string.
public hasMultiSelectValue ( $relation, $value_string )

isEditable() public method

public isEditable ( )

isHiddenInUI() public method

Is this element to be hidden in the UI? (Prevents the elements from being displayed on page load.).
public isHiddenInUI ( ) : boolean
return boolean

isRequired() public method

Is this a required element?
public isRequired ( ) : boolean
return boolean

isRequiredInUI() public method

Is this element required in the UI? (Prevents the user from being able to remove the element.).
public isRequiredInUI ( ) : boolean
return boolean

loadFromExisting() public method

Load an existing element's data into this one The base implementation simply uses copiedFields(), but it may be overridden to allow for more complex relationships.
public loadFromExisting ( BaseEventTypeElement $element )
$element BaseEventTypeElement

render() public method

public render ( $action )

requiredIfSide() public method

public requiredIfSide ( $attribute, $params )

setChildren() public method

set the children for this element - allows external definition of what the children should be (for workflows determined by controllers and the like.
public setChildren ( BaseEventTypeElement[] $children )
$children BaseEventTypeElement[]

setDefaultOptions() public method

Stubbed method to set default options Used by child objects to set defaults for forms on create.
public setDefaultOptions ( )

setUpdateOptions() public method

Stubbed method to set update options Used by child objects to override null values for forms on update.
public setUpdateOptions ( )

softDelete() public method

stub method to allow elements to carry out actions related to being a part of a soft deleted event.
public softDelete ( )

updateMultiSelectData() public method

Updates multiselect items in the database, deleting items not passed in $ids.
public updateMultiSelectData ( $model, $ids, $relation_field )

Property Details

$_children protected_oe property

protected $_children

$_element_type protected_oe property

protected $_element_type

$errorExceptions protected_oe property

protected $errorExceptions

$firm public_oe property

public $firm

$frontEndErrors protected_oe property

protected $frontEndErrors

$patientId public_oe property

public $patientId

$useContainerView public_oe property

public $useContainerView

$userId public_oe property

public $userId