Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.

consumerSearch.vue 5.8 KiB

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