yijianjun 1 өдөр өмнө
parent
commit
62694bdcf1

+ 8 - 2
mer_uniapp/pages/what_to_eat_today/index/index.vue

@@ -21,7 +21,7 @@
 			<view class="model-container">
 			<view class="model-container">
 				<img @click="onClose" :src="`${urlDomain}crmebimage/presets/whateat/what-close.png`" alt="" style="height: 49rpx;width: 49rpx;"
 				<img @click="onClose" :src="`${urlDomain}crmebimage/presets/whateat/what-close.png`" alt="" style="height: 49rpx;width: 49rpx;"
 					class="m-close" />
 					class="m-close" />
-				<view class="goods-items">
+				<view class="goods-items" v-if="productList.length">
 					<view class="g-item" v-for="ite in productList" :key="ite">
 					<view class="g-item" v-for="ite in productList" :key="ite">
 						<img :src="ite.image" alt="" style="height: 210rpx;width: 210rpx;" />
 						<img :src="ite.image" alt="" style="height: 210rpx;width: 210rpx;" />
 						<view class="g-title">
 						<view class="g-title">
@@ -36,19 +36,22 @@
 						</view>
 						</view>
 					</view>
 					</view>
 				</view>
 				</view>
+				<emptyPage v-else title="暂无数据~" :imgSrc="urlDomain+'crmebimage/presets/noShopper.png'"></emptyPage>
 			</view>
 			</view>
 		</uni-popup>
 		</uni-popup>
 	</view>
 	</view>
 </template>
 </template>
 
 
 <script>
 <script>
+	import emptyPage from '@/components/emptyPage.vue'
 	import {whattodayeatApi,whattodayeatProductApi} from '../what_to_eat_today.js'
 	import {whattodayeatApi,whattodayeatProductApi} from '../what_to_eat_today.js'
 	import navBar from '@/components/navBar';
 	import navBar from '@/components/navBar';
 	var statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
 	var statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
 	let app = getApp();
 	let app = getApp();
 	export default {
 	export default {
 		components: {
 		components: {
-			navBar
+			navBar,
+			emptyPage
 		},
 		},
 		data() {
 		data() {
 			return {
 			return {
@@ -285,4 +288,7 @@
 
 
 		margin: auto;
 		margin: auto;
 	}
 	}
+	::v-deep .empty-box {
+		padding-top: 0 !important
+	}
 </style>
 </style>