andWhere('author_id=1'); } public function getSource() { $config = [ 'modelClass' => ArticleDb::className(), 'primaryModel' => $this, 'link' => ['id' => 'id'], 'multiple' => false, ]; return new ActiveRelation($config); } public function getSnippetSource() { return $this->source->content; } }