This commit is contained in:
aixianling
2023-03-21 11:09:07 +08:00
parent bacb186def
commit 3fcc993913

View File

@@ -76,7 +76,7 @@
<h3>{{ item.createUserName }}</h3>
<span v-if="item.publishDepartName">{{ item.publishDepartName }}</span>
</div>
<image hover-stop-propagation @click.stop="removeComment(item.id)" class="remove" src="https://cdn.cunwuyun.cn/wxmp/fengdu/ic-delete.png" />
<image hover-stop-propagation @click.stop="removeLike(item.id)" class="remove" src="https://cdn.cunwuyun.cn/wxmp/fengdu/ic-delete.png" />
</div>
<div class="item-content">
<span v-if="item.themeId" @click.stop="$linkTo('./TopicDetail?themeId=' + item.themeId + '&name=' + item.topicName)">#{{ item.topicName }}</span>
@@ -106,7 +106,7 @@
<div class="comment-item" v-for="(item, index) in list" :key="index">
<div class="comment-top">
<span>{{ item.myComment.createTime }}</span>
<image hover-stop-propagation @click.stop="removeComment(item.id)" class="remove" src="https://cdn.cunwuyun.cn/wxmp/fengdu/ic-delete.png" />
<image hover-stop-propagation @click.stop="removeComment(item.myComment.id)" class="remove" src="https://cdn.cunwuyun.cn/wxmp/fengdu/ic-delete.png" />
</div>
<p>{{ item.myComment.content }}</p>
<div
@@ -142,7 +142,6 @@
appName: '我的帖子',
navigationBarBackgroundColor: '#ffffff',
navigationBarTextStyle: 'black',
data () {
return {
currIndex: 0,
@@ -208,7 +207,21 @@
})
}).catch(() => {})
},
removeLike(id){
this.$dialog.confirm({
title: '温馨提示',
content: '您确定取消点赞吗?'
}).then(() => {
this.$instance.post(`/app/appneighborhoodassistance/appreciate?id=${id}`).then(res => {
if (res.code === 0) {
this.$toast('删除成功!')
this.getInfo()
uni.$emit('updateList')
this.changeTab(this.currIndex)
}
})
}).catch(() => 0)
},
removeComment (id) {
this.$dialog.confirm({
title: '温馨提示',
@@ -224,7 +237,6 @@
})
}).catch(() => {})
},
changeTab (index) {
this.currIndex = index
this.isMore = false
@@ -270,13 +282,11 @@
}
})
}
if (res.data.records.length < 10) {
this.isMore = true
return false
}
this.current = this.current + 1
} else {
this.isMore = true