mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-01 11:39:41 +08:00
Fixes #4708
This commit is contained in:
@ -146,12 +146,15 @@ abstract class ActiveRecord extends BaseActiveRecord
|
||||
* This method must be overridden by child classes to define available attributes.
|
||||
* Note: primary key attribute "_id" should be always present in returned array.
|
||||
* For example:
|
||||
* ~~~
|
||||
*
|
||||
* ```php
|
||||
* public function attributes()
|
||||
* {
|
||||
* return ['_id', 'name', 'address', 'status'];
|
||||
* }
|
||||
* ~~~
|
||||
* ```
|
||||
*
|
||||
* @throws \yii\base\InvalidConfigException if not implemented
|
||||
* @return array list of attribute names.
|
||||
*/
|
||||
public function attributes()
|
||||
|
||||
Reference in New Issue
Block a user