|
|
@@ -121,7 +121,8 @@
|
|
|
:href="item.url"
|
|
|
:title="item.name"
|
|
|
>
|
|
|
- {{item.name}} <span v-if="index!==breadcrumbList.length-1"> > </span>
|
|
|
+ <p v-if="index!==breadcrumbList.length-1">{{item.name}} <span> > </span> </p>
|
|
|
+ <h1 v-else>{{item.name}}</h1>
|
|
|
</a>
|
|
|
</div>
|
|
|
<div class="contentArea">
|
|
|
@@ -206,7 +207,10 @@
|
|
|
}, {
|
|
|
'name': 'h1',
|
|
|
'content': `${this.recruitData.title}`
|
|
|
- } ]
|
|
|
+ } ],
|
|
|
+ link: [
|
|
|
+ { rel: 'canonical', href: this.nowUrl},
|
|
|
+ ]
|
|
|
}
|
|
|
},
|
|
|
async asyncData({...params}) {
|
|
|
@@ -240,13 +244,29 @@
|
|
|
|
|
|
let dealSeoFooterObj = new DealSeoFooter(params, recruitData)
|
|
|
let footer = await dealSeoFooterObj.dealData()
|
|
|
+
|
|
|
+ let nowUrl = ""
|
|
|
+ try {
|
|
|
+ const { headers: {host} } = params.app.context.req || {};
|
|
|
+ let { fullPath } = params.app.context.route
|
|
|
+ //设置baseLink
|
|
|
+ if (host.indexOf('local') !== -1) {
|
|
|
+ nowUrl = 'http://' + host + fullPath
|
|
|
+ } else {
|
|
|
+ nowUrl = 'https://' + host + fullPath
|
|
|
+ }
|
|
|
+ } catch (e) {
|
|
|
+ console.log(e)
|
|
|
+ }
|
|
|
+
|
|
|
return {
|
|
|
+ nowUrl: nowUrl,
|
|
|
android,
|
|
|
recruitId: recruitId,
|
|
|
recruitData,
|
|
|
mobile: params.app.$deviceType.isMobile(),
|
|
|
- footer,
|
|
|
- breadcrumbList: dealBreadcrumbList
|
|
|
+ breadcrumbList: dealBreadcrumbList,
|
|
|
+ ...footer,
|
|
|
}
|
|
|
},
|
|
|
|