Merge branch 'develop' of http://47.244.231.31:8099/zhl/globalso-v6
正在显示
1 个修改的文件
包含
24 行增加
和
1 行删除
| @@ -3,7 +3,9 @@ | @@ -3,7 +3,9 @@ | ||
| 3 | namespace App\Http\Logic\Bside\BTemplate; | 3 | namespace App\Http\Logic\Bside\BTemplate; |
| 4 | 4 | ||
| 5 | use App\Http\Logic\Bside\BaseLogic; | 5 | use App\Http\Logic\Bside\BaseLogic; |
| 6 | +use App\Models\Blog\Blog; | ||
| 6 | use App\Models\Blog\BlogCategory; | 7 | use App\Models\Blog\BlogCategory; |
| 8 | +use App\Models\News\News; | ||
| 7 | use App\Models\News\NewsCategory; | 9 | use App\Models\News\NewsCategory; |
| 8 | use App\Models\Product\Category; | 10 | use App\Models\Product\Category; |
| 9 | use App\Models\Product\Product; | 11 | use App\Models\Product\Product; |
| @@ -373,8 +375,29 @@ class BTemplateLogic extends BaseLogic | @@ -373,8 +375,29 @@ class BTemplateLogic extends BaseLogic | ||
| 373 | if($source == BTemplate::SOURCE_HOME){ | 375 | if($source == BTemplate::SOURCE_HOME){ |
| 374 | $type = 'index'; | 376 | $type = 'index'; |
| 375 | $route = ''; | 377 | $route = ''; |
| 376 | - return $this->updateNotify(['project_id'=>$this->user['project_id'], 'type'=>$type, 'route'=>$route]); | 378 | + }else{ |
| 379 | + //其他界面通知更新 | ||
| 380 | + if($source == 2 && $source_id != 0){ | ||
| 381 | + $type = RouteMap::SOURCE_PRODUCT; | ||
| 382 | + $productModel = new Product(); | ||
| 383 | + $productInfo = $productModel->read(['id'=>$source_id],['route']); | ||
| 384 | + $route = $productInfo['route']; | ||
| 385 | + }elseif($source == 3 && $source_id != 0){ | ||
| 386 | + $type = RouteMap::SOURCE_BLOG; | ||
| 387 | + $blogModel = new Blog(); | ||
| 388 | + $blogInfo = $blogModel->read(['id'=>$source_id],['route']); | ||
| 389 | + $route = $blogInfo['route']; | ||
| 390 | + }elseif($source == 4 && $source_id != 0){ | ||
| 391 | + $type = RouteMap::SOURCE_NEWS; | ||
| 392 | + $newsModel = new News(); | ||
| 393 | + $newsInfo = $newsModel->read(['id'=>$source_id],['route']); | ||
| 394 | + $route = $newsInfo['route']; | ||
| 395 | + }else{ | ||
| 396 | + $type = 0; | ||
| 397 | + $route = 'all'; | ||
| 398 | + } | ||
| 377 | } | 399 | } |
| 400 | + return $this->updateNotify(['project_id'=>$this->user['project_id'], 'type'=>$type, 'route'=>$route]); | ||
| 378 | return $this->success(); | 401 | return $this->success(); |
| 379 | } | 402 | } |
| 380 | 403 |
-
请 注册 或 登录 后发表评论