コード例 #1
0
ファイル: Cellars.php プロジェクト: aekkapun/mysommelier
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getLocations()
 {
     return $this->hasMany(Locations::className(), ['cellar_id' => 'id']);
 }
コード例 #2
0
ファイル: Cellarwines.php プロジェクト: aekkapun/mysommelier
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getCellarLoc()
 {
     return $this->hasOne(Locations::className(), ['cellar_loc_id' => 'cellar_loc_id']);
 }