Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 

1529 lignes
39 KiB

  1. <template>
  2. <view class="box">
  3. <view class="top-search">
  4. <view class="search-box">
  5. <view class="search" @click="goSearch">
  6. <view class="search-img">
  7. <image
  8. class="search-img1"
  9. src="../../../static/images/search.png"
  10. mode=""
  11. ></image>
  12. </view>
  13. <view class="search-text">输入客户姓名/手机号</view>
  14. </view>
  15. </view>
  16. <image
  17. class="filter-icon"
  18. @click="screenShow = true"
  19. src="https://static.quhouse.com/f4feade4a19d413085b591612179457f.png"
  20. mode=""
  21. />
  22. </view>
  23. <!-- 选择器 -->
  24. <view class="boxtittab" style="border: none">
  25. <view class="tabbox" @click="soltishow = true">
  26. {{ sortFilter }}
  27. <u-icon
  28. name="arrow-down"
  29. size="24"
  30. style="padding-left: 12rpx"
  31. ></u-icon>
  32. </view>
  33. <view class="tabbox" @click="timeshow = true">
  34. {{ arriveFilter }}
  35. <u-icon
  36. name="arrow-down"
  37. size="24"
  38. style="padding-left: 12rpx"
  39. ></u-icon>
  40. </view>
  41. <view class="tabbox" @click="selectshow = true">
  42. {{ receptionDuration }}
  43. <u-icon
  44. name="arrow-down"
  45. size="24"
  46. style="padding-left: 12rpx"
  47. ></u-icon>
  48. </view>
  49. <view class="tabbox" @click="huaxiangShow = true">
  50. 画像标签<u-icon
  51. name="arrow-down"
  52. size="24"
  53. style="padding-left: 12rpx"
  54. ></u-icon>
  55. </view>
  56. </view>
  57. <view class="count" v-if="recordList.length > 0">
  58. 筛选结果:<text>{{ totalRecords }} </text>条
  59. </view>
  60. <view class="content">
  61. <view
  62. v-if="recordList.length == 0"
  63. style="width: 100%; height: 100%; display: flex; align-items: center"
  64. >
  65. <view style="width: 100%; padding-top: 200rpx; background: #ffffff">
  66. <view style="width: 100%; text-align: center">
  67. <image
  68. style="width: 220rpx; height: 200rpx"
  69. src="https://static.quhouse.com/zhikong_xcx_img/nodatalist.png"
  70. mode=""
  71. ></image>
  72. </view>
  73. <view
  74. style="
  75. text-align: center;
  76. width: 100%;
  77. margin-top: 20rpx;
  78. color: #999999;
  79. "
  80. >暂无数据</view
  81. >
  82. </view>
  83. </view>
  84. <view
  85. v-if="recordList.length != 0"
  86. class="content-tips"
  87. v-for="(item, index) in recordList"
  88. :key="index"
  89. @click="gotoDetail(item.id)"
  90. >
  91. <view class="content-first">
  92. <view class="left">
  93. <view v-if="item.level.length == 0"></view>
  94. <view class="img" v-else-if="item.level == 1">A</view>
  95. <view class="img" v-else-if="item.level == 2">B</view>
  96. <view class="img" v-else-if="item.level == 3">C</view>
  97. <view class="img" v-else-if="item.level == 4">D</view>
  98. <view class="test">{{ item.name }}</view>
  99. </view>
  100. <view class="right">
  101. <view class="test"
  102. >销讲执行:<text class="blue"
  103. >{{ item.fraction || 0 }}%</text
  104. ></view
  105. >
  106. </view>
  107. </view>
  108. <view class="content-sec">
  109. <view class="content-sec-lab">
  110. <view class="content-sec-lab1"
  111. >手机号码:{{ item.phone || "--" }}</view
  112. >
  113. <view class="content-sec-lab1" style="width: 44%"
  114. >到访次数:{{ item.visitRecord || 0 }}次/{{
  115. item.mm || 0
  116. }}min</view
  117. >
  118. </view>
  119. <view class="content-sec-lab">
  120. <view class="content-sec-lab1"
  121. >需求挖掘:{{ item.wordFraction || 0 }}%</view
  122. >
  123. <view class="content-sec-lab1" style="width: 44%"
  124. >画像标签:<text style="font-weight: 600">{{
  125. item.demand.cusSemanticWordsList.length || 0
  126. }}</text></view
  127. >
  128. </view>
  129. <view class="content-sec-lab">
  130. <view class="content-sec-lab1"
  131. >所属顾问:{{ item.agentName || "--" }}</view
  132. >
  133. <view class="content-sec-lab1" style="width: 44%"
  134. >客户阶段:{{ item.stageName || "--" }}</view
  135. >
  136. </view>
  137. <view class="content-sec-lab">
  138. <view class="content-sec-lab1"
  139. >上次到访:{{ item.createTime || "--" }}</view
  140. >
  141. </view>
  142. </view>
  143. <view class="content-last" v-if="item.isshow">
  144. <view class="content-last-tab">
  145. <!-- <image class="icon" src="https://static.quhouse.com/5daebdec0aad4f63a62d3720437034bc.png" mode="" />
  146. 添加提醒 -->
  147. </view>
  148. <view class="content-last-tab">
  149. <!-- <image class="icon" src="https://static.quhouse.com/b867df5efc72480f8c1f3bc9399c7d6c.png" mode="" />
  150. 拨打电话 -->
  151. </view>
  152. <view class="content-last-tab" @click.stop="gotoFollowUp(item.id)">
  153. <image
  154. class="icon"
  155. src="https://static.quhouse.com/3730fc3a185c4d65ae6a1821601038ab.png"
  156. mode=""
  157. />
  158. 写跟进</view
  159. >
  160. </view>
  161. </view>
  162. </view>
  163. <!-- 更多筛选 -->
  164. <u-popup v-model="screenShow" mode="top" height="850">
  165. <view class="screen">
  166. <scroll-view scroll-y="true" style="height: 700rpx;">
  167. <!-- 咨询业务 -->
  168. <!-- <view class="screen-record">
  169. <view class="screen-record-text" @click="zixunArrow = !zixunArrow">
  170. 咨询业务<image
  171. v-if="zixunArrow"
  172. class="arrow"
  173. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  174. mode=""
  175. />
  176. <image
  177. v-else
  178. class="arrow"
  179. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  180. mode=""
  181. />
  182. </view>
  183. <view class="screen-record-tab" v-if="zixunArrow">
  184. <block v-for="(item, index) in zixunList" :key="index">
  185. <view
  186. class="screen-record-item"
  187. :class="[
  188. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  189. ]"
  190. @click="choice(item)"
  191. >
  192. {{ item.label }}
  193. </view>
  194. </block>
  195. </view>
  196. </view> -->
  197. <!-- 接待时长 -->
  198. <view class="screen-record">
  199. <view class="screen-record-text" @click="jiedaiArrow = !jiedaiArrow">
  200. 接待时长<image
  201. v-if="jiedaiArrow"
  202. class="arrow"
  203. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  204. mode=""
  205. />
  206. <image
  207. v-else
  208. class="arrow"
  209. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  210. mode=""
  211. />
  212. </view>
  213. <view class="screen-record-tab" v-if="jiedaiArrow">
  214. <block v-for="(item, index) in jiedaiList" :key="index">
  215. <view
  216. class="screen-record-item"
  217. :class="[
  218. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  219. ]"
  220. @click="choice(item)"
  221. >
  222. {{ item.label }}
  223. </view>
  224. </block>
  225. </view>
  226. </view>
  227. <!-- 客户等级 -->
  228. <view class="screen-record">
  229. <view class="screen-record-text" @click="levelArrow = !levelArrow">
  230. 客户等级<image
  231. v-if="levelArrow"
  232. class="arrow"
  233. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  234. mode=""
  235. />
  236. <image
  237. v-else
  238. class="arrow"
  239. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  240. mode=""
  241. />
  242. </view>
  243. <view class="screen-record-tab" v-if="levelArrow">
  244. <block v-for="(item, index) in levelList" :key="index">
  245. <view
  246. class="screen-record-item"
  247. :class="[
  248. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  249. ]"
  250. @click="choice(item)"
  251. >
  252. {{ item.label }}
  253. </view>
  254. </block>
  255. </view>
  256. </view>
  257. <!-- 客户来源 -->
  258. <view class="screen-record">
  259. <view class="screen-record-text" @click="sourceArrow = !sourceArrow">
  260. 客户来源<image
  261. v-if="sourceArrow"
  262. class="arrow"
  263. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  264. mode=""
  265. />
  266. <image
  267. v-else
  268. class="arrow"
  269. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  270. mode=""
  271. />
  272. </view>
  273. <view class="screen-record-tab" v-if="sourceArrow">
  274. <block v-for="(item, index) in sourceList" :key="index">
  275. <view
  276. class="screen-record-item"
  277. :class="[
  278. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  279. ]"
  280. @click="choice(item)"
  281. >
  282. {{ item.label }}
  283. </view>
  284. </block>
  285. </view>
  286. </view>
  287. <!-- 客户阶段 -->
  288. <view class="screen-record">
  289. <view
  290. class="screen-record-text"
  291. @click="jieduanArrow = !jieduanArrow"
  292. >
  293. 客户阶段<image
  294. v-if="jieduanArrow"
  295. class="arrow"
  296. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  297. mode=""
  298. />
  299. <image
  300. v-else
  301. class="arrow"
  302. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  303. mode=""
  304. />
  305. </view>
  306. <view class="screen-record-tab" v-if="jieduanArrow">
  307. <block v-for="(item, index) in phaseList" :key="index">
  308. <view
  309. class="screen-record-item"
  310. :class="[
  311. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  312. ]"
  313. @click="choice(item)"
  314. >
  315. {{ item.label }}
  316. </view>
  317. </block>
  318. </view>
  319. </view>
  320. <!-- 需求挖掘率 -->
  321. <view class="screen-record">
  322. <view class="screen-record-text" @click="wajueArrow = !wajueArrow">
  323. 需求挖掘率<image
  324. v-if="wajueArrow"
  325. class="arrow"
  326. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  327. mode=""
  328. />
  329. <image
  330. v-else
  331. class="arrow"
  332. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  333. mode=""
  334. />
  335. </view>
  336. <view class="screen-record-tab" v-if="wajueArrow">
  337. <block v-for="(item, index) in wajueList" :key="index">
  338. <view
  339. class="screen-record-item"
  340. :class="[
  341. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  342. ]"
  343. @click="choice(item)"
  344. >
  345. {{ item.label }}
  346. </view>
  347. </block>
  348. </view>
  349. </view>
  350. <!-- 销讲执行率 -->
  351. <view class="screen-record">
  352. <view
  353. class="screen-record-text"
  354. @click="xiaojiangArrow = !xiaojiangArrow"
  355. >
  356. 销讲执行率
  357. <image
  358. v-if="xiaojiangArrow"
  359. class="arrow"
  360. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  361. mode=""
  362. />
  363. <image
  364. v-else
  365. class="arrow"
  366. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  367. mode=""
  368. />
  369. </view>
  370. <view class="screen-record-tab" v-if="xiaojiangArrow">
  371. <block v-for="(item, index) in xiaojiangList" :key="index">
  372. <view
  373. class="screen-record-item"
  374. :class="[
  375. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  376. ]"
  377. @click="choice(item)"
  378. >
  379. {{ item.label }}
  380. </view>
  381. </block>
  382. </view>
  383. </view>
  384. <!-- 到访次数 -->
  385. <view class="screen-record">
  386. <view class="screen-record-text" @click="visitArrow = !visitArrow">
  387. 到访次数<image
  388. v-if="visitArrow"
  389. class="arrow"
  390. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  391. mode=""
  392. />
  393. <image
  394. v-else
  395. class="arrow"
  396. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  397. mode=""
  398. />
  399. </view>
  400. <view class="screen-record-tab" v-if="visitArrow">
  401. <block v-for="(item, index) in visitList" :key="index">
  402. <view
  403. class="screen-record-item"
  404. :class="[
  405. item.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  406. ]"
  407. @click="choice(item)"
  408. >
  409. {{ item.label }}
  410. </view>
  411. </block>
  412. </view>
  413. </view>
  414. </scroll-view>
  415. <view class="screen-foot">
  416. <view class="screen-foot-reset" @click="reset"> 重置 </view>
  417. <view class="screen-foot-sure" @click="screensure"> 确定 </view>
  418. </view>
  419. </view>
  420. </u-popup>
  421. <!-- 选择顾问的选择框 -->
  422. <u-select
  423. v-model="selectshow"
  424. :list="freeList"
  425. @confirm="actionSelectCallback"
  426. ></u-select>
  427. <!-- 客户阶段 -->
  428. <!-- <u-select
  429. v-model="selectPhaseShow"
  430. :list="phaseList"
  431. @confirm="selectPhase"
  432. ></u-select> -->
  433. <u-calendar
  434. v-model="totalTimeShow"
  435. mode="range"
  436. @change="totalTimeChange"
  437. ></u-calendar>
  438. <!-- 到访时间 -->
  439. <u-popup v-model="timeshow" mode="bottom">
  440. <view
  441. class="timeview"
  442. :style="{ color: activeTotal == 5 ? '#2B6EFF' : '#333333' }"
  443. @click="tabtimetap(5, '接待时间')"
  444. >
  445. 全部</view
  446. >
  447. <view
  448. class="timeview"
  449. :style="{ color: activeTotal == 0 ? '#2B6EFF' : '#333333' }"
  450. @click="tabtimetap(0, '今天')"
  451. >
  452. 今天</view
  453. >
  454. <view
  455. class="timeview"
  456. :style="{ color: activeTotal == 1 ? '#2B6EFF' : '#333333' }"
  457. @click="tabtimetap(1, '昨天')"
  458. >
  459. 昨天</view
  460. >
  461. <view
  462. class="timeview"
  463. :style="{ color: activeTotal == 2 ? '#2B6EFF' : '#333333' }"
  464. @click="tabtimetap(2, '近7天')"
  465. >
  466. 近7天</view
  467. >
  468. <view
  469. class="timeview"
  470. :style="{ color: activeTotal == 6 ? '#2B6EFF' : '#333333' }"
  471. @click="tabtimetap(6, '近30天')"
  472. >
  473. 近30天</view
  474. >
  475. <view
  476. class="timeview"
  477. :style="{ color: activeTotal == 4 ? '#2B6EFF' : '#333333' }"
  478. @click="tabtimetap(4)"
  479. >
  480. 自定义</view
  481. >
  482. </u-popup>
  483. <!-- 画像标签 -->
  484. <u-popup v-model="huaxiangShow" mode="top" height="850">
  485. <view class="screen">
  486. <scroll-view scroll-y="true" style="height: 700rpx;">
  487. <view class="screen-record" v-if="item.children.length" v-for="(item,index) in huaxiangList" :key="index">
  488. <view class="screen-record-text" @click="choice(item)">
  489. {{item.name}}<image
  490. v-if="item.isShow"
  491. class="arrow"
  492. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png"
  493. mode=""
  494. />
  495. <image
  496. v-else
  497. class="arrow"
  498. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png"
  499. mode=""
  500. />
  501. </view>
  502. <view class="screen-record-tab" v-if="item.isShow">
  503. <block v-for="(subitem, ind) in item.children" :key="ind">
  504. <view
  505. class="screen-record-item"
  506. :class="[
  507. subitem.isShow ? 'screen-record-chose' : 'screen-record-nochose',
  508. ]"
  509. @click="choice(subitem)"
  510. >
  511. {{ subitem.name }}
  512. </view>
  513. </block>
  514. </view>
  515. </view>
  516. </scroll-view>
  517. <view class="screen-foot">
  518. <view class="screen-foot-reset" @click="resetHuaXiang"> 重置 </view>
  519. <view class="screen-foot-sure" @click="screensure"> 确定 </view>
  520. </view>
  521. </view>
  522. </u-popup>
  523. <!-- 排序 -->
  524. <u-select
  525. v-model="soltishow"
  526. :list="orderBylist"
  527. @confirm="selectCallback2"
  528. ></u-select>
  529. <!-- 加载组件 -->
  530. <loading v-model="LOADING"></loading>
  531. </view>
  532. </template>
  533. <script>
  534. import loading from "@/components/loading/index.vue";
  535. const config = require("@/config");
  536. export default {
  537. components: {
  538. loading,
  539. },
  540. data() {
  541. return {
  542. huaxiangShow: false,
  543. wajueArrow: true,
  544. jieduanArrow: true,
  545. sourceArrow: true,
  546. levelArrow: true,
  547. zixunArrow: true,
  548. jiedaiArrow: true,
  549. luyinArrow: true,
  550. visitArrow: true,
  551. xiaojiangArrow: true,
  552. huaxiangList: [],
  553. orderBylist: [
  554. {
  555. label: "创建时间倒序",
  556. value: "1",
  557. },
  558. {
  559. label: "创建时间正序",
  560. value: "2",
  561. },
  562. {
  563. label: "接待时间倒序",
  564. value: "3",
  565. },
  566. {
  567. label: "接待时间正序",
  568. value: "4",
  569. },
  570. {
  571. label: "执行率倒序",
  572. value: "5",
  573. },
  574. {
  575. label: "执行率正序",
  576. value: "6",
  577. },
  578. {
  579. label: "接访次数正序",
  580. value: "7",
  581. },
  582. {
  583. label: "接访次数倒序",
  584. value: "8",
  585. },
  586. {
  587. label: "需求挖掘率正序",
  588. value: "9",
  589. },
  590. {
  591. label: "需求挖掘率倒序",
  592. value: "10",
  593. },
  594. ],
  595. zixunList: [
  596. {
  597. label: "一期住宅",
  598. value: 1,
  599. isShow: false,
  600. },
  601. {
  602. label: "二期住宅",
  603. value: 2,
  604. isShow: false,
  605. },
  606. {
  607. label: "三期住宅",
  608. value: 3,
  609. isShow: false,
  610. },
  611. {
  612. label: "商铺",
  613. value: 4,
  614. isShow: false,
  615. },
  616. ],
  617. jiedaiList: [
  618. {
  619. label: "0~15min",
  620. value: 1,
  621. isShow: false,
  622. },
  623. {
  624. label: "15~30min",
  625. value: 2,
  626. isShow: false,
  627. },
  628. {
  629. label: "30~60min",
  630. value: 3,
  631. isShow: false,
  632. },
  633. {
  634. label: "60~90min",
  635. value: 4,
  636. isShow: false,
  637. },
  638. {
  639. label: "90min以上",
  640. value: 5,
  641. isShow: false,
  642. },
  643. ],
  644. wajueList: [
  645. {
  646. label: "30%以下",
  647. value: 1,
  648. isShow: false,
  649. },
  650. {
  651. label: "30%~50%",
  652. value: 2,
  653. isShow: false,
  654. },
  655. {
  656. label: "50%~70%",
  657. value: 3,
  658. isShow: false,
  659. },
  660. {
  661. label: "70%以上",
  662. value: 4,
  663. isShow: false,
  664. },
  665. ],
  666. xiaojiangList: [
  667. {
  668. label: "30%以下",
  669. value: 1,
  670. isShow: false,
  671. },
  672. {
  673. label: "30%~50%",
  674. value: 2,
  675. isShow: false,
  676. },
  677. {
  678. label: "50%~70%",
  679. value: 3,
  680. isShow: false,
  681. },
  682. {
  683. label: "70%以上",
  684. value: 4,
  685. isShow: false,
  686. },
  687. ],
  688. screenShow: false,
  689. selectshow: false,
  690. selectPhaseShow: false,//客户阶段
  691. buildingID: "",
  692. screen: {
  693. staTime: "",
  694. endTime: "",
  695. orderBy: "",// 排序
  696. agentId: "",//顾问
  697. sourceIds: [],// 客户来源
  698. level: [],// 客户等级
  699. visitRecord: [],// 到访次数
  700. // zixunVal: [],// 咨询业务
  701. wajueVal: [],// 需求挖掘
  702. xiaojiangVal:[],//销讲执行率
  703. jiedaiVal: [],// 接待时长
  704. validInvalid: null,// 录音标识
  705. clientStage: [],// 客户阶段 clientStage
  706. },
  707. recordList: [],
  708. nextPage: 1,
  709. totalRecord: "",
  710. freeList: [],
  711. userInfo: {},
  712. phaseList: [],//客户阶段
  713. isnorefresh: "",
  714. activeTotal: 5,
  715. totalTimeShow: false,
  716. timeshow: false,
  717. soltishow: false,
  718. totalRecords: "",
  719. visitList: [
  720. {
  721. label: "首次到访",
  722. value: 1,
  723. isShow: false,
  724. },
  725. {
  726. label: "2次到访",
  727. value: 2,
  728. isShow: false,
  729. },
  730. {
  731. label: "3次到访",
  732. value: 3,
  733. isShow: false,
  734. },
  735. {
  736. label: "3次以上",
  737. value: 4,
  738. isShow: false,
  739. },
  740. ],
  741. levelList: [
  742. {
  743. label: "A",
  744. value: 1,
  745. isShow: false,
  746. },
  747. {
  748. label: "B",
  749. value: 2,
  750. isShow: false,
  751. },
  752. {
  753. label: "C",
  754. value: 3,
  755. isShow: false,
  756. },
  757. {
  758. label: "D",
  759. value: 4,
  760. isShow: false,
  761. },
  762. ],
  763. sourceList: [],//客户来源
  764. isRefresh: false,
  765. // 筛选文字展示
  766. sortFilter: "排序",
  767. arriveFilter: "到访时间",
  768. receptionDuration: "所属顾问",
  769. };
  770. },
  771. onLoad(options) {
  772. this.LOADING = true;
  773. this.isnorefresh = options.refresh;
  774. },
  775. onShow() {
  776. // dataCode: 身份标识 2:项目总、3:客服、4:策划、5:经理、6:置业顾问
  777. this.userInfo = uni.getStorageSync('weapp_session_userInfo_data');
  778. if (this.isnorefresh == "refresh") {
  779. this.buildingID = uni.getStorageSync("buildingID").id;
  780. this.nextPage = 1;
  781. this.recordList = [];
  782. this.isRefresh = false;
  783. this.getMyCustom();
  784. this.getFreeList();
  785. this.getWordMiningList();
  786. this.getCustomPhase();
  787. this.getFromSource();
  788. this.isnorefresh = "";
  789. }
  790. },
  791. onPullDownRefresh() {
  792. this.resetFilter();
  793. this.isRefresh = true;
  794. this.nextPage = 1;
  795. this.getMyCustom();
  796. setTimeout(() => {
  797. uni.stopPullDownRefresh();
  798. }, 1000);
  799. },
  800. onReachBottom() {
  801. if (this.totalRecord == this.nextPage) {
  802. uni.showToast({
  803. icon: "none",
  804. title: "到底了",
  805. duration: 2000,
  806. });
  807. return;
  808. } else {
  809. this.nextPage += 1;
  810. this.isRefresh = false;
  811. this.getMyCustom();
  812. }
  813. },
  814. methods: {
  815. // 获取客户来源
  816. getFromSource() {
  817. this.$u.get(config.service.sourceList, {
  818. houseId: this.buildingID
  819. })
  820. .then((res) => {
  821. console.log(res)
  822. if(res.length){
  823. this.sourceList = res.map((item) => {
  824. return {
  825. label: item.sourceName,
  826. value: item.id,
  827. isShow: false
  828. }
  829. })
  830. }else{
  831. this.sourceList = []
  832. }
  833. })
  834. },
  835. // 过滤
  836. resetFilter() {
  837. this.sortFilter = "排序";
  838. this.receptionDuration = "所属顾问";
  839. this.arriveFilter = "到访时间";
  840. this.screen.orderBy = '';
  841. this.screen.staTime = "";
  842. this.screen.endTime = "";
  843. this.nextPage = 1;
  844. this.activeTotal = 5;
  845. this.recordList = [];
  846. },
  847. choice(item) {
  848. item.isShow = !item.isShow;
  849. },
  850. //选择标签
  851. selectCallback2(e) {
  852. this.sortFilter = e[0].label;
  853. this.screen.orderBy = e[0].value;
  854. this.nextPage = 1;
  855. this.recordList = [];
  856. this.isRefresh = false;
  857. this.getMyCustom();
  858. },
  859. //选择录音时长
  860. timetap(index, text) {
  861. if (text) this.receptionDuration = text;
  862. this.nextPage = 1;
  863. this.recordList = [];
  864. this.isRefresh = false;
  865. this.getMyCustom();
  866. },
  867. //时间选择
  868. tabtimetap(index, text) {
  869. this.timeshow = false;
  870. if (text) this.arriveFilter = text;
  871. if (index == 4) {
  872. this.totalTimeShow = true;
  873. } else {
  874. this.activeTotal = index;
  875. this.screen.staTime = "";
  876. this.screen.endTime = "";
  877. this.nextPage = 1;
  878. this.recordList = [];
  879. this.isRefresh = false;
  880. this.getMyCustom();
  881. }
  882. },
  883. //自定义时间
  884. totalTimeChange(e) {
  885. this.screen.staTime = e.startDate;
  886. this.screen.endTime = e.endDate;
  887. this.activeTotal = 4;
  888. this.nextPage = 1;
  889. this.recordList = [];
  890. this.isRefresh = false;
  891. this.getMyCustom();
  892. },
  893. // 字典表接口
  894. getListByType() {
  895. this.$u
  896. .get("/matchKeywords/findPersonalMatchData", {
  897. customerId: this.customerId,
  898. })
  899. .then((res) => {
  900. // console.log(res)
  901. res.forEach((item1) => {
  902. item1.children.map((item) => {
  903. if (item.isInterval == 0) {
  904. item.label =
  905. item.name + item.unit + "-" + item.endName + item.unit;
  906. } else {
  907. item.label = item.name;
  908. }
  909. item.value = item.id;
  910. });
  911. });
  912. // console.log(res)
  913. this.allList = res;
  914. });
  915. },
  916. // 客户详情
  917. gotoDetail(id) {
  918. uni.navigateTo({
  919. url: `/pages/center/consumer/consumerDetail?id=${id}`,
  920. });
  921. },
  922. getMyCustom() {
  923. this.screen.visitRecord = []
  924. this.screen.jiedaiVal = []
  925. this.screen.wajueVal = []
  926. this.screen.xiaojiangVal = []
  927. this.screen.level = []
  928. this.screen.clientStage = []
  929. this.screen.sourceIds = []
  930. let keywordsIds = []
  931. let dateType = 0;
  932. if (this.activeTotal == 5||this.activeTotal == 4) {
  933. dateType = null;
  934. } else {
  935. dateType = this.activeTotal;
  936. }
  937. // 到访次数
  938. this.visitList.forEach(i => {
  939. if(i.isShow) this.screen.visitRecord.push(i.value)
  940. })
  941. // 接待时长
  942. this.jiedaiList.forEach(i => {
  943. if(i.isShow) this.screen.jiedaiVal.push(i.value)
  944. })
  945. // 需求挖掘
  946. this.wajueList.forEach(i => {
  947. if(i.isShow) this.screen.wajueVal.push(i.value)
  948. })
  949. // 销讲执行率
  950. this.xiaojiangList.forEach(i => {
  951. if(i.isShow) this.screen.xiaojiangVal.push(i.value)
  952. })
  953. // 客户等级
  954. this.levelList.forEach(i => {
  955. if(i.isShow) this.screen.level.push(i.value)
  956. })
  957. //客户阶段
  958. this.phaseList.forEach(i => {
  959. if(i.isShow) this.screen.clientStage.push(i.value)
  960. })
  961. // 客户来源
  962. this.sourceList.forEach(i => {
  963. if(i.isShow) this.screen.sourceIds.push(i.value)
  964. })
  965. this.huaxiangList.forEach(item => {
  966. if(item.children.length){
  967. item.children.forEach(im=>{
  968. if(im.isShow) keywordsIds.push(im.id)
  969. })
  970. }
  971. })
  972. var parames = {
  973. pageNum: this.nextPage,
  974. pageSize: 10,
  975. query: {
  976. projectId: this.buildingID,
  977. fractions: this.screen.xiaojiangVal.length?this.screen.xiaojiangVal.join(','):'',// 销讲执行率
  978. wordFractions: this.screen.wajueVal.length?this.screen.wajueVal.join(','):'',//需求挖掘
  979. visitRecordNum: this.screen.visitRecord.length?this.screen.visitRecord.join(','):'',//到访次数
  980. clientStages: this.screen.clientStage.length?this.screen.clientStage.join(','):'', // 客户阶段
  981. sourceIds: this.screen.sourceIds.length?this.screen.sourceIds.join(','):'',// 客户来源
  982. level: this.screen.level.length?this.screen.level.join(','):'',// 客户等级
  983. duractionNums: this.screen.jiedaiVal.length?this.screen.jiedaiVal.join(','):'',// 接待时长
  984. keywordsIds: keywordsIds.length?keywordsIds.join(','):'',// 画像标签
  985. dateType: dateType, // 接待时间
  986. staTime: this.screen.staTime,
  987. endTime: this.screen.endTime,
  988. agentId: this.screen.agentId,// 顾问
  989. orderBy: this.screen.orderBy==''?'': this.screen.orderBy,// 排序
  990. },
  991. };
  992. this.$u.post("/customer/customerManagement", parames)
  993. .then((data) => {
  994. this.LOADING = false;
  995. // if (this.screen.staTime && this.screen.endTime) {
  996. // this.arriveFilter = `${this.screen.staTime}-${this.screen.endTime}`;
  997. // }
  998. var list = data.results || [];
  999. list.forEach((item) => {
  1000. if (this.userInfo.dataCode == 6) {
  1001. item.isshow = true;
  1002. } else {
  1003. item.isshow = false;
  1004. }
  1005. });
  1006. list.forEach((item) => {
  1007. if (item.demand.cusSemanticWordsList != null) {
  1008. item.demand.cusSemanticWordsList.forEach((che) => {
  1009. if (che.isInterval == 0) {
  1010. che.name = che.name + che.unit + "-" + che.endName + che.unit;
  1011. }
  1012. });
  1013. }else{
  1014. item.demand.cusSemanticWordsList = []
  1015. }
  1016. });
  1017. if (this.isRefresh) {
  1018. this.recordList = list;
  1019. } else {
  1020. this.recordList = [...this.recordList, ...list];
  1021. }
  1022. this.totalRecord = data.totalPage;
  1023. this.totalRecords = data.totalRecord;
  1024. })
  1025. .catch((e) => {
  1026. this.LOADING = false;
  1027. });
  1028. },
  1029. //获取画像标签
  1030. getWordMiningList() {
  1031. this.huaxiangList = [];
  1032. this.$u.get("/corpus/findSelectedWordMiningTemplate", {
  1033. houseId: this.buildingID,
  1034. selected: 1
  1035. })
  1036. .then((res) => {
  1037. // console.log(res)
  1038. if(res.length){
  1039. res.forEach(item=>{
  1040. item.isShow = true;
  1041. if(item.children.length){
  1042. item.children.forEach(subitem=>{
  1043. subitem.isShow = false;
  1044. })
  1045. }
  1046. })
  1047. }
  1048. this.huaxiangList = res;
  1049. });
  1050. },
  1051. //获取顾问列表
  1052. getFreeList() {
  1053. if(this.userInfo.dataCode==6){
  1054. this.freeList = [{
  1055. label: this.userInfo.name,
  1056. value: this.userInfo.accountId
  1057. }]
  1058. }else{
  1059. this.freeList = [];
  1060. this.$u.post("/cusLvStatistics/selectAllAccountIdByHouseId", {
  1061. houseId: this.buildingID,
  1062. })
  1063. .then((res) => {
  1064. this.freeList = res;
  1065. this.freeList.forEach((item) => {
  1066. item.label = item.name;
  1067. item.value = item.accountId;
  1068. });
  1069. this.freeList.unshift({
  1070. label: '全部',
  1071. value: '',
  1072. })
  1073. });
  1074. }
  1075. },
  1076. // 获取客户阶段数据
  1077. getCustomPhase() {
  1078. this.phaseList = [];
  1079. this.$u
  1080. .post("/customer/lifeTrackDefineList", {
  1081. houseId: this.buildingID,
  1082. })
  1083. .then((res) => {
  1084. if(res.length){
  1085. this.phaseList = res.map(item=>{
  1086. return {
  1087. label: item.stageName,
  1088. value: item.id,
  1089. isShow: false
  1090. }
  1091. })
  1092. }else{
  1093. this.phaseList =[]
  1094. }
  1095. });
  1096. },
  1097. //选择顾问
  1098. actionSelectCallback(e) {
  1099. this.screen.agentId = e[0].value;
  1100. this.receptionDuration = e[0].label;
  1101. this.nextPage = 1;
  1102. this.recordList = [];
  1103. this.screenShow = false;
  1104. this.huaxiangShow = false;
  1105. this.isRefresh = false;
  1106. this.getMyCustom();
  1107. },
  1108. // 客户阶段
  1109. selectPhase(e) {
  1110. this.screen.clientStageName = e[0].label;
  1111. this.screen.clientStage = e[0].value;
  1112. },
  1113. //重置
  1114. reset() {
  1115. this.screen = {
  1116. agentId: "",
  1117. visitRecord: [],
  1118. record: [],
  1119. clientStage: "",
  1120. clientStageName: "",
  1121. };
  1122. this.sourceList.map((i) => {
  1123. i.isShow = false;
  1124. });
  1125. this.wajueList.map((i) => {
  1126. i.isShow = false;
  1127. });
  1128. this.phaseList.map((i) => {
  1129. i.isShow = false;
  1130. });
  1131. this.jiedaiList.map((i) => {
  1132. i.isShow = false;
  1133. });
  1134. this.xiaojiangList.map((i) => {
  1135. i.isShow = false;
  1136. });
  1137. this.visitList.map((i) => {
  1138. i.isShow = false;
  1139. });
  1140. this.levelList.map((i) => {
  1141. i.isShow = false;
  1142. });
  1143. this.nextPage = 1;
  1144. this.recordList = [];
  1145. this.isRefresh = false;
  1146. this.getMyCustom();
  1147. },
  1148. //重置画像标签选择
  1149. resetHuaXiang(){
  1150. if(this.huaxiangList.length){
  1151. this.huaxiangList.forEach(item=>{
  1152. item.isShow = true;
  1153. if(item.children.length){
  1154. item.children.forEach(subitem=>{
  1155. subitem.isShow = false;
  1156. })
  1157. }
  1158. })
  1159. }
  1160. },
  1161. //筛选确认
  1162. screensure() {
  1163. this.nextPage = 1;
  1164. this.recordList = [];
  1165. this.screenShow = false;
  1166. this.huaxiangShow = false;
  1167. this.isRefresh = false;
  1168. this.getMyCustom();
  1169. },
  1170. goSearch() {
  1171. uni.navigateTo({
  1172. url: "/pages/center/consumer/consumerSearch",
  1173. });
  1174. },
  1175. gotoFollowUp(id) {
  1176. uni.navigateTo({
  1177. url: `/pages/center/consumer/newFollowup/newFollowup?id=${id}`,
  1178. });
  1179. },
  1180. },
  1181. };
  1182. </script>
  1183. <style lang="scss" scoped>
  1184. .box {
  1185. width: 100%;
  1186. height: 100%;
  1187. background: #f8f8f8;
  1188. }
  1189. .count {
  1190. width: 100%;
  1191. height: 60rpx;
  1192. display: flex;
  1193. align-items: center;
  1194. justify-content: center;
  1195. background-color: #fff;
  1196. border-top: 1px solid #e0e0e0;
  1197. text {
  1198. color: #f71616;
  1199. }
  1200. }
  1201. .timeview {
  1202. height: 80rpx;
  1203. line-height: 80rpx;
  1204. width: 100%;
  1205. text-align: center;
  1206. border-bottom: 1px solid #f8f8f8;
  1207. }
  1208. //时间切换的样式
  1209. .boxtittab {
  1210. position: sticky;
  1211. top: var(--window-top);
  1212. z-index: 999;
  1213. width: 100;
  1214. height: 92rpx;
  1215. background: #ffffff;
  1216. display: flex;
  1217. align-items: center;
  1218. .tabbox {
  1219. flex: 1;
  1220. height: 100%;
  1221. text-align: center;
  1222. line-height: 92rpx;
  1223. color: #666666;
  1224. font-size: 28rpx;
  1225. overflow: hidden;
  1226. text-overflow: ellipsis;
  1227. display: -webkit-box;
  1228. /* 将对象作为弹性伸缩盒子模型显示 */
  1229. -webkit-line-clamp: 1;
  1230. /* 控制最多显示几行 */
  1231. -webkit-box-orient: vertical;
  1232. /* 设置或检索伸缩盒对象的子元素的排列方式 */
  1233. }
  1234. }
  1235. .top-search {
  1236. display: flex;
  1237. align-items: center;
  1238. justify-content: space-between;
  1239. background: #fff;
  1240. padding-right: 30rpx;
  1241. .filter-icon {
  1242. width: 40rpx;
  1243. height: 40rpx;
  1244. padding: 15rpx;
  1245. }
  1246. .search-box {
  1247. width: 670rpx;
  1248. height: 102rpx;
  1249. background: #ffffff;
  1250. display: flex;
  1251. align-items: center;
  1252. justify-content: center;
  1253. .search {
  1254. width: 94%;
  1255. height: 70rpx;
  1256. display: flex;
  1257. align-items: center;
  1258. background: #f8f8f8;
  1259. border-radius: 33rpx;
  1260. .search-img {
  1261. width: 26rpx;
  1262. height: 30rpx;
  1263. margin-left: 20rpx;
  1264. .search-img1 {
  1265. width: 100%;
  1266. height: 100%;
  1267. margin-top: 2rpx;
  1268. }
  1269. }
  1270. .search-text {
  1271. font-size: 28rpx;
  1272. font-weight: 400;
  1273. color: #999999;
  1274. margin-left: 10rpx;
  1275. }
  1276. }
  1277. .search-screen {
  1278. width: 40rpx;
  1279. height: 40rpx;
  1280. margin-left: 30rpx;
  1281. .search-screen1 {
  1282. width: 100%;
  1283. height: 100%;
  1284. }
  1285. }
  1286. }
  1287. }
  1288. .content {
  1289. overflow: hidden;
  1290. .content-tips {
  1291. background: #fff;
  1292. margin-top: 20rpx;
  1293. overflow: hidden;
  1294. padding-bottom: 30rpx;
  1295. .content-first {
  1296. padding: 19rpx 30rpx;
  1297. display: flex;
  1298. justify-content: space-between;
  1299. box-sizing: border-box;
  1300. font-weight: 400;
  1301. color: #292929;
  1302. height: 90rpx;
  1303. font-size: 30rpx;
  1304. line-height: 30rpx;
  1305. .left {
  1306. display: flex;
  1307. .img {
  1308. width: 52rpx;
  1309. height: 52rpx;
  1310. border-radius: 50%;
  1311. text-align: center;
  1312. line-height: 50rpx;
  1313. margin-right: 20rpx;
  1314. color: #fff;
  1315. font-size: 30rpx;
  1316. background: #9f61c8;
  1317. }
  1318. .test {
  1319. margin-top: 11rpx;
  1320. font-weight: 500;
  1321. color: #333333;
  1322. }
  1323. }
  1324. .right {
  1325. display: flex;
  1326. .test {
  1327. margin-top: 11rpx;
  1328. .blue {
  1329. font-size: 32rpx;
  1330. font-family: PingFangSC-Medium, PingFang SC;
  1331. font-weight: 500;
  1332. color: #2671e2;
  1333. }
  1334. }
  1335. }
  1336. }
  1337. .content-sec {
  1338. border-top: 1px solid #e0e0e0;
  1339. padding: 0 30rpx;
  1340. // padding-bottom: 30rpx;
  1341. position: relative;
  1342. .content-sec-lab {
  1343. margin-top: 28rpx;
  1344. display: flex;
  1345. justify-content: space-between;
  1346. font-size: 30rpx;
  1347. font-weight: 400;
  1348. color: #666666;
  1349. line-height: 42rpx;
  1350. .content-sec-lab1 {
  1351. color: #333333;
  1352. }
  1353. .content-sec-tips {
  1354. max-width: 160rpx;
  1355. height: 46rpx;
  1356. background: #f2f2f2;
  1357. border-radius: 6rpx;
  1358. text-align: center;
  1359. line-height: 26rpx;
  1360. overflow: hidden;
  1361. text-overflow: ellipsis;
  1362. white-space: nowrap;
  1363. font-size: 26rpx;
  1364. font-weight: 400;
  1365. color: #333333;
  1366. margin-right: 20rpx;
  1367. box-sizing: border-box;
  1368. padding: 10rpx 24rpx;
  1369. }
  1370. }
  1371. .content-sec-num {
  1372. position: absolute;
  1373. width: 200rpx;
  1374. height: 90rpx;
  1375. background: #f4f8fd;
  1376. border-radius: 12rpx;
  1377. font-weight: 400;
  1378. color: #2671e2;
  1379. line-height: 45rpx;
  1380. bottom: 30rpx;
  1381. right: 30rpx;
  1382. text-align: center;
  1383. }
  1384. }
  1385. .content-last {
  1386. display: flex;
  1387. height: 42rpx;
  1388. margin-top: 30rpx;
  1389. .content-last-tab {
  1390. width: 33.4%;
  1391. text-align: center;
  1392. font-size: 30rpx;
  1393. font-weight: 400;
  1394. color: #333333;
  1395. line-height: 78rpx;
  1396. display: flex;
  1397. align-items: center;
  1398. justify-content: center;
  1399. .icon {
  1400. width: 40rpx;
  1401. height: 40rpx;
  1402. margin-right: 12rpx;
  1403. }
  1404. }
  1405. }
  1406. }
  1407. }
  1408. // 这是弹出层
  1409. .screen {
  1410. .screen-record {
  1411. overflow: hidden;
  1412. padding: 0 30rpx;
  1413. box-sizing: border-box;
  1414. border-bottom: 1px solid #e0e0e0;
  1415. .screen-record-text {
  1416. font-weight: 600;
  1417. padding: 30rpx 0;
  1418. font-size: 30rpx;
  1419. color: #333333;
  1420. line-height: 30rpx;
  1421. display: flex;
  1422. align-items: center;
  1423. justify-content: space-between;
  1424. .arrow {
  1425. width: 30rpx;
  1426. height: 14rpx;
  1427. }
  1428. }
  1429. .screen-record-tab {
  1430. margin-top: 30rpx;
  1431. padding-bottom: 10rpx;
  1432. display: flex;
  1433. flex-wrap: wrap;
  1434. .screen-record-item {
  1435. min-width: 150rpx;
  1436. padding: 0 14rpx;
  1437. height: 60rpx;
  1438. border-radius: 8rpx;
  1439. text-align: center;
  1440. line-height: 60rpx;
  1441. margin: 0 22rpx 22rpx 0;
  1442. &:nth-child(4n) {
  1443. margin-right: 0;
  1444. }
  1445. }
  1446. .screen-record-chose {
  1447. background: #f1f6fd;
  1448. color: #2671e2;
  1449. }
  1450. .screen-record-nochose {
  1451. background: #f7f8fa;
  1452. color: #333;
  1453. }
  1454. }
  1455. }
  1456. .screen-foot {
  1457. width: 100%;
  1458. height: 78rpx;
  1459. display: flex;
  1460. margin: 30rpx 30rpx 0;
  1461. .screen-foot-reset {
  1462. width: 176rpx;
  1463. height: 78rpx;
  1464. line-height: 78rpx;
  1465. background: #FFFFFF;
  1466. border-radius: 8rpx;
  1467. border: 1px solid #2671E2;
  1468. margin-right: 30rpx;
  1469. font-size: 30rpx;
  1470. font-family: PingFangSC-Regular, PingFang SC;
  1471. font-weight: 400;
  1472. color: #2671E2;
  1473. text-align: center;
  1474. }
  1475. .screen-foot-sure {
  1476. width: 484rpx;
  1477. height: 78rpx;
  1478. line-height: 78rpx;
  1479. background: #2671E2;
  1480. border: 1px solid #2671E2;
  1481. border-radius: 8rpx;
  1482. font-size: 30rpx;
  1483. font-family: PingFangSC-Regular, PingFang SC;
  1484. font-weight: 400;
  1485. color: #FFFFFF;
  1486. text-align: center;
  1487. }
  1488. }
  1489. }
  1490. </style>