Skip to content
Permalink
Browse files

Use own method instead.

  • Loading branch information...
dereuromark committed Sep 21, 2014
1 parent 1f8c083 commit afb36eecf2b9e14b6cf3541d436e587b1e77261b
Showing with 10 additions and 1 deletion.
  1. +9 −0 src/View/Helper/PaginatorHelper.php
  2. +1 −1 tests/TestCase/View/Helper/PaginatorHelperTest.php
@@ -85,6 +85,15 @@ class PaginatorHelper extends Helper {
public function __construct(View $View, array $config = array()) {
parent::__construct($View, $config);
$this->setUpUrl();
}
/**
* Merges passed args with URL options.
*
* @return void
*/
public function setUpUrl() {
$this->config(
'options.url',
array_merge($this->request->params['pass'], $this->request->query)
@@ -739,7 +739,7 @@ public function testPassedArgsMergingWithUrlOptions() {
$this->Paginator->request->params['pass'] = array(2);
$this->Paginator->request->query = array('page' => 1, 'foo' => 'bar', 'x' => 'y');
$this->Paginator->__construct($this->View);
$this->Paginator->setUpUrl();
$result = $this->Paginator->sort('title');
$expected = array(

0 comments on commit afb36ee

Please sign in to comment.
You can’t perform that action at this time.