PHP 클래스 skeeks\cms\relatedProperties\models\RelatedPropertiesModel

상속: extends yii\base\DynamicModel
파일 보기 프로젝트 열기: skeeks-cms/cms 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$relatedElementModel RelatedElementModel

공개 메소드들

메소드 설명
attributeHints ( ) : array
attributeLabels ( )
delete ( ) : boolean
getAttribute ( string $name ) : mixed Returns the named attribute value.
getEnumByAttribute ( $name ) : RelatedPropertyEnumModel | RelatedPropertyEnumModel[] | null
getProperties ( ) : RelatedPropertyModel[]
getRelatedElementProperties ( string $name ) : RelatedElementPropertyModel | RelatedElementPropertyModel[]
getRelatedProperty ( string $name ) : RelatedPropertyModel
getSmartAttribute ( $name ) : string
hasAttribute ( string $name ) : boolean Returns a value indicating whether the model has an attribute with the specified name.
init ( )
loadDefaultValues ( boolean $skipIfSet = true ) Loads default values from database table schema
save ( boolean $runValidation = true, array $attributeNames = null ) : boolean Saves the current record.
setAttribute ( string $name, mixed $value ) Sets the named attribute value.

보호된 메소드들

메소드 설명
_deleteRelatedPropertyValue ( RelatedPropertyModel $property )
_saveRelatedPropertyValue ( RelatedPropertyModel $property )

메소드 상세

_deleteRelatedPropertyValue() 보호된 메소드

protected _deleteRelatedPropertyValue ( RelatedPropertyModel $property )
$property RelatedPropertyModel

_saveRelatedPropertyValue() 보호된 메소드

protected _saveRelatedPropertyValue ( RelatedPropertyModel $property )
$property RelatedPropertyModel

attributeHints() 공개 메소드

public attributeHints ( ) : array
리턴 array

attributeLabels() 공개 메소드

public attributeLabels ( )

delete() 공개 메소드

public delete ( ) : boolean
리턴 boolean

getAttribute() 공개 메소드

If this record is the result of a query and the attribute is not loaded, null will be returned.
또한 보기: hasAttribute()
public getAttribute ( string $name ) : mixed
$name string the attribute name
리턴 mixed the attribute value. Null if the attribute is not set or does not exist.

getEnumByAttribute() 공개 메소드

public getEnumByAttribute ( $name ) : RelatedPropertyEnumModel | RelatedPropertyEnumModel[] | null
$name
리턴 RelatedPropertyEnumModel | RelatedPropertyEnumModel[] | null

getProperties() 공개 메소드

public getProperties ( ) : RelatedPropertyModel[]
리턴 RelatedPropertyModel[]

getRelatedElementProperties() 공개 메소드

public getRelatedElementProperties ( string $name ) : RelatedElementPropertyModel | RelatedElementPropertyModel[]
$name string
리턴 RelatedElementPropertyModel | RelatedElementPropertyModel[]

getRelatedProperty() 공개 메소드

public getRelatedProperty ( string $name ) : RelatedPropertyModel
$name string
리턴 RelatedPropertyModel

getSmartAttribute() 공개 메소드

public getSmartAttribute ( $name ) : string
$name
리턴 string

hasAttribute() 공개 메소드

Returns a value indicating whether the model has an attribute with the specified name.
public hasAttribute ( string $name ) : boolean
$name string the name of the attribute
리턴 boolean whether the model has an attribute with the specified name.

init() 공개 메소드

public init ( )

loadDefaultValues() 공개 메소드

You may call this method to load default values after creating a new instance: php class Customer extends \yii\db\ActiveRecord $customer = new Customer(); $customer->loadDefaultValues();
public loadDefaultValues ( boolean $skipIfSet = true )
$skipIfSet boolean whether existing value should be preserved. This will only set defaults for attributes that are `null`.

save() 공개 메소드

This method will call [[insert()]] when [[isNewRecord]] is true, or [[update()]] when [[isNewRecord]] is false. For example, to save a customer record: php $customer = new Customer; // or $customer = Customer::findOne($id); $customer->name = $name; $customer->email = $email; $customer->save();
public save ( boolean $runValidation = true, array $attributeNames = null ) : boolean
$runValidation boolean whether to perform validation (calling [[validate()]]) before saving the record. Defaults to `true`. If the validation fails, the record will not be saved to the database and this method will return `false`.
$attributeNames array list of attribute names that need to be saved. Defaults to null, meaning all attributes that are loaded from DB will be saved.
리턴 boolean whether the saving succeeded (i.e. no validation errors occurred).

setAttribute() 공개 메소드

Sets the named attribute value.
또한 보기: hasAttribute()
public setAttribute ( string $name, mixed $value )
$name string the attribute name
$value mixed the attribute value.

프로퍼티 상세

$relatedElementModel 공개적으로 프로퍼티

public RelatedElementModel $relatedElementModel
리턴 RelatedElementModel