19 lines
444 B
PHP
19 lines
444 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
class HeaderController extends BaseController {
|
||
|
|
|
||
|
|
public $model = null;
|
||
|
|
public function __construct()
|
||
|
|
{
|
||
|
|
parent::__construct();
|
||
|
|
$this->model = new HeaderModel();
|
||
|
|
}
|
||
|
|
public function getHeader($params) {
|
||
|
|
|
||
|
|
$header = $this->model->getHeader($params);
|
||
|
|
if (empty($header)) {
|
||
|
|
http_response_code(404);
|
||
|
|
return $this->response(['message' => 'Header not found']);
|
||
|
|
} else return $this->response($header);
|
||
|
|
}
|
||
|
|
}
|