feature/comment-0624-ch
ch 2 years ago
parent e17951e223
commit 09ba7e8819

@ -2,7 +2,7 @@
* @Author: ch * @Author: ch
* @Date: 2022-06-24 11:43:04 * @Date: 2022-06-24 11:43:04
* @LastEditors: ch * @LastEditors: ch
* @LastEditTime: 2022-06-30 14:27:38 * @LastEditTime: 2022-06-30 19:46:42
* @Description: file content * @Description: file content
--> -->
<template> <template>
@ -22,7 +22,7 @@
<template v-else> <template v-else>
<div class="top"> <div class="top">
<el-rate :value="commentDetail.commentScore" disabled/> <el-rate :value="commentDetail.commentScore" disabled/>
<span class="time">{{commentDetail.createTime}}</span> <span class="time">{{FormatDate(commentDetail.createTime, 'yyyy-mm-dd hh:ii')}}</span>
</div> </div>
<p class="sku">已购买{{commentDetail.skuName}}</p> <p class="sku">已购买{{commentDetail.skuName}}</p>
<div class="ctx">{{commentDetail.commentContent}}</div> <div class="ctx">{{commentDetail.commentContent}}</div>
@ -64,7 +64,7 @@
<li class="answer--item" v-for="(item, idx) in answerCommentList" :key="idx"> <li class="answer--item" v-for="(item, idx) in answerCommentList" :key="idx">
<div class="answer--name"> <div class="answer--name">
<b>{{item.userName}} {{item.parentId !== commentDetail.id ? ` 回复 ${item.parentUserName}` : ''}}</b> <b>{{item.userName}} {{item.parentId !== commentDetail.id ? ` 回复 ${item.parentUserName}` : ''}}</b>
<span>{{item.createTime}}</span> <span>{{FormatDate(item.createTime, 'yyyy-mm-dd hh:ii')}}</span>
</div> </div>
<p class="answer--ctx">{{item.commentContent}}</p> <p class="answer--ctx">{{item.commentContent}}</p>
<span class="answer--answer" @click="handleAnswer(item)"></span> <span class="answer--answer" @click="handleAnswer(item)"></span>
@ -87,7 +87,7 @@
<script> <script>
import BsCommentFollowInfo from './BsCommentFollowInfo.vue'; import BsCommentFollowInfo from './BsCommentFollowInfo.vue';
import {ApiPostComment, ApiPutCommentUseful} from '@/plugins/api/comment'; import {ApiPostComment, ApiPutCommentUseful} from '@/plugins/api/comment';
import {Debounce } from '@/plugins/utils'; import {Debounce, FormatDate } from '@/plugins/utils';
import UiImgs from './UiImgs.vue'; import UiImgs from './UiImgs.vue';
import UiButton from './UiButton.vue'; import UiButton from './UiButton.vue';
import BsCommentSubmit from './BsCommentSubmit.vue'; import BsCommentSubmit from './BsCommentSubmit.vue';
@ -159,6 +159,7 @@ export default {
this.answerCommentList = this.commentDetail.answerCommentList || []; this.answerCommentList = this.commentDetail.answerCommentList || [];
}, },
methods : { methods : {
FormatDate,
/** /**
* 评价成功后抛出事件方便父组件做数据处理 * 评价成功后抛出事件方便父组件做数据处理
*/ */
@ -289,6 +290,10 @@ export default {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
margin-bottom: 10px; margin-bottom: 10px;
/deep/.el-rate__icon{
margin-right: 0;
font-size: 24px;
}
} }
.time, .sku{ .time, .sku{
color: #999; color: #999;
@ -388,6 +393,12 @@ export default {
} }
&--btn{ &--btn{
height: 40px; height: 40px;
font-size: 14px;
}
/deep/.ui-button__disabled{
background: #eee;
color: #999;
} }
} }
</style> </style>

@ -2,7 +2,7 @@
* @Author: ch * @Author: ch
* @Date: 2022-06-24 19:07:45 * @Date: 2022-06-24 19:07:45
* @LastEditors: ch * @LastEditors: ch
* @LastEditTime: 2022-06-30 11:40:54 * @LastEditTime: 2022-06-30 19:40:36
* @Description: file content * @Description: file content
--> -->
<template> <template>
@ -82,6 +82,7 @@ export default {
width: 300px; width: 300px;
margin-top: 20px; margin-top: 20px;
position: relative; position: relative;
border: 1px solid #eee;
img{ img{
width: 300px; width: 300px;
height: 300px; height: 300px;
@ -116,11 +117,11 @@ export default {
top: 16px; top: 16px;
} }
&.prev{ &.prev{
left: 0; left: 10px;
} }
&.next{ &.next{
right: 0; right: 10px;
&::after{ &::after{
left: 20px; left: 20px;
transform: rotate(45deg); transform: rotate(45deg);

@ -2,7 +2,7 @@
* @Author: ch * @Author: ch
* @Date: 2022-05-09 14:41:37 * @Date: 2022-05-09 14:41:37
* @LastEditors: ch * @LastEditors: ch
* @LastEditTime: 2022-06-28 21:58:08 * @LastEditTime: 2022-06-30 20:01:46
* @Description: file content * @Description: file content
--> -->
<template> <template>
@ -53,6 +53,7 @@ export default {
'5' : {name:'已收货'}, '5' : {name:'已收货'},
// //
'6' : {name:'交易成功'}, '6' : {name:'交易成功'},
'7' : {name:'交易成功'},
}, },
ctxCon : {}, ctxCon : {},
startSecondNum : 0, startSecondNum : 0,

@ -2,7 +2,7 @@
* @Author: ch * @Author: ch
* @Date: 2022-06-24 14:39:38 * @Date: 2022-06-24 14:39:38
* @LastEditors: ch * @LastEditors: ch
* @LastEditTime: 2022-06-29 14:20:54 * @LastEditTime: 2022-06-30 20:10:31
* @Description: file content * @Description: file content
--> -->
<template> <template>
@ -26,7 +26,7 @@
<div class="ctx--top-rate" v-if="productRate"> <div class="ctx--top-rate" v-if="productRate">
<b>商品满意度</b> <b>商品满意度</b>
<p>{{productRate}}</p> <p>{{productRate}}</p>
<el-rate :value="productRate" disabled></el-rate> <el-rate :value="productRate" disabled size="16px"></el-rate>
</div> </div>
<div class="ctx--top-tabs" v-if="tabs.length > 1"> <div class="ctx--top-tabs" v-if="tabs.length > 1">
<span v-for="i in tabs" :key="i.labelType" @click="handleTabChanage(i)" <span v-for="i in tabs" :key="i.labelType" @click="handleTabChanage(i)"
@ -105,7 +105,7 @@ export default {
productId : this.productId, productId : this.productId,
commentLabel : this.tabActive == -1 ? null : this.tabActive, commentLabel : this.tabActive == -1 ? null : this.tabActive,
sortType : this.sortActive.val, sortType : this.sortActive.val,
isContent : this.isContent isContent : this.isContent || null
}); });
this.loading = false this.loading = false
if(error){ if(error){
@ -183,6 +183,10 @@ export default {
justify-content: space-between; justify-content: space-between;
&--sort{ &--sort{
margin-right: 30px; margin-right: 30px;
cursor: pointer;
&:hover{
color: #FF512B;
}
} }
} }
.ctx{ .ctx{
@ -200,12 +204,15 @@ export default {
position: relative; position: relative;
b{ b{
font-weight: normal; font-weight: normal;
display: block;
height: 14px;
} }
p{ p{
font-size: 40px; font-size: 40px;
height: 40px; height: 40px;
line-height: 40px; line-height: 40px;
font-weight: bold; font-weight: bold;
margin-top: 6px;
} }
&::after{ &::after{
content: ''; content: '';
@ -217,10 +224,16 @@ export default {
right: 0; right: 0;
top: 26px; top: 26px;
} }
/deep/.el-rate__icon{
margin-right: 0;
font-size: 24px;
}
} }
&-tabs{ &-tabs{
margin: 34px 0; margin: 34px 0;
padding-left: 40px; padding-left: 40px;
display: flex;
align-items: center;
span{ span{
display: inline-block; display: inline-block;
height: 24px; height: 24px;

Loading…
Cancel
Save