/** * @return \yii\db\ActiveQuery */ public function getBrands0() { return $this->hasMany(Brands::className(), ['updatedBy' => 'id']); }
public function getNameBrand() { return $this->hasOne(Brands::className(), ['id' => 'id_brand'])->one()->name; }