expertServices.vue 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240
  1. <template>
  2. <view class="content">
  3. <!-- 我的服务顾问 -->
  4. <view class="ad-bg-box" v-if="users">
  5. <view class="ad-box">
  6. <view class="ad-sec-tit">
  7. 我的服务顾问
  8. </view>
  9. <view class="ad-con-box">
  10. <!-- <view class="ad-con-box-l"> -->
  11. <image :src="usersAvatarStr" mode="aspectFit" class="ad-icon-mine"></image>
  12. <!-- </view> -->
  13. <view class="ad-con-box-r">
  14. <view class="ad-name">{{users.name}}</view>
  15. <view class="ad-years">{{userYears}}</view>
  16. </view>
  17. </view>
  18. </view>
  19. </view>
  20. <!-- 全部服务顾问横栏 -->
  21. <view class="mid-box">
  22. <view class="mid-v-line"></view>
  23. <view class="mid-sec-tit">全部服务顾问</view>
  24. </view>
  25. <!-- 服务顾问list -->
  26. <view class="ad-list" v-for="(item,index) in queryManagerList" :key="item.id" @click="goDetail(item)">
  27. <!-- <view class="ad-con-box-l"> -->
  28. <image :src="item.avatar ? item.avatar : '../../static/timg/pic_def_ava@2x.png'" class="ad-list-img"></image>
  29. <!-- </view> -->
  30. <view class="ad-name ad-list-r">
  31. <text>{{item.name}}</text>
  32. </view>
  33. <view class="address-arrow">
  34. <image src="../../static/img/little_rightArrow.png" mode="aspectFit"></image>
  35. </view>
  36. </view>
  37. <!-- 上拉 加载更多 -->
  38. <view class="noMore" v-if="noMoreShow && (queryManagerList.length!=0)">没有更多数据</view>
  39. <!-- 无数据空白页 -->
  40. <nodata v-if="queryManagerList.length==0"></nodata>
  41. </view>
  42. </template>
  43. <script>
  44. export default {
  45. data() {
  46. return {
  47. queryManagerList: '',
  48. noMoreShow: false,
  49. users: ''
  50. }
  51. },
  52. onLoad() {
  53. this.getQueryManagerList()
  54. },
  55. computed: {
  56. usersAvatarStr() {
  57. return this.users.avatar ? this.users.avatar : '../../static/timg/pic_def_ava@2x.png'
  58. },
  59. userYears(){
  60. if (this.users.years) {
  61. return '从业年限:' + this.users.years + '年'
  62. }
  63. return '从业年限:未知'
  64. }
  65. },
  66. methods: {
  67. getQueryManagerList() {
  68. uni.showLoading({
  69. title: '加载中'
  70. })
  71. this.$http('openmy/queryManager', {}, 'GET').then(res => {
  72. uni.hideLoading();
  73. this.queryManagerList = res.data.userlist
  74. this.users = res.data.users
  75. console.log('服务顾问列表===', res);
  76. })
  77. },
  78. goDetail(item) {
  79. uni.navigateTo({
  80. url: '../index/personalCard?adInfo=' + JSON.stringify(item)
  81. })
  82. }
  83. },
  84. // 下拉刷新
  85. onPullDownRefresh() {
  86. this.getQueryManagerList()
  87. setTimeout(function() {
  88. uni.stopPullDownRefresh();
  89. }, 1000);
  90. }
  91. }
  92. </script>
  93. <style scoped>
  94. .content {
  95. min-height: 100vh;
  96. background-color: #F4F5F7;
  97. padding-bottom: 60rpx;
  98. }
  99. .ad-bg-box {
  100. background-color: #FF0000;
  101. padding: 20rpx 24rpx;
  102. }
  103. .ad-box {
  104. background-color: #FFFFFF;
  105. border-radius: 10rpx;
  106. }
  107. .ad-con-box {
  108. display: flex;
  109. padding-bottom: 10rpx;
  110. margin-top: 30rpx;
  111. margin-left: 30rpx;
  112. }
  113. /* .ad-con-box-l{
  114. display: flex;
  115. background-color: green;
  116. } */
  117. .ad-sec-tit {
  118. font-size: 24rpx;
  119. color: #666;
  120. padding-top: 30rpx;
  121. margin-left: 30rpx;
  122. }
  123. .ad-icon-mine {
  124. width: 100rpx;
  125. height: 100rpx;
  126. border-radius: 50rpx;
  127. }
  128. .ad-con-box-r {
  129. display: flex;
  130. flex-direction: column;
  131. justify-content: center;
  132. margin-left: 30rpx;
  133. }
  134. .ad-name {
  135. font-size: 30rpx;
  136. font-weight: bold;
  137. color: #333333;
  138. }
  139. .ad-years {
  140. font-size: 24rpx;
  141. color: #666;
  142. margin-top: 10rpx;
  143. }
  144. /* 全部服务顾问横栏 */
  145. .mid-v-line {
  146. background-color: #FF0000;
  147. width: 8rpx;
  148. height: 30rpx;
  149. border-radius: 4rpx;
  150. margin-left: 30rpx;
  151. }
  152. .mid-box {
  153. display: flex;
  154. height: 94rpx;
  155. align-items: center;
  156. background-color: #FFFFFF;
  157. margin-bottom: 20rpx;
  158. }
  159. .mid-sec-tit {
  160. margin-left: 16rpx;
  161. font-size: 30rpx;
  162. font-weight: 500;
  163. color: #333333;
  164. }
  165. /* 顾问list */
  166. .ad-list {
  167. margin: 0rpx 24rpx 20rpx;
  168. padding: 20rpx;
  169. background-color: #FFFFFF;
  170. border-radius: 10rpx;
  171. display: flex;
  172. }
  173. .ad-list-img {
  174. width: 84rpx;
  175. height: 84rpx;
  176. border-radius: 42rpx;
  177. }
  178. .address-arrow {
  179. width: 30rpx;
  180. }
  181. .address-arrow image {
  182. width: 30rpx;
  183. height: 100%;
  184. }
  185. .ad-list-r {
  186. display: flex;
  187. flex: 1;
  188. }
  189. .ad-list-r text{
  190. margin: auto 20rpx;
  191. /* background-color: green; */
  192. }
  193. .noMore {
  194. text-align: center;
  195. line-height: 50rpx;
  196. color: #999999;
  197. font-size: 28rpx;
  198. }
  199. /* .nodataImg {
  200. width: 400rpx;
  201. padding-top: 100rpx;
  202. }
  203. .noTxt {
  204. font-size: 36rpx;
  205. color: #999999;
  206. padding-top: 50rpx;
  207. }
  208. .nodataBox {
  209. text-align: center;
  210. } */
  211. </style>