This commit is contained in:
2020-07-20 08:43:13 +08:00
parent 113144b716
commit 4c70db7575
4 changed files with 35 additions and 13 deletions

View File

@@ -1,20 +1,20 @@
<template>
<view class="userinfo">
<view class="userhead">
<image></image>
<image :src="list.member_avatar"></image>
<text>+</text>
</view>
<view class="zan">
<image></image>
<text>123</text>
<text>{{list.like_num}}</text>
</view>
<view class="shoucang">
<image></image>
<text>123</text>
<text>{{list.collect_num}}</text>
</view>
<view class="pinglun">
<image></image>
<text>123</text>
<text>{{list.comment_num}}</text>
</view>
<view class="gouwu">
<image></image>
@@ -78,6 +78,7 @@ export default {
return {
}
}
},
props:['list']
}
</script>

View File

@@ -5,11 +5,11 @@
</view>
<swiper class="swiper">
<swiper-item>
<image></image>
<image :src="list.article_pic"></image>
</swiper-item>
<swiper-item>
<!-- <swiper-item>
<image></image>
</swiper-item>
</swiper-item> -->
</swiper>
<view class="bottom">
@@ -21,7 +21,7 @@
<view class="title">hasjdhajskhj</view>
<view class="info u-line-2">asdjhasjdkasljdklasjkl</view>
</view>
<userinfo class="userinfo"></userinfo>
<userinfo class="userinfo" :list="list"></userinfo>
<shpoone class="shpoone"></shpoone>
<shoplist></shoplist>
</view>
@@ -117,6 +117,23 @@ export default {
userinfo,
shpoone,
shoplist
},
data(){
return {
list:{}
}
},
methods:{
articleInfo(article_id){
this.$u.api.articleInfo({article_id}).then((res)=>{
console.log(res)
this.list = res.data.info
})
}
},
onLoad(o){
this.id = o.id
this.articleInfo(this.id)
}
}
</script>