Rename Icinga\Web\Widget\SortBox::applyRequest() to ...::setRequest()

refs #9220
This commit is contained in:
Alexander A. Klimov 2015-05-11 14:07:57 +02:00
parent 152c6a8f7f
commit 295254d1d5
2 changed files with 4 additions and 4 deletions

View File

@ -53,7 +53,7 @@ class Controller extends ModuleActionController
$this->view->sortBox = SortBox::create( $this->view->sortBox = SortBox::create(
'sortbox-' . $req->getActionName(), 'sortbox-' . $req->getActionName(),
$columns $columns
)->applyRequest($req); )->setRequest($req);
} }
return $this; return $this;

View File

@ -14,7 +14,7 @@ use Icinga\Web\Request;
* submission of sorting changes and draws an additional submit button when JavaScript is disabled. * submission of sorting changes and draws an additional submit button when JavaScript is disabled.
* *
* The constructor takes an string for the component name and an array containing the select options, where the key is * The constructor takes an string for the component name and an array containing the select options, where the key is
* the value to be submitted and the value is the label that will be shown. You then should call applyRequest in order * the value to be submitted and the value is the label that will be shown. You then should call setRequest in order
* to make sure the form is correctly populated when a request with a sort parameter is being made. * to make sure the form is correctly populated when a request with a sort parameter is being made.
* *
* Example: * Example:
@ -23,7 +23,7 @@ use Icinga\Web\Request;
* $this->getRequest()->getActionName(), * $this->getRequest()->getActionName(),
* $columns * $columns
* ); * );
* $this->view->sortControl->applyRequest($this->getRequest()); * $this->view->sortControl->setRequest($this->getRequest());
* </code></pre> * </code></pre>
*/ */
class SortBox extends AbstractWidget class SortBox extends AbstractWidget
@ -81,7 +81,7 @@ class SortBox extends AbstractWidget
* *
* @return $this * @return $this
*/ */
public function applyRequest($request) public function setRequest($request)
{ {
$this->request = $request; $this->request = $request;
return $this; return $this;