|
|
|
@ -54,6 +54,22 @@
|
|
|
|
|
<p class="comment--ctx">{{ detailData.followComment.commentContent }}</p>
|
|
|
|
|
</template>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="title">
|
|
|
|
|
<b>商家回复</b>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<ul class="reply" v-if="detailData.merchantComment">
|
|
|
|
|
<li class="reply--item">
|
|
|
|
|
<div class="reply--title">
|
|
|
|
|
{{ detailData.merchantComment.userName }}
|
|
|
|
|
<span>({{ detailData.merchantComment.createTime }}) 回复 :</span>
|
|
|
|
|
</div>
|
|
|
|
|
<p class="reply--ctx">{{ detailData.merchantComment.commentContent }}</p>
|
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
|
|
|
|
<div class="reply__emtpy" v-else>暂无内容</div>
|
|
|
|
|
|
|
|
|
|
<div class="title">
|
|
|
|
|
<b>全部回复({{ detailData.answerCommentList?.length || 0 }}条)</b>
|
|
|
|
|
</div>
|
|
|
|
@ -174,11 +190,8 @@
|
|
|
|
|
state.isSubmit = true;
|
|
|
|
|
let data = {
|
|
|
|
|
commentContent: state.commentContent,
|
|
|
|
|
commentType: 3,
|
|
|
|
|
parentId: state.reply.id || detailData.value.id,
|
|
|
|
|
parentId: detailData.value.id,
|
|
|
|
|
originId: detailData.value.id,
|
|
|
|
|
userId: store.state.auth.userInfo.userId,
|
|
|
|
|
userType: 1,
|
|
|
|
|
};
|
|
|
|
|
// 需要返回ID或对象 去登录用户的userName不对
|
|
|
|
|
const res = await store.dispatch('comment/add', data);
|
|
|
|
@ -188,8 +201,6 @@
|
|
|
|
|
detailData.value.answerCommentList.push({
|
|
|
|
|
...res,
|
|
|
|
|
isShow: true,
|
|
|
|
|
parentUserName: state.reply.userName,
|
|
|
|
|
userName: store.state.auth.userInfo.userName,
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
</script>
|
|
|
|
|