RelatedToEntry
extends Condition
in package
Table of Contents
- EVENT_DEFINE_FOR_TRIGGERS = 'event-define-for-triggers'
- $active : bool
- $dateCreated : DateTime
- $dateUpdated : DateTime
- $elementId : int
- $group_id : int
- $handle : string
- $id : int
- $operator : string
- $order : int
- $trigger_id : int
- $uid : string
- $_element : Element
- $_forTriggers : bool
- $_trigger : TriggerInterface
- check() : bool
- configTemplate() : string
- Get configuration template
- defineRules() : array<string|int, mixed>
- forTriggers() : array<string|int, mixed>|null
- To which triggers this condition applies
- getConfig() : array<string|int, mixed>
- Get project config
- getDescription() : string
- getElement() : Element|null
- Get the element chosen
- getElementName() : string
- Get the element name
- getElementTitle() : string
- Get the element type
- getElementType() : string
- Get the element type
- getHandle() : string
- getName() : string
- getTrigger() : TriggerInterface|null
- Trigger getter
- hasConfig() : bool
- Does this condition have configuration
- populateFromData() : mixed
- Populate condition from array of data
- setData() : mixed
- Data setter
- setTrigger() : mixed
- Trigger setter
- baseAttributes() : array<string|int, mixed>
- Get all base attributes, all attributes not in this array will be considered data
- defineForTriggers() : array<string|int, mixed>|null
- Triggers for which this condition applies. null means all
Constants
EVENT_DEFINE_FOR_TRIGGERS
public
mixed
EVENT_DEFINE_FOR_TRIGGERS
= 'event-define-for-triggers'
Properties
$active
public
bool
$active
= true
$dateCreated
public
DateTime
$dateCreated
$dateUpdated
public
DateTime
$dateUpdated
$elementId
public
int
$elementId
$group_id
public
int
$group_id
$handle
public
string
$handle
$id
public
int
$id
$operator
public
string
$operator
= 'and'
$order
public
int
$order
$trigger_id
public
int
$trigger_id
$uid
public
string
$uid
$_element
protected
Element
$_element
$_forTriggers
protected
bool
$_forTriggers
= false
$_trigger
protected
TriggerInterface
$_trigger
Methods
check()
public
check(TriggerInterface $trigger, array<string|int, mixed> $data) : bool
Parameters
- $trigger : TriggerInterface
- $data : array<string|int, mixed>
Tags
Return values
bool —configTemplate()
Get configuration template
public
configTemplate() : string
Tags
Return values
string —defineRules()
public
defineRules() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —forTriggers()
To which triggers this condition applies
public
forTriggers() : array<string|int, mixed>|null
Tags
Return values
array<string|int, mixed>|null —getConfig()
Get project config
public
getConfig() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —getDescription()
public
getDescription() : string
Tags
Return values
string —getElement()
Get the element chosen
public
getElement() : Element|null
Return values
Element|null —getElementName()
Get the element name
public
getElementName() : string
Return values
string —getElementTitle()
Get the element type
public
getElementTitle() : string
Return values
string —getElementType()
Get the element type
public
getElementType() : string
Return values
string —getHandle()
public
getHandle() : string
Tags
Return values
string —getName()
public
getName() : string
Tags
Return values
string —getTrigger()
Trigger getter
public
getTrigger() : TriggerInterface|null
Tags
Return values
TriggerInterface|null —hasConfig()
Does this condition have configuration
public
hasConfig() : bool
Tags
Return values
bool —populateFromData()
Populate condition from array of data
public
populateFromData(array<string|int, mixed> $data) : mixed
Parameters
- $data : array<string|int, mixed>
Tags
Return values
mixed —setData()
Data setter
public
setData(mixed $data) : mixed
Parameters
- $data : mixed
Tags
Return values
mixed —setTrigger()
Trigger setter
public
setTrigger(TriggerInterface $trigger) : mixed
Parameters
- $trigger : TriggerInterface
Tags
Return values
mixed —baseAttributes()
Get all base attributes, all attributes not in this array will be considered data
protected
baseAttributes() : array<string|int, mixed>
Return values
array<string|int, mixed> —defineForTriggers()
Triggers for which this condition applies. null means all
protected
defineForTriggers() : array<string|int, mixed>|null