db\BaseActiveRecord extraFields()

extraFields() public method

Returns the list of fields that can be expanded further and returned by toArray().

This method is similar to fields() except that the list of fields returned by this method are not returned by default by toArray(). Only when field names to be expanded are explicitly specified when calling toArray(), will their values be exported.

The default implementation returns an empty array.

You may override this method to return a list of expandable fields based on some context information (e.g. the current application user).

The default implementation returns the names of the relations that have been populated into this record.

public array extraFields ( )
return array

The list of expandable field names or field definitions. Please refer to fields() on the format of the return value.

doc_Yii
2016-10-30 16:56:43
Comments
Leave a Comment

Please login to continue.