public function getCollection($db = null) { if ($db === null) { $db = Yii::$app->get('mongodb'); } return $db->getCollection($this->from); }