suppliers.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. <template>
  2. <!-- 经销商基本信息 -->
  3. <view class="whole">
  4. <view class="head">
  5. <view class="behind"></view>
  6. <view class="below">
  7. <view class="nothing" v-if="judge==true">
  8. <u-empty mode="page" :text="$t('unified.nodata')"></u-empty>
  9. </view>
  10. <view class="content" v-for="(item, index) in supplier_s" :key="index">
  11. <view class="content_s">
  12. <view class="title">
  13. <view></view>
  14. <h3>{{item.agentName}}</h3>
  15. </view>
  16. <view class="information_E">
  17. <u-image width="250rpx" v-for="(item2, index) in item.brandList" :key="index" :src="item2" mode="widthFix"></u-image>
  18. </view>
  19. </view>
  20. </view>
  21. </view>
  22. </view>
  23. </view>
  24. </template>
  25. <script>
  26. import {
  27. request
  28. } from '../../common/request/request'
  29. require("promise.prototype.finally").shim()
  30. export default {
  31. data() {
  32. return {
  33. judge: true,
  34. supplier_s: [] //经销商信息
  35. }
  36. },
  37. created() {
  38. uni.showLoading({
  39. title: this.$t('unified.Loading')
  40. });
  41. setTimeout(function() {
  42. uni.hideLoading();
  43. }, 1000);
  44. this.supplier()
  45. },
  46. methods: {
  47. supplier() {
  48. request({
  49. url: '/myapp/storeSelectAgent',
  50. method: 'Post',
  51. data: {
  52. storeId: this.$store.state.storeInfo.storeId,
  53. userId: this.$store.state.storeInfo.userId
  54. }
  55. }).then(res => {
  56. this.supplier_s = res.data.data
  57. if (this.supplier_s.length != 0) {
  58. this.judge = false
  59. }
  60. }).catch(err => {
  61. if (this.supplier_s.length != 0) {
  62. this.judge = false
  63. }
  64. }).finally(() => {
  65. // Loading.close()
  66. })
  67. }
  68. }
  69. }
  70. </script>
  71. <style lang="scss" scoped>
  72. .behind {
  73. width: 750rpx;
  74. height: 462rpx;
  75. background: url(../../static/sailun/behind.png) no-repeat;
  76. background-size: 100% 100%;
  77. background-repeat: no-repeat;
  78. margin-top: -150rpx;
  79. padding-top: 100px;
  80. }
  81. .below {
  82. margin-top: -270rpx;
  83. }
  84. .nothing {
  85. width: 96%;
  86. height: 800rpx;
  87. background-color: #FFFFFF;
  88. margin: 0 auto;
  89. margin-top: 20rpx;
  90. border-radius: 20rpx;
  91. box-shadow: 0 0 24rpx 0 rgba(101, 176, 249, 0.41);
  92. }
  93. .content {
  94. width: 667rpx;
  95. height: auto;
  96. background: #FFFFFF;
  97. box-shadow: 0px 10rpx 30rpx 0px rgba(223, 223, 223, 0.51);
  98. border-radius: 18px;
  99. margin: 0 auto;
  100. padding-top: 30rpx;
  101. margin-top: 20rpx;
  102. padding-bottom: 40rpx;
  103. .content_s {
  104. width: 92%;
  105. // height: 330rpx;
  106. height: auto;
  107. margin: 0 auto;
  108. margin-top: 10rpx;
  109. .information {
  110. margin-top: 10rpx;
  111. }
  112. .information_E {
  113. display: flex;
  114. width: 100%;
  115. flex-flow: wrap;
  116. justify-content: space-around;
  117. align-items: center;
  118. }
  119. .title {
  120. border-bottom: 1rpx solid #EBEBEB;
  121. padding-bottom: 15rpx;
  122. view {
  123. width: 6px;
  124. height: 20px;
  125. background: #0292FD;
  126. float: left;
  127. margin-right: 10rpx;
  128. margin-top: 5rpx;
  129. }
  130. }
  131. }
  132. }
  133. </style>