/** * @return \yii\db\ActiveQuery */ public function getComments() { return $this->hasMany(Comments::className(), ['idtodo' => 'idtodo']); }
/** * @return \yii\db\ActiveQuery */ public function getComments() { return $this->hasMany(Comments::className(), ['article_id' => 'id']); }