suppliers.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  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="出错了!请联系管理员"></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. <image v-for="(item2, index) in item.brandList" :key="index" :src="item2" mode=""></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. this.supplier()
  39. },
  40. methods: {
  41. supplier(){
  42. request({
  43. url: '/myapp/storeSelectAgent',
  44. method: 'Post',
  45. data: {
  46. storeId:this.$store.state.storeInfo.storeId,
  47. userId:this.$store.state.storeInfo.userId
  48. }
  49. }).then(res => {
  50. console.log(res.data.data)
  51. console.log(res)
  52. this.supplier_s = res.data.data
  53. console.log(this.supplier_s)
  54. if(this.supplier_s.length != 0){
  55. this.judge = false
  56. }
  57. console.log(res.data.data[1].brandList[1])
  58. }).catch(err => {
  59. console.log(err)
  60. if(this.supplier_s.length != 0){
  61. this.judge = false
  62. }
  63. }).finally(() => {
  64. // Loading.close()
  65. })
  66. }
  67. }
  68. }
  69. </script>
  70. <style lang="scss" scoped>
  71. .behind {
  72. width: 750rpx;
  73. height: 462rpx;
  74. background: url(../../static/sailun/behind.png) no-repeat;
  75. background-size: 100% 100%;
  76. background-repeat: no-repeat;
  77. margin-top:-150rpx;
  78. padding-top: 100px;
  79. }
  80. .below{
  81. margin-top: -270rpx;
  82. }
  83. .nothing {
  84. width: 96%;
  85. height: 800rpx;
  86. background-color: #FFFFFF;
  87. margin: 0 auto;
  88. margin-top: 20rpx;
  89. border-radius: 20rpx;
  90. box-shadow: 0 0 24rpx 0 rgba(101, 176, 249, 0.41);
  91. }
  92. .content {
  93. width: 667rpx;
  94. height: auto;
  95. background: #FFFFFF;
  96. box-shadow: 0px 10px 40px 0px rgba(223, 223, 223, 0.51);
  97. border-radius: 18px;
  98. margin: 0 auto;
  99. padding-top: 30rpx;
  100. margin-top: 20rpx;
  101. padding-bottom: 40rpx;
  102. .content_s {
  103. width: 92%;
  104. // height: 330rpx;
  105. height: auto;
  106. margin: 0 auto;
  107. margin-top: 10rpx;
  108. .information{
  109. margin-top: 10rpx;
  110. }
  111. .information_E{
  112. image{
  113. width: 48%;
  114. height: 100rpx;
  115. margin-top: 20rpx;
  116. }
  117. }
  118. .title {
  119. border-bottom: 1rpx solid #EBEBEB;
  120. padding-bottom: 15rpx;
  121. view {
  122. width: 6px;
  123. height: 20px;
  124. background: #0292FD;
  125. float: left;
  126. margin-right: 10rpx;
  127. margin-top: 5rpx;
  128. }
  129. }
  130. }
  131. }
  132. </style>