@@ -96,12 +96,12 @@ |
||
| 96 | 96 | } |
| 97 | 97 | |
| 98 | 98 | return '<ul class="pagination">' . |
| 99 | - $this->_renderListItem($this->_currentPage - 1, $this->_getFirstPageUrl(), $this->_firstPageSymbol) . |
|
| 100 | - $this->_renderListItem($this->_currentPage - 1, $this->_getPreviousPageUrl(), $this->_previousPageSymbol) . |
|
| 101 | - $this->_renderPageList() . |
|
| 102 | - $this->_renderListItem($this->_currentPage + 1, $this->_getNextPageUrl(), $this->_nextPageSymbol) . |
|
| 103 | - $this->_renderListItem($this->_currentPage + 1, $this->_getLastPageUrl(), $this->_lastPageSymbol) . |
|
| 104 | - '</ul>'; |
|
| 99 | + $this->_renderListItem($this->_currentPage - 1, $this->_getFirstPageUrl(), $this->_firstPageSymbol) . |
|
| 100 | + $this->_renderListItem($this->_currentPage - 1, $this->_getPreviousPageUrl(), $this->_previousPageSymbol) . |
|
| 101 | + $this->_renderPageList() . |
|
| 102 | + $this->_renderListItem($this->_currentPage + 1, $this->_getNextPageUrl(), $this->_nextPageSymbol) . |
|
| 103 | + $this->_renderListItem($this->_currentPage + 1, $this->_getLastPageUrl(), $this->_lastPageSymbol) . |
|
| 104 | + '</ul>'; |
|
| 105 | 105 | } |
| 106 | 106 | |
| 107 | 107 | /** |
@@ -120,9 +120,9 @@ |
||
| 120 | 120 | public function render() : string |
| 121 | 121 | { |
| 122 | 122 | return '<form method="get" action="' . $this->_buildSearchUrl() . |
| 123 | - '"><div class="row"><div class="col-md-10"><input name="search" class="form-control data-scout-input" placeholder="' . |
|
| 124 | - $this->_placeholder . '"/></div><div class="col-md-2"><button type="submit" class="btn btn-primary">' . |
|
| 125 | - $this->_buttonText . '</button></div></div></form>'; |
|
| 123 | + '"><div class="row"><div class="col-md-10"><input name="search" class="form-control data-scout-input" placeholder="' . |
|
| 124 | + $this->_placeholder . '"/></div><div class="col-md-2"><button type="submit" class="btn btn-primary">' . |
|
| 125 | + $this->_buttonText . '</button></div></div></form>'; |
|
| 126 | 126 | } |
| 127 | 127 | |
| 128 | 128 | /** |
@@ -138,7 +138,9 @@ discard block |
||
| 138 | 138 | public function addComponent(DataComponent $component, ?string $name = null): DataTable |
| 139 | 139 | { |
| 140 | 140 | $componentName = \str_replace(' ', '', Str::lower($name ?? \class_basename($component))); |
| 141 | - if ($this->componentExists($componentName)) throw new MultipleComponentAssertionException(); |
|
| 141 | + if ($this->componentExists($componentName)) { |
|
| 142 | + throw new MultipleComponentAssertionException(); |
|
| 143 | + } |
|
| 142 | 144 | $this->_components[$componentName] = $component->init($this); |
| 143 | 145 | |
| 144 | 146 | return $this; |
@@ -382,7 +384,9 @@ discard block |
||
| 382 | 384 | */ |
| 383 | 385 | public function __get($name) |
| 384 | 386 | { |
| 385 | - if (\array_key_exists($name, $this->_components)) return $this->_components[$name]; |
|
| 387 | + if (\array_key_exists($name, $this->_components)) { |
|
| 388 | + return $this->_components[$name]; |
|
| 389 | + } |
|
| 386 | 390 | |
| 387 | 391 | return $this->$name; |
| 388 | 392 | } |