loadingAll.vue 824 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <template>
  2. <view v-show="loadingShow">
  3. <view class="request-loading-view">
  4. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/loading_all.gif"></image>
  5. </view>
  6. </view>
  7. </template>
  8. <script>
  9. export default {
  10. data() {
  11. return {
  12. loadingShow: false,
  13. };
  14. },
  15. watch: {
  16. "$store.state.requestLoading": {
  17. handler(newValue) {
  18. this.loadingShow = newValue;
  19. },
  20. deep: true,
  21. immediate: true,
  22. },
  23. },
  24. };
  25. </script>
  26. <style lang="scss" scoped>
  27. .request-loading-view {
  28. position: fixed;
  29. top: 0;
  30. left: 0;
  31. width: 100%;
  32. height: 100%;
  33. z-index: 10000;
  34. // background-color: rgba(0, 0, 0, 0.6);
  35. display: flex;
  36. justify-content: center;
  37. align-items: center;
  38. // padding-top: 430rpx;
  39. image {
  40. width: 110rpx;
  41. height: 110rpx;
  42. }
  43. }
  44. </style>