优化空列表提示

master
Eratosici 5 years ago
parent fa44c3fb9b
commit 73372fd109

@ -226,3 +226,12 @@ page {
color: #eb2444; color: #eb2444;
font-family: arial; font-family: arial;
} }
/* 空 */
.cont-item.empty {
display: block;
font-size: 24rpx;
margin-top: 80rpx;
color: #aaa;
text-align: center;
}

@ -32,7 +32,7 @@
<image :src="categoryImg" mode="widthFix"></image> <image :src="categoryImg" mode="widthFix"></image>
</view> </view>
</view> </view>
<view class="cont-item"> <view v-if="productList.length" class="cont-item">
<block v-for="(item, index) in productList" :key="index"> <block v-for="(item, index) in productList" :key="index">
<view class="show-item" @tap="toProdPage" :data-prodid="item.prodId"> <view class="show-item" @tap="toProdPage" :data-prodid="item.prodId">
<view class="more-prod-pic"> <view class="more-prod-pic">
@ -49,6 +49,7 @@
</block> </block>
</view> </view>
<view v-if="!productList.length" class="cont-item empty"></view>
<!-- </block> --> <!-- </block> -->
</scroll-view> </scroll-view>
<!-- 右侧内容end --> <!-- 右侧内容end -->

@ -82,7 +82,7 @@
<view class="item"> <view class="item">
<text class="item-tit">订单编号</text> <text class="item-tit">订单编号</text>
<text class="item-txt">{{orderNumber}}</text> <text class="item-txt">{{orderNumber}}</text>
<text class="copy-btn" @tap="copyBtn"></text> <!-- <text class="copy-btn" @tap="copyBtn"></text> -->
</view> </view>
<view class="item"> <view class="item">
<text class="item-tit">下单时间</text> <text class="item-tit">下单时间</text>

@ -326,6 +326,13 @@ swiper image {
right: -10px; right: -10px;
border-bottom-color: #e5e5e5; border-bottom-color: #e5e5e5;
} }
.cmt-items .empty {
display: block;
font-size: 24rpx;
text-align: center;
color: #aaa;
margin-top: 5vh;
}
.cmt-user { .cmt-user {
line-height: 25px; line-height: 25px;

@ -197,23 +197,26 @@
<text @tap="getProdCommPage" data-evaluate="3" :class="evaluate==3?'selected':''">有图({{prodCommData.picNumber}})</text> <text @tap="getProdCommPage" data-evaluate="3" :class="evaluate==3?'selected':''">有图({{prodCommData.picNumber}})</text>
</view> </view>
<view class="cmt-items"> <view class="cmt-items">
<view v-for="(item, index) in prodCommPage.records" :key="index" class="cmt-item"> <block v-if="prodCommPage.records.length">
<view class="cmt-user"> <view v-for="(item, index) in prodCommPage.records" :key="index" class="cmt-item">
<text class="date">{{item.recTime}}</text> <view class="cmt-user">
<view class="cmt-user-info"> <text class="date">{{item.recTime}}</text>
<image class="user-img" :src="item.pic"></image> <view class="cmt-user-info">
<view class="nickname">{{item.nickName}}</view> <image class="user-img" :src="item.pic"></image>
<!-- <van-rate readonly :value="item.score" @change="onChange" color="#f44"></van-rate> --> <view class="nickname">{{item.nickName}}</view>
<!-- <van-rate readonly :value="item.score" @change="onChange" color="#f44"></van-rate> -->
</view>
</view>
<view class="cmt-cnt">{{item.content}}</view>
<scroll-view class="cmt-attr" scroll-x="true" v-if="item.pics.length">
<image v-for="(commPic, index2) in item.pics" :key="index2" :src="commPic"></image>
</scroll-view>
<view class="cmt-reply" v-if="item.replyContent">
<text class="reply-tit">店铺回复</text> {{item.replyContent}}
</view> </view>
</view> </view>
<view class="cmt-cnt">{{item.content}}</view> </block>
<scroll-view class="cmt-attr" scroll-x="true" v-if="item.pics.length"> <view v-if="!prodCommPage.records.length" class="empty"></view>
<image v-for="(commPic, index2) in item.pics" :key="index2" :src="commPic"></image>
</scroll-view>
<view class="cmt-reply" v-if="item.replyContent">
<text class="reply-tit">店铺回复</text> {{item.replyContent}}
</view>
</view>
</view> </view>
<view class="load-more" v-if="prodCommPage.pages > prodCommPage.current"> <view class="load-more" v-if="prodCommPage.pages > prodCommPage.current">
<text @tap="getMoreCommPage"></text> <text @tap="getMoreCommPage"></text>
@ -438,6 +441,7 @@ export default {
this.setData({ this.setData({
prodCommData: res prodCommData: res
}); });
console.log('评论prodCommData:', this.prodCommData)
} }
}); });
}, },

Loading…
Cancel
Save