Esempio n. 1
0
 public function getAttrs()
 {
     return $this->hasMany(Attr::className(), ['category_id' => 'id']);
 }
Esempio n. 2
0
 public function getAttr()
 {
     return $this->hasOne(Attr::className(), ['id' => 'attr_id']);
 }