Merge branch 'hotfix/baiduJsonLd' into 'hotfix/sale'
'非mip页面不须要加载baidu-js' See merge request !1206
Showing
4 changed files
with
4 additions
and
1 deletions
@@ -307,6 +307,7 @@ const index = (req, res, next) => { | @@ -307,6 +307,7 @@ const index = (req, res, next) => { | ||
307 | isShare: isShare, | 307 | isShare: isShare, |
308 | id: id, | 308 | id: id, |
309 | showAnaJson: { | 309 | showAnaJson: { |
310 | + mipsite: true, | ||
310 | miptitle: data.title, | 311 | miptitle: data.title, |
311 | mipPublishTime: guang.detail.publishTime, | 312 | mipPublishTime: guang.detail.publishTime, |
312 | mipPic: mipPic, | 313 | mipPic: mipPic, |
@@ -216,6 +216,7 @@ const detailIndex = (req, res, next) => { | @@ -216,6 +216,7 @@ const detailIndex = (req, res, next) => { | ||
216 | currentHref: `https://m.yohobuy.com/guang/${id}.html` | 216 | currentHref: `https://m.yohobuy.com/guang/${id}.html` |
217 | }, | 217 | }, |
218 | showAnaJson: { | 218 | showAnaJson: { |
219 | + mipsite: false, | ||
219 | miptitle: `${detail.getArticle.article_title} | Yoho!Buy有货 | 潮流购物逛不停`, | 220 | miptitle: `${detail.getArticle.article_title} | Yoho!Buy有货 | 潮流购物逛不停`, |
220 | mipId: id, | 221 | mipId: id, |
221 | mipPublishTime: mipPublishTime, | 222 | mipPublishTime: mipPublishTime, |
@@ -85,6 +85,7 @@ const newDetail = { | @@ -85,6 +85,7 @@ const newDetail = { | ||
85 | appPath: appPath, | 85 | appPath: appPath, |
86 | isMarsApp: req.yoho.isMarsApp, // 判断mars | 86 | isMarsApp: req.yoho.isMarsApp, // 判断mars |
87 | showAnaJson: { | 87 | showAnaJson: { |
88 | + mipsite: true, | ||
88 | miptitle: title, | 89 | miptitle: title, |
89 | mipPublishTime: moment.unix(result.shelveTime).format('YYYY-MM-DDTHH:mm:ss'), // mip日期必填 | 90 | mipPublishTime: moment.unix(result.shelveTime).format('YYYY-MM-DDTHH:mm:ss'), // mip日期必填 |
90 | mipPic: mipPic, | 91 | mipPic: mipPic, |
1 | {{# showAnaJson}} | 1 | {{# showAnaJson}} |
2 | -<script src="//msite.baidu.com/sdk/c.js?appid=1583402501013173"></script> | 2 | +{{#if mipsite}}<script src="//msite.baidu.com/sdk/c.js?appid=1583402501013173"></script>{{/if}} |
3 | <script type="application/ld+json"> | 3 | <script type="application/ld+json"> |
4 | { | 4 | { |
5 | "@context": "https://ziyuan.baidu.com/contexts/cambrian.jsonld", | 5 | "@context": "https://ziyuan.baidu.com/contexts/cambrian.jsonld", |
-
Please register or login to post a comment