vhost init...3

This commit is contained in:
최준흠 2024-05-17 23:46:32 +09:00
parent f6cb3984d2
commit 7916447a5b
2 changed files with 9 additions and 5 deletions

View File

@ -3,9 +3,8 @@
namespace App\Cells;
use App\Models\CategoryModel;
use CodeIgniter\View\Cells\Cell;
class BaseCell extends Cell
class BaseCell
{
private $_categoryModel = null;

View File

@ -2,8 +2,9 @@
namespace App\Cells;
use App\Cells\BaseCell;
use App\Models\CategoryModel;
use App\Models\BoardModel;
use App\Cells\BaseCell;
class BoardCell extends BaseCell
{
@ -14,12 +15,16 @@ class BoardCell extends BaseCell
}
public function information(array $cellDatas = [])
{
//dd($cellDatas);
helper('Board');
$cellDatas['currentCategory'] = $this->getCategoryModel()->getEntity([
'uid' => __FUNCTION__
]);
$cellDatas['entitys'] = $this->getBoardModel()->getEntitys([
'category' => __FUNCTION__
'category' => $cellDatas['currentCategory']->getPrimaryKey()
]);
return view(
'Views/cells/board/' . __FUNCTION__,
'Views/cells/board/' . $cellDatas['currentCategory']->getPrimaryKey(),
['cellDatas' => $cellDatas]
);
}