All Data Structures Functions Variables Pages
Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Member Functions
CampaignItem Class Reference
Inheritance diagram for CampaignItem:
OwnedModel RedBeanModel BeanModel ObservableComponent

Public Member Functions

 isQueued ()
 
 isSkipped ()
 
 isSent ()
 
 hasFailedToSend ()
 
 hasAtLeastOneOpenActivity ()
 
 hasAtLeastOneClickActivity ()
 
 hasAtLeastOneUnsubscribeActivity ()
 
 hasAtLeastOneBounceActivity ()
 
 hasAtLeastOneEventActivity ($eventType)
 
- Public Member Functions inherited from OwnedModel
 __set ($attributeName, $value)
 
 save ($runValidation=true, array $attributeNames=null)
 
 unrestrictedSave ($runValidation=true, array $attributeNames=null)
 
 forgetOriginalAttributeValues ()
 
- Public Member Functions inherited from RedBeanModel
 getIsNewModel ()
 
 __construct ($setDefaults=true, RedBean_OODBBean $bean=null, $forceTreatAsCreation=false, $runConstruction=true)
 
 serialize ()
 
 unserialize ($data)
 
 getPrimaryBean ()
 
 getClassId ($modelClassName)
 
 getClassBean ($modelClassName)
 
 getModelIdentifier ()
 
 castDown (array $derivedModelClassNames)
 
 isSame (RedBeanModel $model)
 
 __toString ()
 
 __get ($attributeName)
 
 __set ($attributeName, $value)
 
 __isset ($attributeName)
 
 __unset ($attributeName)
 
 attributeNames ()
 
 isAttribute ($attributeName)
 
 isAttributeWithLowerCaseConversion ($attributeName)
 
 isAttributeReadOnly ($attributeName)
 
 isAttributeFormattedAsProbability ($attributeName)
 
 isAllowedToSetReadOnlyAttribute ($attributeName)
 
 rules ()
 
 behaviors ()
 
 attributeLabels ()
 
 abbreviatedAttributeLabels ()
 
 validate (array $attributeNames=null, $ignoreRequiredValidator=false)
 
 onBeforeValidate (CModelEvent $event)
 
 onAfterValidate ($event)
 
 getValidatorList ()
 
 getValidators ($attributeName=null)
 
 forgetValidators ()
 
 createValidators ()
 
 isUniqueAttributeValue ($attributeName, $value)
 
 save ($runValidation=true, array $attributeNames=null)
 
 isRelatedModelReallyModified ($relatedModel, $relationType, $isOwned)
 
 isReallyModified ($relationType, $isOwned)
 
 onBeforeSave ($event)
 
 onAfterSave ($event)
 
 onRedBeanOneToManyRelatedModelsChange ($event)
 
 onBeforeDelete ($event)
 
 onAfterDelete ($event)
 
 isModified ()
 
 delete ()
 
 isDeleted ()
 
 isDeletable ()
 
 forget ()
 
 isAttributeRequired ($attributeName)
 
 isAttributeSafe ($attributeName)
 
 getAttributeLabel ($attributeName)
 
 getAttributeLabelsForAllActiveLanguagesByAttributeName ($attributeName)
 
 hasErrors ($attributeNameOrNames=null)
 
 getErrors ($attributeNameOrNames=null)
 
 getError ($attributeName)
 
 addError ($attributeName, $errorMessage)
 
 addErrors (array $errors)
 
 clearErrors ($attributeName=null)
 
 generateAttributeLabel ($attributeName)
 
 getAttributes (array $attributeNames=null)
 
 setAttributes (array $values, $safeOnly=true)
 
 unsetAttributes ($attributeNames=null)
 
 onUnsafeAttribute ($name, $value)
 
 getScenario ()
 
 setScenario ($scenarioName)
 
 getSafeAttributeNames ()
 
 getIterator ()
 
 offsetExists ($offset)
 
 offsetGet ($offset)
 
 offsetSet ($offset, $item)
 
 offsetUnset ($offset)
 
 stringifyOneToManyRelatedModelsValues ($values)
 
 setIsCopied ()
 
 isCopied ()
 
 addValidator ($attribute, $validator, $params=array())
 
- Public Member Functions inherited from ObservableComponent
 init ()
 
 attachEvents ($events)
 
 events ()
 
 attachEventHandler ($name, $handler)
 
 detachEventHandler ($name, $handler)
 

Static Public Member Functions

static getModuleClassName ()
 
static getDefaultMetadata ()
 
static isTypeDeletable ()
 
static canSaveMetadata ()
 
static getByProcessed ($processed, $pageSize=null)
 
static getByProcessedAndSendOnDateTime ($processed, $timestamp=null, $pageSize=null)
 
static getByProcessedAndStatusAndSendOnDateTime ($processed, $status, $timestamp=null, $pageSize=null)
 
static getByProcessedAndCampaignId ($processed, $campaignId, $pageSize=null)
 
static getByTypeAndCampaignId ($type, $campaignId, $pageSize=null, $countOnly=false)
 
static getAllContactsFromCampaignItemBasedOnItemActivity ($campaignId, $offset, $pageSize, $getNotViewedItem=false, $getNotClickedItems=false, $getOpenedItems=false, $getClickedItems=false)
 
static getNotViewedContactIds ($campaignId, $offset, $pageSize)
 
static getCountOfNotViewedContactIds ($campaignId)
 
static getNotClickedOrUnsubscribedOrSpamContactIds ($campaignId, $offset, $pageSize)
 
static getCountOfNotClickedOrUnsubscribedOrSpamContactIds ($campaignId)
 
static getContactIdsFromCampaignItemsByActivityTypeAndCampaign ($type, $campaignId, $offset, $pageSize)
 
static getCountOfCampaignItemsByActivityTypeAndCampaign ($type, $campaignId)
 
- Static Public Member Functions inherited from OwnedModel
static getCanHaveBean ()
 
static isTypeDeletable ()
 
- Static Public Member Functions inherited from RedBeanModel
static model ($className=null)
 
static getAll ($orderBy=null, $sortDescending=false, $modelClassName=null)
 
static getSubset (RedBeanModelJoinTablesQueryAdapter $joinTablesAdapter=null, $offset=null, $count=null, $where=null, $orderBy=null, $modelClassName=null, $selectDistinct=false)
 
static getSubsetIds (RedBeanModelJoinTablesQueryAdapter $joinTablesAdapter=null, $offset=null, $count=null, $where=null, $orderBy=null, $modelClassName=null, $selectDistinct=false)
 
static makeSubsetOrCountSqlQuery ($tableName, RedBeanModelJoinTablesQueryAdapter $joinTablesAdapter, $offset=null, $count=null, $where=null, $orderBy=null, $selectCount=false, $selectDistinct=false, array $quotedExtraSelectColumnNameAndAliases=array())
 
static getCount (RedBeanModelJoinTablesQueryAdapter $joinTablesAdapter=null, $where=null, $modelClassName=null, $selectDistinct=false)
 
static getById ($id, $modelClassName=null)
 
static deleteAll ()
 
static mangleTableName ()
 
static getTableName ()
 
static getTableNames ($classNames)
 
static getForeignKeyName ($modelClassName, $relationName)
 
static getModelClassNameByIdentifier ($identifier)
 
static getMetadata ()
 
static canSaveMetadata ()
 
static setMetadata (array $metadata)
 
static getDefaultMetadata ()
 
static isTypeDeletable ()
 
static forgetAll ()
 
static getModelLabelByTypeAndLanguage ($type, $language=null)
 
static getAnAttributeLabel ($attributeName)
 
static makeModel (RedBean_OODBBean $bean, $modelClassName=null)
 
static makeModels (array $beans, $modelClassName=null)
 
static getModuleClassName ()
 
static getLastClassInBeanHeirarchy ()
 
static getSortAttributesByAttribute ($attribute)
 
static isCacheable ()
 
static getYiiValidatorsToRedBeanValidators ()
 
static getHasManyOpposingRelationName (RedBeanModel $model, $precedingModelClassName, $precedingRelation)
 
static relationLinksToPrecedingRelation ($modelClassName, $relation, $precedingModelClassName=null, $precedingRelation=null)
 
static allowMemcacheCache ()
 
- Static Public Member Functions inherited from BeanModel
static getCanHaveBean ()
 
static getMetadata ()
 
static isAnAttribute ($attributeName)
 
static resolveAttributeModelClassName ($attributeName)
 
static getAttributeModelClassName ($attributeName)
 
static isRelation ($attributeName)
 
static isOwnedRelation ($attributeName)
 
static getRelationType ($relationName)
 
static getRelationModelClassName ($relationName)
 
static getRelationLinkType ($relationName)
 
static getRelationLinkName ($relationName)
 
static isRelationTypeAHasManyVariant ($relationName)
 
static isRelationTypeAHasOneVariant ($relationName)
 
static isADerivedRelationViaCastedUpModel ($relationName)
 
static getDerivedRelationType ($relationName)
 
static getDerivedRelationModelClassName ($relationName)
 
static getDerivedRelationViaCastedUpModelOpposingRelationName ($relationName)
 
static getInferredRelationModelClassNamesForRelation ($relation)
 
static getColumnNameByAttribute ($attributeName)
 
static getAttributeNames ()
 
static generateAnAttributeLabel ($attributeName)
 
static getAbbreviatedAttributeLabel ($attributeName)
 
static getTranslatedAttributeLabels ($language)
 
static getMixedInModelClassNames ()
 
static isRelationTypeAManyManyVariant ($relationName)
 

Protected Member Functions

 afterDelete ()
 
- Protected Member Functions inherited from RedBeanModel
 constructDerived ($bean, $setDefaults)
 
 constructIncomplete ($bean)
 
 setNotModified ()
 
 onCreated ()
 
 onLoaded ()
 
 onModified ()
 
 mapAndCacheMetadataAndSetHints ($modelClassName, RedBean_OODBBean $bean)
 
 runDefaultValidators ()
 
 setClassBean ($modelClassName, RedBean_OODBBean $bean)
 
 unrestrictedGet ($attributeName)
 
 unrestrictedSet ($attributeName, $value)
 
 beforeValidate ()
 
 afterValidate ()
 
 beforeSave ()
 
 afterSave ()
 
 linkBeans ()
 
 beforeDelete ()
 
 afterDelete ()
 
 unrestrictedDelete ()
 
 deleteOwnedRelatedModels ($modelClassName)
 
 deleteForeignRelatedModels ($modelClassName)
 
 deleteManyManyRelations ($modelClassName)
 

Static Protected Member Functions

static getLabel ($language=null)
 
static getPluralLabel ($language=null)
 
- Static Protected Member Functions inherited from RedBeanModel
static makeCasedLinkName ($relationType, $linkType, $relationLinkName)
 
static getModelIdentifierByClassNameAndBeanId ($modelClassName, $beanId)
 
static assertMetadataIsValid (array $metadata)
 
static getByRelatedClassId ($relatedModelClassName, $id, $modelClassName=null)
 
static getLabel ($language=null)
 
static getPluralLabel ($language=null)
 
static getAttributeLabelByLanguage ($attributeName, $language)
 
static getTranslatedCustomAttributeLabelByLanguage ($attributeName, $languageCode)
 
static resolveModelClassNameForClassesWithoutBeans (&$modelClassName)
 
- Static Protected Member Functions inherited from BeanModel
static translatedAbbreviatedAttributeLabels ($language)
 
static translatedAttributeLabels ($language)
 
static getAttributeNamesToClassNamesForModel ()
 
static getAttributeNamesNotBelongsToOrManyManyForModel ()
 
static getRelationNameToRelationTypeModelClassNameAndOwnsForModel ()
 
static getDerivedRelationNameToTypeModelClassNameAndOppposingRelationForModel ()
 
static forgetBeanModel ($modelClassName)
 
static forgetAllBeanModels ()
 
static resolveCacheAndMapMetadataForAllClassesInHeirarchy ()
 
static resolveCachedMetadataForIntegrity ($cachedData)
 
static resolveLinkTypeAndRelationLinkName ($relationTypeModelClassNameAndOwns, &$linkType, &$relationLinkName)
 

Additional Inherited Members

- Data Fields inherited from OwnedModel
 $originalAttributeValues = array()
 
- Data Fields inherited from RedBeanModel
const MODEL_IDENTIFIER_DELIMITER = '_'
 
- Data Fields inherited from BeanModel
const HAS_ONE_BELONGS_TO = 0
 
const HAS_MANY_BELONGS_TO = 1
 
const HAS_ONE = 2
 
const HAS_MANY = 3
 
const MANY_MANY = 4
 
const OWNED = true
 
const NOT_OWNED = false
 
const CACHE_IDENTIFIER = 'BeanModelMapping'
 
const LINK_TYPE_ASSUMPTIVE = 0
 
const LINK_TYPE_SPECIFIC = 1
 
const LINK_TYPE_POLYMORPHIC = 2
 
- Protected Attributes inherited from RedBeanModel
 $modelClassNameToBean = array()
 
 $attributeNameToBeanAndClassName = array()
 
 $relationNameToRelatedModel = array()
 
 $unlinkedRelationNames = array()
 
 $unlinkedOwnedRelatedModelsToRemove = array()
 
 $validators = array()
 
 $attributeNameToErrors = array()
 
 $scenarioName = ''
 
 $modified = false
 
 $deleted = false
 
 $isInIsModified = false
 
 $isInHasErrors = false
 
 $isInGetErrors = false
 
 $isValidating = false
 
 $isSaving = false
 
 $isDeleting = false
 
 $isNewModel = false
 
 $isCopied = false
 
 $isSavableFromRelation = true
 
- Static Protected Attributes inherited from OwnedModel
static $lastClassInBeanHeirarchy = 'OwnedModel'
 
- Static Protected Attributes inherited from RedBeanModel
static $lastClassInBeanHeirarchy = 'RedBeanModel'
 
static $attributeLabelsByLanguage = array()
 
- Static Protected Attributes inherited from BeanModel
static $lastClassInBeanHeirarchy = 'BeanModel'
 

Detailed Description

Definition at line 37 of file CampaignItem.php.

Member Function Documentation

static getLabel (   $language = null)
staticprotected

Returns the display name for the model class.

Returns
dynamic label name based on module.

Definition at line 48 of file CampaignItem.php.

static getPluralLabel (   $language = null)
staticprotected

Returns the display name for plural of the model class.

Returns
dynamic label name based on module.

Definition at line 57 of file CampaignItem.php.

static getByProcessed (   $processed,
  $pageSize = null 
)
static
Parameters
int$processed
null | int$pageSize

Definition at line 106 of file CampaignItem.php.

static getByProcessedAndSendOnDateTime (   $processed,
  $timestamp = null,
  $pageSize = null 
)
static
Parameters
int$processed
null$timestamp
null | int$pageSize

Definition at line 128 of file CampaignItem.php.

static getByProcessedAndCampaignId (   $processed,
  $campaignId,
  $pageSize = null 
)
static
Parameters
int$processed
int$campaignId
null | int$pageSize

Definition at line 196 of file CampaignItem.php.

static getByTypeAndCampaignId (   $type,
  $campaignId,
  $pageSize = null,
  $countOnly = false 
)
static
Parameters
int$type
int$campaignId
null | int$pageSize
null | bool$countOnly

Definition at line 226 of file CampaignItem.php.

isQueued ( )

Return true if the related email message in on the outbox folder

Returns
bool

Definition at line 259 of file CampaignItem.php.

isSkipped ( )
Returns
bool

Definition at line 272 of file CampaignItem.php.

isSent ( )

Return true if the email message has been sent

Returns
bool

Definition at line 292 of file CampaignItem.php.

hasFailedToSend ( )
Returns
bool

Definition at line 304 of file CampaignItem.php.

hasAtLeastOneOpenActivity ( )
Returns
bool;

Definition at line 316 of file CampaignItem.php.

hasAtLeastOneClickActivity ( )
Returns
bool;

Definition at line 324 of file CampaignItem.php.

hasAtLeastOneUnsubscribeActivity ( )
Returns
bool;

Definition at line 332 of file CampaignItem.php.

hasAtLeastOneBounceActivity ( )
Returns
bool;

Definition at line 340 of file CampaignItem.php.

hasAtLeastOneEventActivity (   $eventType)
Returns
bool;

Definition at line 348 of file CampaignItem.php.

static getNotViewedContactIds (   $campaignId,
  $offset,
  $pageSize 
)
static

Get not viewed contacts from campaigns.

Parameters
int$campaignId
int$offset
int$pageSize
Returns
array

Definition at line 408 of file CampaignItem.php.

static getCountOfNotViewedContactIds (   $campaignId)
static

Get count of not viewed items.

Parameters
int$campaignId
Returns
int

Definition at line 431 of file CampaignItem.php.

static getNotClickedOrUnsubscribedOrSpamContactIds (   $campaignId,
  $offset,
  $pageSize 
)
static

Get contacts from campaign items that are not clicked, but do not return those that are marked as spam, unsubscribed, or hard bounced

Parameters
int$campaignId
intoffset
intpageSize
Returns
array

Definition at line 451 of file CampaignItem.php.

static getCountOfNotClickedOrUnsubscribedOrSpamContactIds (   $campaignId)
static

Get count of contacts that are not clicked, but do not return those that are marked as spam, unsubscribed, or hard bounced

Parameters
int$campaignId
Returns
int

Definition at line 485 of file CampaignItem.php.

static getContactIdsFromCampaignItemsByActivityTypeAndCampaign (   $type,
  $campaignId,
  $offset,
  $pageSize 
)
static

Get distinct contact ids by activity type and campaign

Parameters
$type
int$campaignId
$offset
$pageSize
Returns
An

Definition at line 518 of file CampaignItem.php.

static getCountOfCampaignItemsByActivityTypeAndCampaign (   $type,
  $campaignId 
)
static

Get number of distinct contacts by activity type and campaign

Parameters
$type
int$campaignId
Returns
string

Definition at line 543 of file CampaignItem.php.


The documentation for this class was generated from the following file:
Generated on Sun Jan 26 2020 07:10:28