예제 #1
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getBasket()
 {
     return $this->hasOne(Basket::className(), ['id' => 'basket_id']);
 }
예제 #2
0
파일: Items.php 프로젝트: koakumasd/shop
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getBaskets()
 {
     return $this->hasMany(Basket::className(), ['item_id' => 'id']);
 }