/** * @param int $position */ public function registerClientScript($position = View::POS_END) { $view = Yii::$app->getView(); MapAsset::register($view); $view->registerJs($this->getJs(), $position); }
public function run() { MapAsset::register($this->getView()); return $this->map->display(); }