NoData.vue 995 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <template>
  2. <div class="flex-box-v flex-v-zhu">
  3. <img src="@/assets/image/nodata.png" :style="{ width: imgW, height: imgH }" style="margin: 30px auto;">
  4. <div class="fontColorC" style="text-align: center;line-height: 28px;" v-if="!isSolt">{{content}}</div>
  5. <slot></slot>
  6. </div>
  7. </template>
  8. <!-- content:为提示内容 -->
  9. <!-- imgUrl:为空值显示图片 -->
  10. <!-- isSolt:是否显示自定义内容 -->
  11. <script>
  12. export default {
  13. name:'NoData',
  14. props:{
  15. content:{
  16. type:String,
  17. default:'暂无数据'
  18. },
  19. isSolt:{
  20. type:Boolean,
  21. default:false
  22. },
  23. imgW:{
  24. type:String,
  25. default:'266px'
  26. },
  27. imgH:{
  28. type:String,
  29. default:'182px'
  30. },
  31. },
  32. data(){
  33. return{
  34. }
  35. },
  36. methods:{
  37. }
  38. }
  39. </script>
  40. <style scoped="scoped">
  41. .green{
  42. color: #67c23a;
  43. }
  44. .blue{
  45. color:#26a2ff;
  46. cursor: pointer;
  47. }
  48. .fontColorC{
  49. color:#909399;
  50. }
  51. </style>