attributes() публичный Метод

This method could be overridden by child classes to define available attributes. Note: all attributes defined in base Active Record class should be always present in returned array. For example: php public function attributes() { return array_merge( parent::attributes(), ['tags', 'status'] ); }
public attributes ( ) : array
Результат array list of attribute names.
Пример #1
0
 public function attributes()
 {
     return array_merge(parent::attributes(), ['ownerId', 'contentType']);
 }
Пример #2
0
 public function attributes()
 {
     return array_merge(parent::attributes(), ['mimeType']);
 }
Пример #3
0
 public function attributes()
 {
     return array_merge(parent::attributes(), ['filename', 'metadata', 'metadatanew', 'uploadDate', 'groups', 'onlineStatus', 'updated_by', 'updated_at']);
 }
Пример #4
0
 public function attributes()
 {
     return array_merge(parent::attributes(), ['userId', 'contentType', 'description']);
 }
Пример #5
0
 public function attributes()
 {
     return array_merge(parent::attributes(), ['filesize', 'filetype']);
 }