/** * @return \yii\db\ActiveQuery */ public function getSnippet() { return $this->hasOne(Snippet::className(), ['id' => 'snippetId']); }
/** * @return \yii\db\ActiveQuery */ public function getSnippets() { return $this->hasMany(Snippet::className(), ['languageId' => 'id']); }