Пример #1
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getIdWarehouse()
 {
     return $this->hasOne(Warehouse::className(), ['id_warehouse' => 'id_warehouse']);
 }
Пример #2
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getWarehouses()
 {
     return $this->hasMany(Warehouse::className(), ['id_branch' => 'id_branch']);
 }