This commit is contained in:
Gdpao
2020-08-07 19:56:47 +08:00
parent 71e984b2ed
commit 502e020000
17 changed files with 238 additions and 136 deletions

View File

@@ -18,7 +18,7 @@
<!-- 评论 -->
<view class="operat pinglun">
<u-icon name="more-circle-fill" :color=" is_content ? '#FF7807' : '#ffffff' " :size="50" @click="editing()"></u-icon>
<text>{{item.comment_num}}</text>
<text>{{ comment_num }}</text>
</view>
<!-- 购物车 -->
<view class="operat gouwu">
@@ -74,7 +74,7 @@
<script>
export default {
name:'userinfo',
props:['list','cart','comment'],
props:['list','cart','comment','num'],
data(){
return {
is_follow: this.list.is_attention || false,
@@ -82,6 +82,7 @@ export default {
is_collect: this.list.is_collect || false,
is_content: false,
is_cart: false,
comment_num: this.list.comment_num || 0,
item: this.list || {}
}
},
@@ -92,15 +93,21 @@ export default {
this.is_follow = this.list.is_attention || false;
this.is_like = this.list.is_like || false;
this.is_collect = this.list.is_collect || false;
this.comment_num = this.list.comment_num || 0;
},
cart(newValue,old) {
// console.log(newValue,old);
// console.log(newValue);
this.is_cart = newValue;
},
comment(newValue,old) {
// console.log(newValue,old);
this.is_content = newValue;
},
num(newVal,old) {
// console.log(newVal);
this.comment_num = newVal;
// this.item.comment_num = newVal;
},
deep: true
},
methods: {