正在显示
1 个修改的文件
包含
6 行增加
和
3 行删除
| @@ -235,7 +235,7 @@ class BTemplateLogic extends BaseLogic | @@ -235,7 +235,7 @@ class BTemplateLogic extends BaseLogic | ||
| 235 | $bTemplateMainModel = new BTemplateMain(); | 235 | $bTemplateMainModel = new BTemplateMain(); |
| 236 | $mainInfo = $bTemplateMainModel->read(['project_id'=>$this->user['project_id'],'type'=>$type]); | 236 | $mainInfo = $bTemplateMainModel->read(['project_id'=>$this->user['project_id'],'type'=>$type]); |
| 237 | if($mainInfo === false){ | 237 | if($mainInfo === false){ |
| 238 | - $data['main_html'] = $this->getModule($type,$is_custom); | 238 | + $data['main_html'] = $this->getModule($type); |
| 239 | $data['main_css'] = "<style id='globalsojs-styles'></style>"; | 239 | $data['main_css'] = "<style id='globalsojs-styles'></style>"; |
| 240 | }else{ | 240 | }else{ |
| 241 | $data['main_html'] = $mainInfo['main_html']; | 241 | $data['main_html'] = $mainInfo['main_html']; |
| @@ -621,7 +621,7 @@ class BTemplateLogic extends BaseLogic | @@ -621,7 +621,7 @@ class BTemplateLogic extends BaseLogic | ||
| 621 | * @method :post | 621 | * @method :post |
| 622 | * @time :2023/7/27 15:08 | 622 | * @time :2023/7/27 15:08 |
| 623 | */ | 623 | */ |
| 624 | - public function getModule($type,$is_custom){ | 624 | + public function getModule($type){ |
| 625 | $mainModel = new TemplateTypeMain(); | 625 | $mainModel = new TemplateTypeMain(); |
| 626 | $info = $mainModel->read(['type'=>$type]); | 626 | $info = $mainModel->read(['type'=>$type]); |
| 627 | return $info['main_html']; | 627 | return $info['main_html']; |
| @@ -844,7 +844,10 @@ class BTemplateLogic extends BaseLogic | @@ -844,7 +844,10 @@ class BTemplateLogic extends BaseLogic | ||
| 844 | $bTemplateMainModel = new BTemplateMain(); | 844 | $bTemplateMainModel = new BTemplateMain(); |
| 845 | $mainInfo = $bTemplateMainModel->read(['project_id'=>$this->user['project_id'],'type'=>$this->param['type'],'is_custom'=>$is_custom]); | 845 | $mainInfo = $bTemplateMainModel->read(['project_id'=>$this->user['project_id'],'type'=>$this->param['type'],'is_custom'=>$is_custom]); |
| 846 | if($mainInfo === false){ | 846 | if($mainInfo === false){ |
| 847 | - $main_html = $this->getModule($this->param['type'],$is_custom); | 847 | + if($is_custom == BTemplate::SOURCE_CUSTOM) { |
| 848 | + $this->param['type'] = BTemplate::TYPE_CUSTOM_DETAIL; | ||
| 849 | + } | ||
| 850 | + $main_html = $this->getModule($this->param['type']); | ||
| 848 | $main_style = "<style id='globalsojs-styles'></style>"; | 851 | $main_style = "<style id='globalsojs-styles'></style>"; |
| 849 | }else{ | 852 | }else{ |
| 850 | $main_html = $mainInfo['main_html']; | 853 | $main_html = $mainInfo['main_html']; |
-
请 注册 或 登录 后发表评论