예제 #1
0
파일: Movie.php 프로젝트: syungkeaw/m
 /**
  * @Genre handle
  */
 public function getGenre()
 {
     return $this->hasMany(Genre::className(), ['movie_id' => 'id']);
 }
예제 #2
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getMusic()
 {
     return $this->hasOne(Genre::className(), ['Id' => 'musicId']);
 }