my_invite.vue 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. <template>
  2. <view class="container">
  3. <view v-if="emptyType==0">
  4. <view v-for="item in dataList" class="item" @tap="handleClick(item)">
  5. <view class="item-left">
  6. <image :src="item.member.icon?item.member.icon:''" mode="aspectFit"></image>
  7. <view>
  8. <view class="item-name">{{item.member.username}}</view>
  9. <view class="item-tel">{{item.member.mobile}}</view>
  10. </view>
  11. </view>
  12. <image src="http://139.9.103.171:1888/img/image/arrow.png" class="arrow"></image>
  13. </view>
  14. </view>
  15. <DtNoMore v-if="isNoMore" />
  16. <DtEmpty :type="emptyType" />
  17. </view>
  18. </template>
  19. <script>
  20. import DtNoMore from "../comps/dt_no_more.vue";
  21. import DtEmpty from '../comps/dt_empty.vue'
  22. export default {
  23. components: {
  24. DtNoMore,
  25. DtEmpty
  26. },
  27. data() {
  28. return {
  29. memberId:'',
  30. dataList:[]
  31. };
  32. },
  33. methods:{
  34. onLoadPage() {
  35. this.memberId = this.$auth.getMemberId();
  36. this.getData()
  37. },
  38. async getData(){
  39. let resp = await this.$api.distributorGetInvites({
  40. _isShowLoading: true,
  41. memberId:this.memberId,
  42. pageNo:this.pageIndex,
  43. pageSize:this.pageSize,
  44. })
  45. let list = this.getDataList(resp)
  46. this.dataList = this.dataList.concat(list)
  47. },
  48. handleClick(item){
  49. uni.navigateTo({
  50. url:"/pagesM/pages/user_invite?title="+item.member.username+'&id='+item.member.id
  51. })
  52. }
  53. },
  54. onReachBottom() {
  55. this.onReachBottomPage()
  56. }
  57. }
  58. </script>
  59. <style lang="scss" scoped>
  60. .container{
  61. height: 100vh;
  62. border-top: 2upx solid rgba(238,238,238,1);
  63. .item{
  64. display: flex;
  65. align-items: center;
  66. justify-content: space-between;
  67. margin-left: 16upx;
  68. padding-left: 24upx;
  69. padding-right: 40upx;
  70. height: 108upx;
  71. background-color: #fff;
  72. border-bottom: 2upx solid rgba(238,238,238,1);
  73. .item-left{
  74. display: flex;
  75. align-items: center;
  76. image{
  77. width:66upx;
  78. height:66upx;
  79. border-radius:50%;
  80. background-color: #f7f7f7;
  81. margin-right: 21upx;
  82. display: block;
  83. }
  84. .item-name{
  85. font-size:30upx;
  86. line-height: 40upx;
  87. font-family:PingFang SC;
  88. font-weight:400;
  89. color:rgba(51,51,51,1);
  90. }
  91. .item-tel{
  92. font-size:24upx;
  93. font-family:PingFang SC;
  94. font-weight:400;
  95. color:rgba(153,153,153,1);
  96. }
  97. }
  98. .arrow{
  99. width: 10upx;
  100. height: 18upx;
  101. }
  102. }
  103. }
  104. </style>