Beispiel #1
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getOwner()
 {
     return $this->hasOne(User::className(), ['id' => 'owner_id']);
 }
Beispiel #2
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getUsers()
 {
     return $this->hasMany(User::className(), ['name' => 'role']);
 }
Beispiel #3
0
 public function actions()
 {
     return ['remove' => ['class' => RemoveAction::className(), 'modelClass' => User::className()], 'delete' => ['class' => DeleteAction::className(), 'modelClass' => User::className()], 'restore' => ['class' => RestoreAction::className(), 'modelClass' => User::className()]];
 }