Commit 955dc088 by Max Lapko

Change magic methods to getters

parent 236230e8
...@@ -26,8 +26,9 @@ class Toolbar extends Widget ...@@ -26,8 +26,9 @@ class Toolbar extends Widget
$url = Yii::$app->getUrlManager()->createUrl($this->debugAction, array( $url = Yii::$app->getUrlManager()->createUrl($this->debugAction, array(
'tag' => Yii::getLogger()->tag, 'tag' => Yii::getLogger()->tag,
)); ));
$this->view->registerJs("yii.debug.load('$id', '$url');"); $view = $this->getView();
$this->view->registerAssetBundle('yii/debug'); $view->registerJs("yii.debug.load('$id', '$url');");
$view->registerAssetBundle('yii/debug');
echo Html::tag('div', '', array( echo Html::tag('div', '', array(
'id' => $id, 'id' => $id,
'style' => 'display: none', 'style' => 'display: none',
......
...@@ -122,7 +122,7 @@ class LinkPager extends Widget ...@@ -122,7 +122,7 @@ class LinkPager extends Widget
{ {
$buttons = array(); $buttons = array();
$pageCount = $this->pagination->pageCount; $pageCount = $this->pagination->getPageCount();
$currentPage = $this->pagination->getPage(); $currentPage = $this->pagination->getPage();
// first page // first page
......
...@@ -63,7 +63,7 @@ class ListPager extends Widget ...@@ -63,7 +63,7 @@ class ListPager extends Widget
*/ */
public function run() public function run()
{ {
$pageCount = $this->pagination->pageCount; $pageCount = $this->pagination->getPageCount();
$currentPage = $this->pagination->getPage(); $currentPage = $this->pagination->getPage();
$pages = array(); $pages = array();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment