You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

229 lines
5.3 KiB

  1. <template>
  2. <view class="box">
  3. <view style="width: 690rpx;margin: 0 auto;margin-top: 20rpx;">
  4. <u-search @search='searchinfo()' placeholder="请输入" v-model="keyword"></u-search>
  5. </view>
  6. <!-- <view @click="searchinfo()">搜索</view> -->
  7. <view class="content">
  8. <view class="content-tips" v-for="(item,index) in recordList" :key='index' @click="gotoDetail(item.id)">
  9. <view class="content-first">
  10. <view class="left">
  11. <view v-if="item.level.length==0"></view>
  12. <view class="img" v-else-if="item.level==1">A</view>
  13. <view class="img" v-else-if="item.level==2">B</view>
  14. <view class="img" v-else-if="item.level==3">C</view>
  15. <view class="img" v-else-if="item.level==4">D</view>
  16. <view class="test">{{item.name}}</view>
  17. </view>
  18. </view>
  19. <view class="content-sec">
  20. <view class="content-sec-lab">
  21. 手机号码:<view class="content-sec-lab1">{{item.phone || '--'}}</view>
  22. </view>
  23. <view class="content-sec-lab">
  24. 客户标签:
  25. <!-- <view class="content-sec-tips" v-for="(che,ind) in item.demand.cusSemanticWords" :key='ind'>{{che.name}}</view> -->
  26. </view>
  27. <view class="content-sec-lab">
  28. 顾问姓名:<view class="content-sec-lab1">{{item.agentName}}</view>
  29. </view>
  30. <view class="content-sec-lab">
  31. 添加时间:<view class="content-sec-lab1">{{item.createTime}}</view>
  32. </view>
  33. <view class="content-sec-num">
  34. <view class="">{{item.visitRecord || "0"}}次到访</view>
  35. <view class="">{{item.fraction || '0'}}% | {{item.fraction || '0'}}分</view>
  36. </view>
  37. </view>
  38. </view>
  39. </view>
  40. </view>
  41. </template>
  42. <script>
  43. export default{
  44. data(){
  45. return{
  46. keyword:'',
  47. stageList:['未知','到访','意向','定金','成交'],
  48. recordList:[],
  49. nextPage:1,
  50. totalRecord:'',
  51. buildingID:'',
  52. }
  53. },
  54. onShow() {
  55. this.buildingID = uni.getStorageSync('buildingID').id;
  56. },
  57. onReachBottom() {
  58. if(this.totalRecord==this.nextPage){
  59. uni.showToast({
  60. icon:'none',
  61. title: '到底了',
  62. duration: 2000
  63. });
  64. return
  65. }else{
  66. this.nextPage+=1;
  67. this.getMyCustom();
  68. }
  69. },
  70. methods:{
  71. // 客户详情
  72. gotoDetail(id) {
  73. uni.navigateTo({
  74. url: `/pages/center/consumer/consumerDetail?id=${id}`
  75. })
  76. },
  77. searchinfo(){
  78. this.nextPage=1;
  79. this.recordList=[];
  80. this.getMyCustom();
  81. },
  82. getMyCustom(){
  83. var parames = {
  84. pageNum: this.nextPage,
  85. pageSize: 10,
  86. query: {
  87. projectId:this.buildingID,
  88. nameOrPhone:this.keyword
  89. }
  90. };
  91. this.$u.post("/customer/customerManagement", parames).then(data => {
  92. var list = data.results || [];
  93. this.recordList = [...this.recordList, ...list];
  94. this.totalRecord=data.totalPage;
  95. })
  96. },
  97. }
  98. }
  99. </script>
  100. <style lang="scss" scoped>
  101. .box {
  102. width: 100%;
  103. height: 100%;
  104. background: #FFFFFF;
  105. }
  106. .content{
  107. overflow: hidden;
  108. margin-top: 10rpxs;
  109. .content-tips{
  110. background: #fff;
  111. // box-sizing: border-box;
  112. margin-bottom: 20rpx;
  113. overflow: hidden;
  114. .content-first{
  115. padding: 19rpx 30rpx;
  116. display: flex;
  117. justify-content: space-between;
  118. box-sizing: border-box;
  119. // border-top: 1px solid #E0E0E0;
  120. font-weight: 400;
  121. color: #292929;
  122. height: 90rpx;
  123. font-size: 30rpx;
  124. line-height: 30rpx;
  125. .left{
  126. display: flex;
  127. .img{
  128. // margin-top: 19rpx;
  129. width: 52rpx;
  130. height: 52rpx;
  131. border: 1px solid #E0E0E0;
  132. border-radius: 50%;
  133. text-align: center;
  134. line-height: 50rpx;
  135. margin-right: 20rpx;
  136. }
  137. .test{
  138. margin-top: 11rpx;
  139. // margin-left: 20rpx;
  140. font-weight: 500;
  141. color: #333333;
  142. }
  143. }
  144. .right{
  145. display: flex;
  146. .point{
  147. width: 12rpx;
  148. height: 12rpx;
  149. background: #2B6EFF;
  150. border-radius: 50%;
  151. margin-right: 9rpx;
  152. margin-top: 20rpx;
  153. }
  154. .test{
  155. margin-top: 11rpx;
  156. }
  157. }
  158. }
  159. .content-sec{
  160. border-top: 1px solid #E0E0E0;
  161. padding: 0 30rpx;
  162. padding-bottom: 30rpx;
  163. // height: 270rpx;
  164. position: relative;
  165. .content-sec-lab{
  166. margin-top: 30rpx;
  167. display: flex;
  168. font-size: 30rpx;
  169. font-weight: 400;
  170. color: #666666;
  171. line-height: 30rpx;
  172. .content-sec-lab1{
  173. color: #333333;
  174. }
  175. .content-sec-tips{
  176. max-width:174rpx ;
  177. height: 46rpx;
  178. background: #F2F2F2;
  179. border-radius: 6rpx;
  180. text-align: center;
  181. line-height: 26rpx;
  182. overflow: hidden;
  183. text-overflow:ellipsis;
  184. white-space: nowrap;
  185. font-size: 26rpx;
  186. font-weight: 400;
  187. color: #333333;
  188. margin-right: 24rpx;
  189. box-sizing: border-box;
  190. padding: 10rpx 24rpx;
  191. }
  192. }
  193. .content-sec-num{
  194. position: absolute;
  195. width: 190rpx;
  196. height: 90rpx;
  197. background: #F4F8FD;
  198. border-radius: 12rpx;
  199. font-weight: 400;
  200. color: #2671E2;
  201. line-height: 45rpx;
  202. bottom: 30rpx;
  203. right: 30rpx;
  204. text-align: center;
  205. }
  206. }
  207. .content-last{
  208. display: flex;
  209. border-top: 1px solid #E0E0E0;
  210. // padding: 0 30rpx;
  211. height: 78rpx;
  212. .content-last-tab{
  213. width: 33.4%;
  214. text-align: center;
  215. font-size: 30rpx;
  216. font-weight: 400;
  217. color: #333333;
  218. line-height: 78rpx;
  219. border-right: 1px solid #E0E0E0;
  220. }
  221. }
  222. }
  223. }
  224. </style>