diff --git a/app/Config/Pager.php b/app/Config/Pager.php index e341f4d..4c2a766 100644 --- a/app/Config/Pager.php +++ b/app/Config/Pager.php @@ -24,6 +24,8 @@ class Pager extends BaseConfig 'default_full' => 'CodeIgniter\Pager\Views\default_full', 'default_simple' => 'CodeIgniter\Pager\Views\default_simple', 'default_head' => 'CodeIgniter\Pager\Views\default_head', + 'bootstrap_full' => 'Pagers\bootstrap_full', + 'bootstrap_simple' => 'Pagers\bootstrap_simple', ]; /** diff --git a/app/Controllers/MVController.php b/app/Controllers/MVController.php index d3e4174..c5ed381 100644 --- a/app/Controllers/MVController.php +++ b/app/Controllers/MVController.php @@ -205,26 +205,26 @@ abstract class MVController extends CommonController { //조건절 처리 foreach ($this->filter_fields as $field) { - $this->$field = $this->request->getVar($field) ?? DEFAULTS['EMPTY']; + $this->$field = $this->request->getVar($field) ?: DEFAULTS['EMPTY']; if ($this->$field !== DEFAULTS['EMPTY']) { $this->getMyLibrary()->getMyStorage()->setList_FieldFilter($field, $this->$field); } } //검색어 처리 - $this->word = $this->request->getVar('word') ?? DEFAULTS['EMPTY']; + $this->word = $this->request->getVar('word') ?: DEFAULTS['EMPTY']; if ($this->word !== DEFAULTS['EMPTY']) { $this->getMyLibrary()->getMyStorage()->setList_WordFilter($this->word); } //검색일 처리 - $this->start = $this->request->getVar('start') ?? DEFAULTS['EMPTY']; - $this->end = $this->request->getVar('end') ?? DEFAULTS['EMPTY']; + $this->start = $this->request->getVar('start') ?: DEFAULTS['EMPTY']; + $this->end = $this->request->getVar('end') ?: DEFAULTS['EMPTY']; if ($this->start !== DEFAULTS['EMPTY'] && $this->end !== DEFAULTS['EMPTY']) { $this->getMyLibrary()->getMyStorage()->setList_DateFilter($this->start, $this->end); } if (!$isTotalCount) { //Sorting 처리 - $this->order_field = $this->request->getVar('order_field') ?? DEFAULTS['EMPTY']; - $this->order_value = $this->request->getVar('order_value') ?? DEFAULTS['EMPTY']; + $this->order_field = $this->request->getVar('order_field') ?: DEFAULTS['EMPTY']; + $this->order_value = $this->request->getVar('order_value') ?: DEFAULTS['EMPTY']; if ($this->order_field !== DEFAULTS['EMPTY'] && $this->order_value !== DEFAULTS['EMPTY']) { $this->getMyLibrary()->getMyStorage()->setList_OrderBy("{$this->order_field} {$this->order_value}"); } @@ -237,11 +237,11 @@ abstract class MVController extends CommonController return $this->getMyLibrary()->getMyStorage()->countAllResults(); } //PageNation 처리 - protected function list_pagination($pager_group = 'default', int $segment = 0, $template = 'bootstrap_full'): string + protected function list_pagination($pager_group = 'default', int $segment = 0, $template = 'default_full'): string { //Page, Per_page필요부분 - $this->page = (int)$this->request->getVar('page') ?? 1; - $this->per_page = (int)$this->request->getVar('per_page') ?? $this->_per_page; + $this->page = (int)$this->request->getVar('page') ?: 1; + $this->per_page = (int)$this->request->getVar('per_page') ?: 20; //줄수 처리용 $page_options = array("" => "줄수선택"); for ($i = 10; $i <= $this->total_count + $this->per_page; $i += 10) { @@ -272,7 +272,7 @@ abstract class MVController extends CommonController protected function list_entitys(): array { $this->list_condition(); - if (array_key_exists('page', $this->_viewDatas)) { + if ($this->page) { $this->getMyLibrary()->getMyStorage()->limit( $this->per_page, $this->page * $this->per_page - $this->per_page diff --git a/app/Models/Cloudflare/RecordModel.php b/app/Models/Cloudflare/RecordModel.php index 4db90b8..96e9ba6 100644 --- a/app/Models/Cloudflare/RecordModel.php +++ b/app/Models/Cloudflare/RecordModel.php @@ -1,6 +1,6 @@