emptyPage.vue 813 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <template>
  2. <!-- 无数据时显示 -->
  3. <view class="empty-box">
  4. <image :src="imgHost + '/statics/images/empty-box.png'"></image>
  5. <view class="txt">{{title}}</view>
  6. <slot name="bottom"></slot>
  7. </view>
  8. </template>
  9. <script>
  10. import {HTTP_REQUEST_URL} from '@/config/app';
  11. export default{
  12. props: {
  13. title: {
  14. type: String,
  15. default: '暂无记录',
  16. },
  17. },
  18. data(){
  19. return{
  20. imgHost:HTTP_REQUEST_URL
  21. }
  22. }
  23. }
  24. </script>
  25. <style lang="scss">
  26. .empty-box{
  27. display: flex;
  28. flex-direction: column;
  29. justify-content: center;
  30. align-items: center;
  31. width: 690rpx;
  32. height: 760rpx;
  33. margin: 30rpx auto;
  34. background: #FFFFFF;
  35. border-radius: 14rpx;
  36. background: #fff;
  37. image{
  38. width: 414rpx;
  39. height: 240rpx;
  40. }
  41. .txt{
  42. font-size: 26rpx;
  43. color: #999;
  44. }
  45. }
  46. </style>