|
@@ -34,7 +34,7 @@
|
|
v-model="vxCodeShow"
|
|
v-model="vxCodeShow"
|
|
:footer-hide="true"
|
|
:footer-hide="true"
|
|
width="300px">
|
|
width="300px">
|
|
- <VueQr id="vx-qrcode" :text="'http://aseanweb.info666.com/#/content/'+id" :size="200" :data-bd-imgshare-binded="0"></VueQr>
|
|
|
|
|
|
+ <vue-qr id="vx-qrcode" :text="'http://aseanweb.info666.com/#/content/'+id" :size="200" :data-bd-imgshare-binded="0"></vue-qr>
|
|
<p>打开微信,点击底部的“发现”,使用“扫一扫”即可将网页分享至朋友圈。</p>
|
|
<p>打开微信,点击底部的“发现”,使用“扫一扫”即可将网页分享至朋友圈。</p>
|
|
</Modal>
|
|
</Modal>
|
|
</a>
|
|
</a>
|
|
@@ -51,7 +51,10 @@
|
|
<div class="con-img-box" v-html="content"></div>
|
|
<div class="con-img-box" v-html="content"></div>
|
|
<div class="keyword" v-if="keywords">
|
|
<div class="keyword" v-if="keywords">
|
|
<span>关键字:</span>
|
|
<span>关键字:</span>
|
|
- <a v-for="item in keywords.split(' ')" @click="keywordList(item)" class="line-one" style="-webkit-box-orient: vertical;margin: 0 5px">{{item}}</a>
|
|
|
|
|
|
+ <span v-for="item in keywords.split(' ')">
|
|
|
|
+ <a @click="keywordList(item)" class="line-one" style="-webkit-box-orient: vertical;margin: 0 5px">{{item}}</a>
|
|
|
|
+ </span>
|
|
|
|
+
|
|
</div>
|
|
</div>
|
|
<div class="author"><span>【编辑:{{author}}】</span></div>
|
|
<div class="author"><span>【编辑:{{author}}】</span></div>
|
|
</div>
|
|
</div>
|
|
@@ -181,9 +184,57 @@ export default {
|
|
},
|
|
},
|
|
};
|
|
};
|
|
},
|
|
},
|
|
- async asyncData ({ query }) {
|
|
|
|
- console.log(query,'query')
|
|
|
|
- // this.id = parseInt( query.id )
|
|
|
|
|
|
+ async asyncData ({query}) {
|
|
|
|
+ let arr=[];
|
|
|
|
+ let picPath="http://pic-asean2.oss-cn-hongkong.aliyuncs.com/";
|
|
|
|
+ let swiperList=[];
|
|
|
|
+ let keywords='';
|
|
|
|
+ let columnName='';
|
|
|
|
+ let [conData,imgObj] = await Promise.all([
|
|
|
|
+ getInfoDetail({reqdata: {infoId: query.id}}),
|
|
|
|
+ getColumnAd({ reqdata: { adPosition: "column" } }),
|
|
|
|
+ ]);
|
|
|
|
+
|
|
|
|
+ conData.object.relateList.map((item,index)=>{
|
|
|
|
+ if(index<12){
|
|
|
|
+ arr.push({
|
|
|
|
+ path: picPath + item.infoimg,
|
|
|
|
+ infoId: item.infoId,
|
|
|
|
+ title:item.title
|
|
|
|
+ })
|
|
|
|
+ if((index+1)%3==0){
|
|
|
|
+ swiperList.push(arr);
|
|
|
|
+ arr=[];
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ arr.length?swiperList.push(arr):null;
|
|
|
|
+
|
|
|
|
+ keywords = conData.object.keywords;
|
|
|
|
+ if (conData.object.columnName.includes("-")) {
|
|
|
|
+ columnName = conData.object.columnName.split("-");
|
|
|
|
+ } else {
|
|
|
|
+ columnName = conData.object.columnName;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ return{
|
|
|
|
+ type : conData.object.infoType,
|
|
|
|
+ content : conData.object.articleContent,
|
|
|
|
+ title : conData.object.title,
|
|
|
|
+ summary: conData.object.summary,
|
|
|
|
+ upTime : conData.object.uptimeStr,
|
|
|
|
+ list : conData.list,
|
|
|
|
+ vurl : "http://video-asean2.oss-cn-hongkong.aliyuncs.com/" + conData.object.vurl,
|
|
|
|
+ columnId : conData.object.columnId,
|
|
|
|
+ srcname : conData.object.srcname,
|
|
|
|
+ author : conData.object.managerName || '',
|
|
|
|
+ listData:conData.object.relateList||[],
|
|
|
|
+ swiperList,
|
|
|
|
+ keywords,
|
|
|
|
+ columnName,
|
|
|
|
+ imgPath:imgObj.object?imgObj.object.adimg:'',
|
|
|
|
+ imgTo:imgObj.object?imgObj.object.adurl:''
|
|
|
|
+ }
|
|
},
|
|
},
|
|
beforeCreate(){
|
|
beforeCreate(){
|
|
},
|
|
},
|
|
@@ -193,8 +244,10 @@ export default {
|
|
mounted() {
|
|
mounted() {
|
|
|
|
|
|
this.id = parseInt( this.$route.query.id )
|
|
this.id = parseInt( this.$route.query.id )
|
|
|
|
+ Bus.$emit("columnId", this.columnId);
|
|
window._bd_share_main = "";
|
|
window._bd_share_main = "";
|
|
- this.getData(this.id);
|
|
|
|
|
|
+ this.shareArt();
|
|
|
|
+ // this.getData(this.id);
|
|
},
|
|
},
|
|
// computed: {
|
|
// computed: {
|
|
// swiperTop () {
|
|
// swiperTop () {
|
|
@@ -218,7 +271,6 @@ export default {
|
|
methods: {
|
|
methods: {
|
|
// ...mapMutations(["setColumnId"]),
|
|
// ...mapMutations(["setColumnId"]),
|
|
getData(id) {
|
|
getData(id) {
|
|
- console.log(id, "id_+_+___________");
|
|
|
|
let params = {
|
|
let params = {
|
|
reqdata: {
|
|
reqdata: {
|
|
infoId: id
|
|
infoId: id
|
|
@@ -252,7 +304,6 @@ export default {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
arr.length?this.swiperList.push(arr):null;
|
|
arr.length?this.swiperList.push(arr):null;
|
|
- console.log(this.swiperList,"this.swiperList")
|
|
|
|
|
|
|
|
this.keywords = res.object.keywords;
|
|
this.keywords = res.object.keywords;
|
|
if (res.object.columnName.includes("-")) {
|
|
if (res.object.columnName.includes("-")) {
|
|
@@ -292,7 +343,7 @@ export default {
|
|
keywordList(keyword){
|
|
keywordList(keyword){
|
|
// this.$store.dispatch('saveKeyword',keyword);
|
|
// this.$store.dispatch('saveKeyword',keyword);
|
|
// this.$router.push({ name:'lists'})
|
|
// this.$router.push({ name:'lists'})
|
|
- let routeData = this.$router.resolve({name:'lists',params:{id:keyword}});
|
|
|
|
|
|
+ let routeData = this.$router.resolve({path:'/lists',query:{id:keyword}});
|
|
window.open(routeData.href, '_blank');
|
|
window.open(routeData.href, '_blank');
|
|
},
|
|
},
|
|
|
|
|