選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。
 
 
 

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