| Total Complexity | 4 |
| Total Lines | 41 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | abstract class Controller |
||
| 14 | { |
||
| 15 | public Application $app; |
||
| 16 | public string $layout = 'layout'; |
||
| 17 | public string $title; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * Action Init |
||
| 21 | * @codeCoverageIgnore |
||
| 22 | */ |
||
| 23 | public function init() |
||
| 24 | { |
||
| 25 | } |
||
| 26 | |||
| 27 | /** |
||
| 28 | * Volta para o método index da pagina atual |
||
| 29 | * @codeCoverageIgnore |
||
| 30 | */ |
||
| 31 | protected function backToIndex() |
||
| 32 | { |
||
| 33 | Url::redirect($this->app->getPage()); |
||
| 34 | } |
||
| 35 | |||
| 36 | /** |
||
| 37 | * Redireciona para a URL |
||
| 38 | * @param string $url |
||
| 39 | * @codeCoverageIgnore |
||
| 40 | */ |
||
| 41 | protected function redirect($url) |
||
| 44 | } |
||
| 45 | |||
| 46 | /** |
||
| 47 | * Atualiza a mesma página |
||
| 48 | * @param string $url |
||
| 49 | * @codeCoverageIgnore |
||
| 50 | */ |
||
| 51 | protected function refresh() |
||
| 56 |