/** * @return \yii\db\ActiveQuery */ public function getDocumentCategories() { return $this->hasMany(DocumentCategory::className(), ['updated_by' => 'user_id']); }
/** * @return \yii\db\ActiveQuery */ public function getStuDocsCategory() { return $this->hasOne(DocumentCategory::className(), ['doc_category_id' => 'stu_docs_category_id']); }