Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 
 

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