diff --git a/code/app/home/view/videoBoKu/base.html b/code/app/home/view/videoBoKu/base.html index f0395e4..235e96a 100644 --- a/code/app/home/view/videoBoKu/base.html +++ b/code/app/home/view/videoBoKu/base.html @@ -14,7 +14,7 @@ - + {// PWA 支持(Chrome/安卓)和 SEO 不是强关联 } @@ -26,7 +26,7 @@ - + diff --git a/code/app/home/view/videoDadi/base.html b/code/app/home/view/videoDadi/base.html index a902d9e..c885c2a 100644 --- a/code/app/home/view/videoDadi/base.html +++ b/code/app/home/view/videoDadi/base.html @@ -13,7 +13,7 @@ - + {// PWA 支持(Chrome/安卓)和 SEO 不是强关联 } @@ -23,7 +23,8 @@ {block name="title"}{/block} - + + {// 提前加载 CSS } diff --git a/code/app/home/view/videoDingZhu/base.html b/code/app/home/view/videoDingZhu/base.html index 0d3983d..202b8c5 100644 --- a/code/app/home/view/videoDingZhu/base.html +++ b/code/app/home/view/videoDingZhu/base.html @@ -14,7 +14,7 @@ - + {// PWA 支持(Chrome/安卓)和 SEO 不是强关联 } @@ -26,7 +26,7 @@ - + diff --git a/code/app/home/view/videoLaoNiu/base.html b/code/app/home/view/videoLaoNiu/base.html index 9b26dce..1602819 100644 --- a/code/app/home/view/videoLaoNiu/base.html +++ b/code/app/home/view/videoLaoNiu/base.html @@ -14,7 +14,7 @@ - + {// PWA 支持(Chrome/安卓)和 SEO 不是强关联 } @@ -26,8 +26,8 @@ - - + + diff --git a/code/app/home/view/videoNuNu/base.html b/code/app/home/view/videoNuNu/base.html index 8cd26cf..6011385 100644 --- a/code/app/home/view/videoNuNu/base.html +++ b/code/app/home/view/videoNuNu/base.html @@ -14,7 +14,7 @@ - + {// PWA 支持(Chrome/安卓)和 SEO 不是强关联 } @@ -26,7 +26,7 @@ - + diff --git a/code/app/services/SiteContext.php b/code/app/services/SiteContext.php index 69c05d7..2755a97 100644 --- a/code/app/services/SiteContext.php +++ b/code/app/services/SiteContext.php @@ -103,8 +103,7 @@ class SiteContext $this->DomainModel = DomainModel::getDomainOnCacheByDomain($strDomain); - $this->TpStyle = SiteStyle::getConfig(); - $this->UrlBuilder = new UrlBuilder($this->TpStyle); + if (empty($this->DomainModel)) { throw new HttpException(404, 'Site config not Found'); @@ -112,6 +111,9 @@ class SiteContext $this->TemplatesModel = TemplatesModel::getTemplateOnCacheByTId($this->DomainModel->t_id); + $this->TpStyle = SiteStyle::getConfig(); + $this->UrlBuilder = new UrlBuilder($this->TpStyle); + if (empty($this->TemplatesModel)) { throw new HttpException(500, 'Site template not Found'); } @@ -184,15 +186,12 @@ class SiteContext View::assign("strYouQingLiangJieTemp", $strYouQingLiangJieTemp); } - // 视频站点需要信息 - $strEmail = SystemConfigModel::getValByCode('YOU_XIANG'); // 1. 站点 DNA $TpStyle = $this->TpStyle; define('SITE_SEED', $TpStyle['seed']); // 你已有的站点 seed - // 3. 构建本域名 CSS(合并并替换 __PFX__) $strCssUrl = CssBuilder::build( $TpStyle['css_files'], @@ -210,9 +209,11 @@ class SiteContext View::assign('TpStyle', $TpStyle); View::assign('strTpCss', $strCssUrl); View::assign('strTpJs', $strJsUrl); - View::assign('strEmail', $strEmail); - // View::assign('Url', new UrlBuilder($TpStyle)); + // 视频站点需要信息 + $strEmail = SystemConfigModel::getValByCode('YOU_XIANG'); + + View::assign('strEmail', $strEmail); $vod_list = $this->DomainModel; View::assign('vod_list', $vod_list);