project Employees
This commit is contained in:
1 parent
1b8ca5b695
commit
b2f482e10b
4 files changed
+142
-12
No files matched your search
@@ -50,6 +50,21 @@ class ManagerEmployee extends \yii\db\ActiveRecord
|
||||
];
|
||||
}
|
||||
|
||||
public function fields(): array
|
||||
{
|
||||
return [
|
||||
'id',
|
||||
'manager_id',
|
||||
'employee_id',
|
||||
'employee' => function () {
|
||||
return [
|
||||
"fio" => $this->employee->userCard->fio ?? $this->employee->username,
|
||||
"avatar" => $this->employee->userCard->photo ?? '',
|
||||
];
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* @return ActiveQuery
|
||||
*/
|
||||
|
||||
Reference in new issue
Block a user