コード例 #1
0
ファイル: Profile.php プロジェクト: vovancho/yii2test
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getAuthuser()
 {
     return $this->hasOne(Authuser::className(), ['auth_user_id' => 'profile_id']);
 }
コード例 #2
0
ファイル: Authitem.php プロジェクト: vovancho/yii2test
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getusers()
 {
     return $this->hasMany(Authuser::className(), ['auth_user_id' => 'user_id'])->from(['users' => Authuser::tableName()])->viaTable('auth_assignment', ['item_name' => 'name']);
 }
コード例 #3
0
ファイル: Authassignment.php プロジェクト: vovancho/yii2test
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getuser()
 {
     return $this->hasOne(Authuser::className(), ['auth_user_id' => 'user_id'])->from(['user' => Authuser::tableName()]);
 }
コード例 #4
0
ファイル: Employee.php プロジェクト: vovancho/yii2test
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getIdperson()
 {
     return $this->hasOne(Authuser::className(), ['auth_user_id' => 'id_person'])->from(['idperson' => Authuser::tableName()]);
 }