/** * @return \yii\db\ActiveQuery */ public function getCity() { return $this->hasOne(ReceivedCity::className(), ['code' => 'city_code']); }
/** * @return \yii\db\ActiveQuery */ public function getCity() { return $this->hasMany(ReceivedCity::className(), ['country_code' => 'code'])->with('translations'); }