作者 lyh

gx

... ... @@ -671,7 +671,7 @@ class BTemplateLogic extends BaseLogic
{
//定义数据结构
$data = $this->model->product_type;
$productCategory = $this->getCategoryList((new Category()));
$productCategory = $this->getCategoryList((new Category()),1);
$newCategory = $this->getCategoryList((new NewsCategory()));
$blogCategory = $this->getCategoryList((new BlogCategory()));
if (!empty($productCategory)){
... ... @@ -694,7 +694,7 @@ class BTemplateLogic extends BaseLogic
* @method :post
* @time :2023/12/20 10:26
*/
public function getCategoryList($categoryModel){
public function getCategoryList($categoryModel,$status = 0){
$data = array();
$list = $categoryModel->list(['pid'=>0,'status'=>1]);
foreach ($list as $v){
... ... @@ -707,6 +707,7 @@ class BTemplateLogic extends BaseLogic
return $this->success($data);
}
/**
* @remark :保存html
* @name :savePublicTemplateHtml
... ...
... ... @@ -38,7 +38,8 @@ class CountLogic extends BaseLogic
];
$info = $this->model->read($param,['pv_num','ip_num','inquiry_num','date','compliance_day','service_day','country']);
if($info === false){
$info = [];
$info = $this->model->read(['project_id' => $this->user['project_id']],
['pv_num','ip_num','inquiry_num','date','compliance_day','service_day','country']);
}
return $this->success($info);
}
... ...