Overview

Packages

  • application
    • commands
    • components
      • actions
      • filters
      • leftWidget
      • permissions
      • sortableWidget
      • util
      • webupdater
      • x2flow
        • actions
        • triggers
      • X2GridView
      • X2Settings
    • controllers
    • models
      • embedded
    • modules
      • accounts
        • controllers
        • models
      • actions
        • controllers
        • models
      • calendar
        • controllers
        • models
      • charts
        • models
      • contacts
        • controllers
        • models
      • docs
        • components
        • controllers
        • models
      • groups
        • controllers
        • models
      • marketing
        • components
        • controllers
        • models
      • media
        • controllers
        • models
      • mobile
        • components
      • opportunities
        • controllers
        • models
      • products
        • controllers
        • models
      • quotes
        • controllers
        • models
      • services
        • controllers
        • models
      • template
        • models
      • users
        • controllers
        • models
      • workflow
        • controllers
        • models
      • x2Leads
        • controllers
        • models
  • Net
  • None
  • PHP
  • system
    • base
    • caching
      • dependencies
    • collections
    • console
    • db
      • ar
      • schema
        • cubrid
        • mssql
        • mysql
        • oci
        • pgsql
        • sqlite
    • i18n
      • gettext
    • logging
    • test
    • utils
    • validators
    • web
      • actions
      • auth
      • filters
      • form
      • helpers
      • renderers
      • services
      • widgets
        • captcha
        • pagers
  • Text
    • Highlighter
  • zii
    • behaviors
    • widgets
      • grid
      • jui

Classes

  • BaseDocsMassAction
  • CApplication
  • CApplicationComponent
  • CBehavior
  • CComponent
  • CEnumerable
  • CErrorEvent
  • CErrorHandler
  • CEvent
  • CExceptionEvent
  • CModel
  • CModelBehavior
  • CModelEvent
  • CModule
  • CommonFieldsBehavior
  • CSecurityManager
  • CStatePersister
  • Expression
  • MassAction
  • MassAddToList
  • MassCompleteAction
  • MassMoveFileSysObjToFolder
  • MassRemoveFromList
  • MassRenameFileSysObj
  • MassUncompleteAction
  • MobileRecentItems
  • ModulePanelItem
  • NewListFromSelection
  • PanelItem
  • QuickCRUDBehavior
  • RecentItemPanelItem
  • ServiceRoutingBehavior
  • SettingsPanelItem
  • X2AddressBehavior
  • X2AuthCache
  • X2BaseListViewBehavior

Interfaces

  • IAction
  • IApplicationComponent
  • IAuthManager
  • IBehavior
  • IFilter
  • IStatePersister
  • IUserIdentity
  • IViewRenderer
  • IWebServiceProvider
  • IWebUser

Exceptions

  • CException
  • CHttpException
  • TwitterFeedWidgetException
  • Overview
  • Package
  • Class
  • Tree

Class CModelBehavior

CModelBehavior is a base class for behaviors that are attached to a model component. The model should extend from CModel or its child classes.

CComponent
Extended by CBehavior implements IBehavior
Extended by CModelBehavior

Direct known subclasses

CActiveRecordBehavior, SearchIndexBehavior

Indirect known subclasses

AssociatedMediaBehavior, ContactsNameBehavior, JSONFieldsDefaultValuesBehavior, ModelPermissionsBehavior, NormalizedJSONFieldsBehavior, RecordLimitBehavior, RelationshipsBehavior, TagBehavior, TransformedFieldStorageBehavior, WorkflowBehavior, X2ActiveRecordBehavior, X2ChangeLogBehavior, CSaveRelationsBehavior, X2DuplicateBehavior, X2FlowTriggerBehavior, X2LinkableBehavior, X2MergeableBehavior, X2ModelConversionBehavior, X2PermissionsBehavior, X2TimestampBehavior, CTimestampBehavior, EncryptedFieldsBehavior, ERememberFiltersBehavior, FileFieldBehavior, FileSystemObjectBehavior, JSONEmbeddedModelFieldsBehavior, JSONFieldsBehavior
Package: system\base
Copyright: 2008-2013 Yii Software LLC
License: http://www.yiiframework.com/license/
Author: Qiang Xue <qiang.xue@gmail.com>
Located at x2engine/framework/base/CModelBehavior.php
Methods summary
public array
# events( )

Declares events and the corresponding event handler methods. The default implementation returns 'onAfterConstruct', 'onBeforeValidate' and 'onAfterValidate' events and handlers. If you override this method, make sure you merge the parent result to the return value.

Declares events and the corresponding event handler methods. The default implementation returns 'onAfterConstruct', 'onBeforeValidate' and 'onAfterValidate' events and handlers. If you override this method, make sure you merge the parent result to the return value.

Returns

array
events (array keys) and the corresponding event handler methods (array values).

See

CBehavior::events()

Overrides

CBehavior::events()
protected
# afterConstruct( CEvent $event )

Responds to CModel::onAfterConstruct() event. Override this method and make it public if you want to handle the corresponding event of the CBehavior::owner owner.

Responds to CModel::onAfterConstruct() event. Override this method and make it public if you want to handle the corresponding event of the CBehavior::owner owner.

Parameters

$event
CEvent
$event event parameter
protected
# beforeValidate( CModelEvent $event )

Responds to CModel::onBeforeValidate() event. Override this method and make it public if you want to handle the corresponding event of the owner. You may set CModelEvent::$isValid to be false to quit the validation process.

Responds to CModel::onBeforeValidate() event. Override this method and make it public if you want to handle the corresponding event of the owner. You may set CModelEvent::$isValid to be false to quit the validation process.

Parameters

$event
CModelEvent
$event event parameter
protected
# afterValidate( CEvent $event )

Responds to CModel::onAfterValidate() event. Override this method and make it public if you want to handle the corresponding event of the owner.

Responds to CModel::onAfterValidate() event. Override this method and make it public if you want to handle the corresponding event of the owner.

Parameters

$event
CEvent
$event event parameter
Methods inherited from CBehavior
attach(), detach(), getEnabled(), getOwner(), setEnabled()
Methods inherited from CComponent
__call(), __get(), __isset(), __set(), __unset(), asa(), attachBehavior(), attachBehaviors(), attachEventHandler(), canGetProperty(), canSetProperty(), detachBehavior(), detachBehaviors(), detachEventHandler(), disableBehavior(), disableBehaviors(), enableBehavior(), enableBehaviors(), evaluateExpression(), getEventHandlers(), hasEvent(), hasEventHandler(), hasProperty(), raiseEvent()
Magic properties summary
public CModel $owner
#

The owner model that this behavior is attached to.

The owner model that this behavior is attached to.

Magic properties inherited from CBehavior
$enabled
API documentation generated by ApiGen 2.8.0