AI销管
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 
 

1309 行
34 KiB

  1. <template>
  2. <view class="box">
  3. <!-- 选择器 -->
  4. <view class="boxtittab">
  5. <view class="tabbox" :class="{activeColor: arriveFilter!=='接待时间'}" @click="timeshow = true">
  6. {{ arriveFilter }}
  7. <u-icon name="arrow-down" size="24" style="padding-left: 12rpx;"></u-icon>
  8. </view>
  9. <view class="tabbox" :class="{activeColor:counselorName!=='接待顾问'}" @click="selectshow=true">
  10. {{ counselorName }}
  11. <u-icon name="arrow-down" size="24" style="padding-left: 12rpx;"></u-icon>
  12. </view>
  13. <view class="tabbox" :class="{activeColor: sortText!=='排序'}" @click="soltishow = true">
  14. {{ sortText }}
  15. <u-icon name="arrow-down" size="24" style="padding-left: 12rpx;"></u-icon>
  16. </view>
  17. <view class="tabbox" :class="{activeColor: chooseMore}" @click="screenShow = true">
  18. 更多筛选<u-icon name="arrow-down" size="24" style="padding-left: 12rpx;"></u-icon>
  19. </view>
  20. </view>
  21. <!-- 筛选后的数量 -->
  22. <view class="count" v-if="recordList.length > 0">
  23. 筛选结果:<text>{{totalRecords}}</text>条
  24. </view>
  25. <view class="content">
  26. <view v-if="recordList.length == 0"
  27. style="width: 100%;height: 100%;display: flex;align-items: center;background: #FFFFFF;">
  28. <view style="width: 100%;padding-top: 200rpx;">
  29. <view style="width: 100%;text-align: center;">
  30. <image style="width: 220rpx;height: 200rpx;"
  31. src="https://static.quhouse.com/zhikong_xcx_img/nodatalist.png" mode=""></image>
  32. </view>
  33. <view style="text-align: center;width: 100%;margin-top: 20rpx;color: #999999;">暂无数据</view>
  34. </view>
  35. </view>
  36. <view v-else class="content-tips" v-for="(item,index) in recordList" :key='index'
  37. @click="tapThevisiting(item)">
  38. <view class="content-first">
  39. <view class="left">
  40. <view class="adviser">顾</view>
  41. <view class="name">{{item.agentName}}</view>
  42. </view>
  43. <view class="right" v-if="item.recording!=0">
  44. <view v-if="item.receptionStatusName" style="margin-right: 6rpx;color: red;">
  45. {{item.receptionStatusName.slice(0, 2) || ''}}
  46. </view>
  47. <text style="margin-right: 6rpx;" v-if="item.receptionStatusName"> |</text>
  48. <view v-if="methodsisshow">
  49. <text style="margin-right: 6rpx;color: red;" v-if="item.taboo==1">违禁接待</text>
  50. <text style="margin-right: 6rpx;" v-if="item.taboo==1"> |</text>
  51. </view>
  52. <view v-if="item.validInvalidName" style="margin-right: 6rpx;">
  53. {{item.validInvalidName.slice(0, 2)||''}}
  54. </view>
  55. <text style="margin-right: 6rpx;" v-if="item.validInvalidName"> |</text>
  56. <view v-if="item.markAdvisor==0" class="">未标记</view>
  57. <view v-if="item.markAdvisor==1" class="">已标记</view>
  58. </view>
  59. <view class="right" v-else>
  60. <view class="">无录音</view>
  61. </view>
  62. </view>
  63. <view class="content-sec">
  64. <view class="left">
  65. <view class="adviser">客</view>
  66. <view class="cus">{{item.name || '--'}}</view>
  67. <view class="arriveNum">{{ item.phone | encryption }}</view>
  68. </view>
  69. <view class="right">
  70. <!-- 销讲业务:{{item.marketingBusiness || ''}} -->
  71. </view>
  72. </view>
  73. <view class="content-newadd">
  74. <view class="c-items">
  75. 挖掘执行:{{item.wordFraction||0}}%
  76. </view>
  77. <view class="c-items">
  78. 挖掘成功:{{item.wordFinishFraction||0}}%
  79. </view>
  80. <view class="c-items u-flex">
  81. 销讲执行:<view class="value" style="color: #2671E2;font-weight:bold;">{{item.fraction||0}}%</view>
  82. </view>
  83. </view>
  84. <view class="content-last">
  85. <view class="c-items">
  86. <image src="../static/img/people.png" class="c-items-img" mode=""></image>
  87. {{ item.visitRecord || "--" }}次到访
  88. </view>
  89. <view class="c-items">
  90. <image src="../static/img/time.png" class="c-items-img" mode=""></image>
  91. {{ item.createTime }}
  92. </view>
  93. <view class="c-items">
  94. <image src="../static/img/voice.png" class="c-items-img" mode=""></image>
  95. {{ item.mm || '0' }}min
  96. </view>
  97. </view>
  98. </view>
  99. </view>
  100. <u-popup v-model="screenShow" mode="top" height="900">
  101. <view class="screen">
  102. <scroll-view scroll-y="true" style="height: 750rpx;">
  103. <!-- 销讲业务 -->
  104. <view class="screen-record">
  105. <view class="screen-record-text" @click="showTemplate=!showTemplate">
  106. 销讲业务
  107. <image v-if="showTemplate" class="arrow"
  108. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  109. <image v-else class="arrow"
  110. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  111. </view>
  112. <view class="screen-record-tab" v-if="showTemplate">
  113. <block v-for="(item,index) in templateList" :key="index">
  114. <view class="screen-record-item"
  115. :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
  116. @click="choice(item)">
  117. {{item.templateName}}
  118. </view>
  119. </block>
  120. </view>
  121. </view>
  122. <!-- 销讲执行率 -->
  123. <view class="screen-record">
  124. <view class="screen-record-text" @click="xiaojiangArrow=!xiaojiangArrow">
  125. 销讲执行率
  126. <image v-if="xiaojiangArrow" class="arrow"
  127. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  128. <image v-else class="arrow"
  129. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  130. </view>
  131. <view class="screen-record-tab" v-if="xiaojiangArrow">
  132. <block v-for="(item,index) in xiaojiangList" :key="index">
  133. <view class="screen-record-item"
  134. :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
  135. @click="choice(item)">
  136. {{item.label}}
  137. </view>
  138. </block>
  139. </view>
  140. </view>
  141. <!-- 需求挖掘率 -->
  142. <view class="screen-record">
  143. <view class="screen-record-text" @click="wajueArrow=!wajueArrow">
  144. 挖掘执行率
  145. <image v-if="wajueArrow" class="arrow"
  146. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  147. <image v-else class="arrow"
  148. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  149. </view>
  150. <view class="screen-record-tab" v-if="wajueArrow">
  151. <block v-for="(item,index) in wajueList" :key="index">
  152. <view class="screen-record-item"
  153. :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
  154. @click="choice(item)">
  155. {{item.label}}
  156. </view>
  157. </block>
  158. </view>
  159. </view>
  160. <!-- 需求挖掘率 -->
  161. <view class="screen-record">
  162. <view class="screen-record-text" @click="wajueArrows=!wajueArrows">
  163. 挖掘成功率
  164. <image v-if="wajueArrows" class="arrow"
  165. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  166. <image v-else class="arrow"
  167. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  168. </view>
  169. <view class="screen-record-tab" v-if="wajueArrows">
  170. <block v-for="(item,index) in wajueLists" :key="index">
  171. <view class="screen-record-item"
  172. :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
  173. @click="choice(item)">
  174. {{item.label}}
  175. </view>
  176. </block>
  177. </view>
  178. </view>
  179. <!-- 接待时长 -->
  180. <view class="screen-record">
  181. <view class="screen-record-text" @click="jiedaiArrow=!jiedaiArrow">
  182. 接待时长
  183. <image v-if="jiedaiArrow" class="arrow"
  184. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  185. <image v-else class="arrow"
  186. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  187. </view>
  188. <view class="screen-record-tab" v-if="jiedaiArrow">
  189. <block v-for="(item,index) in jiedaiList" :key="index">
  190. <view class="screen-record-item"
  191. :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
  192. @click="choice(item)">
  193. {{item.label}}
  194. </view>
  195. </block>
  196. </view>
  197. </view>
  198. <!-- 录音标识 -->
  199. <view class="screen-record">
  200. <view class="screen-record-text" @click="luyinArrow=!luyinArrow">
  201. 录音标识
  202. <image v-if="luyinArrow" class="arrow"
  203. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  204. <image v-else class="arrow"
  205. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  206. </view>
  207. <view class="screen-record-tab" v-if="luyinArrow">
  208. <view class="screen-record-item"
  209. :class="[screen.validInvalid===0?'screen-record-chose':'screen-record-nochose']"
  210. @click="screenvisivalidInvalid(0)">
  211. 有效接待
  212. </view>
  213. <view class="screen-record-item"
  214. :class="[screen.validInvalid===1?'screen-record-chose':'screen-record-nochose']"
  215. @click="screenvisivalidInvalid(1)">
  216. 无效接待
  217. </view>
  218. <view class="screen-record-item"
  219. :class="[screen.validInvalid===2?'screen-record-chose':'screen-record-nochose']"
  220. @click="screenvisivalidInvalid(2)">
  221. 无录音
  222. </view>
  223. <view class="screen-record-item"
  224. :class="[screen.validInvalid===3?'screen-record-chose':'screen-record-nochose']"
  225. @click="screenvisivalidInvalid(3)">
  226. 无效(未审核)
  227. </view>
  228. </view>
  229. </view>
  230. <!-- 标记顾问 -->
  231. <view class="screen-record">
  232. <view class="screen-record-text" @click="markArrow=!markArrow">
  233. 标记顾问
  234. <image v-if="markArrow" class="arrow"
  235. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  236. <image v-else class="arrow"
  237. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  238. </view>
  239. <view class="screen-record-tab" v-if="markArrow">
  240. <view class="screen-record-item"
  241. :class="[screen.markAdvisor==1?'screen-record-chose':'screen-record-nochose']"
  242. @click="screenvisitRecord(1)">
  243. 标记
  244. </view>
  245. <view class="screen-record-item"
  246. :class="[screen.markAdvisor===0?'screen-record-chose':'screen-record-nochose']"
  247. @click="screenvisitRecord(0)">
  248. 未标记
  249. </view>
  250. </view>
  251. </view>
  252. <!-- 到访次数 -->
  253. <view class="screen-record">
  254. <view class="screen-record-text" @click="visitArrow=!visitArrow">
  255. 到访次数
  256. <image v-if="visitArrow" class="arrow"
  257. src="https://static.quhouse.com/6cf38a2b82694392a7ab6eea24ce76b1.png" mode="" />
  258. <image v-else class="arrow"
  259. src="https://static.quhouse.com/17d69984ec7c4830b43f712016f06807.png" mode="" />
  260. </view>
  261. <view class="screen-record-tab" v-if="visitArrow">
  262. <block v-for="(item,index) in visitList" :key="index">
  263. <view class="screen-record-item"
  264. :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
  265. @click="choice(item)">
  266. {{item.label}}
  267. </view>
  268. </block>
  269. </view>
  270. </view>
  271. </scroll-view>
  272. <view class="screen-foot">
  273. <view class="screen-foot-reset" @click="reset">
  274. 重置
  275. </view>
  276. <view class="screen-foot-sure" @click="screensure">
  277. 确定
  278. </view>
  279. </view>
  280. </view>
  281. </u-popup>
  282. <!-- 选择顾问的选择框 -->
  283. <u-select v-model="selectshow" :list="freeList" @confirm="actionSelectCallback"></u-select>
  284. <u-calendar v-model="totalTimeShow" mode="range" @change="totalTimeChange"></u-calendar>
  285. <u-popup v-model="timeshow" mode="bottom">
  286. <view class="timeview" :style="{ color: activeTotal == 5 ? '#2B6EFF' : '#333333' }"
  287. @click="tabtimetap(5, '接待时间')">
  288. 全部</view>
  289. <view class="timeview" :style="{ color: activeTotal == 0 ? '#2B6EFF' : '#333333' }"
  290. @click="tabtimetap(0, '今天')">
  291. 今天</view>
  292. <view class="timeview" :style="{ color: activeTotal == 1 ? '#2B6EFF' : '#333333' }"
  293. @click="tabtimetap(1, '昨天')">
  294. 昨天</view>
  295. <view class="timeview" :style="{ color: activeTotal == 2 ? '#2B6EFF' : '#333333' }"
  296. @click="tabtimetap(2, '近7天')">
  297. 近7天</view>
  298. <view class="timeview" :style="{ color: activeTotal == 3 ? '#2B6EFF' : '#333333' }"
  299. @click="tabtimetap(3, '近30天')">
  300. 近30天</view>
  301. <view class="timeview" :style="{ color: activeTotal == 4 ? '#2B6EFF' : '#333333' }" @click="tabtimetap(4)">
  302. 自定义</view>
  303. </u-popup>
  304. <u-select v-model="soltishow" :list="orderBylist" @confirm="selectCallback2"></u-select>
  305. <!-- 加载组件 -->
  306. <u-loadings v-model="LOADING"></u-loadings>
  307. </view>
  308. </template>
  309. <script>
  310. export default {
  311. data() {
  312. return {
  313. templateList: [], // 销讲业务
  314. showTemplate: true, // 展示销讲业务
  315. orderBylist: [
  316. // {
  317. // label: '全部',
  318. // value: '0'
  319. // },
  320. {
  321. label: '创建时间倒序',
  322. value: '1'
  323. },
  324. {
  325. label: '创建时间正序',
  326. value: '2'
  327. },
  328. {
  329. label: '接待时间倒序',
  330. value: '3'
  331. },
  332. {
  333. label: '接待时间正序',
  334. value: '4'
  335. },
  336. {
  337. label: '执行率正序',
  338. value: '5'
  339. },
  340. {
  341. label: '执行率倒序',
  342. value: '6'
  343. },
  344. {
  345. label: '接访次数正序',
  346. value: '7'
  347. },
  348. {
  349. label: '接访次数倒序',
  350. value: '8'
  351. },
  352. ],
  353. jiedaiList: [{
  354. label: '0~15min',
  355. value: 1,
  356. isShow: false,
  357. }, {
  358. label: '16~30min',
  359. value: 2,
  360. isShow: false,
  361. }, {
  362. label: '31~60min',
  363. value: 3,
  364. isShow: false,
  365. }, {
  366. label: '61~90min',
  367. value: 4,
  368. isShow: false,
  369. }, {
  370. label: '91min及以上',
  371. value: 5,
  372. isShow: false,
  373. }],
  374. wajueList: [{
  375. label: '30%及以下',
  376. value: 1,
  377. isShow: false,
  378. }, {
  379. label: '31%~50%',
  380. value: 2,
  381. isShow: false,
  382. }, {
  383. label: '51%~70%',
  384. value: 3,
  385. isShow: false,
  386. }, {
  387. label: '71%及以上',
  388. value: 4,
  389. isShow: false,
  390. }],
  391. wajueLists: [{
  392. label: '30%及以下',
  393. value: 1,
  394. isShow: false,
  395. }, {
  396. label: '31%~50%',
  397. value: 2,
  398. isShow: false,
  399. }, {
  400. label: '51%~70%',
  401. value: 3,
  402. isShow: false,
  403. }, {
  404. label: '71%及以上',
  405. value: 4,
  406. isShow: false,
  407. }],
  408. xiaojiangList: [{
  409. label: '30%及以下',
  410. value: 1,
  411. isShow: false,
  412. }, {
  413. label: '31%~50%',
  414. value: 2,
  415. isShow: false,
  416. }, {
  417. label: '51%~70%',
  418. value: 3,
  419. isShow: false,
  420. }, {
  421. label: '71%及以上',
  422. value: 4,
  423. isShow: false,
  424. }],
  425. activeTotal: 5,
  426. value: '',
  427. screenShow: false,
  428. wajueArrow: true,
  429. wajueArrows: true,
  430. jiedaiArrow: true,
  431. markArrow: true,
  432. visitArrow: true,
  433. xiaojiangArrow: true,
  434. luyinArrow: true,
  435. selectshow: false,
  436. totalTimeShow: false,
  437. totalRecords: '',
  438. screen: {
  439. orderBy: '', //排序
  440. agentId: '', //顾问id
  441. markAdvisor: '', //标记顾问
  442. validInvalid: '', // 录音标识
  443. visitRecord: [], // 到访次数
  444. wajueVal: [], // 需求挖掘
  445. wajueVals: [], // 需求挖掘
  446. xiaojiangVal: [], //销讲执行率
  447. jiedaiVal: [], // 接待时长
  448. marketingBusiness: [], // 选中销讲业务id
  449. },
  450. freeList: [], //顾问
  451. recordList: [],
  452. buildingID: '',
  453. nextPage: 1,
  454. totalRecord: "",
  455. staTime: '',
  456. endtime: '',
  457. isnorefresh: '',
  458. activeTotal2: 0,
  459. timeshow: false,
  460. timetushow: false,
  461. soltishow: false,
  462. methodsisshow: false,
  463. userInfo: {},
  464. counselorName: '接待顾问', //接待顾问
  465. arriveFilter: '接待时间', // 接待时间
  466. sortText: '排序',
  467. visitList: [{
  468. label: '首次到访',
  469. value: 1,
  470. isShow: false,
  471. }, {
  472. label: '2次到访',
  473. value: 2,
  474. isShow: false,
  475. }, {
  476. label: '3次到访',
  477. value: 3,
  478. isShow: false,
  479. }, {
  480. label: '3次以上',
  481. value: 4,
  482. isShow: false,
  483. }, ],
  484. isRefresh: false,
  485. chooseMore: false,
  486. }
  487. },
  488. onLoad(options) {
  489. this.LOADING = true
  490. this.isnorefresh = options.refresh;
  491. this.activeTotal = options.activeTotal
  492. this.screen.markAdvisor = options.markAdvisor
  493. this.screen.validInvalid = options.validInvalid
  494. if (options.staTime) {
  495. this.staTime = options.staTime;
  496. this.endtime = options.endtime + ' 23:59:59';
  497. }
  498. },
  499. onShow() {
  500. try {
  501. this.$store.commit('stopAduio')
  502. } catch (e) {
  503. console.log(e)
  504. }
  505. this.userInfo = uni.getStorageSync('weapp_session_userInfo_data');
  506. if (this.userInfo.dataCode == 6 || this.userInfo.dataCode == 3) {
  507. this.methodsisshow = false;
  508. } else {
  509. this.methodsisshow = true;
  510. }
  511. if (this.isnorefresh == 'refresh') {
  512. this.buildingID = uni.getStorageSync('buildingID').id;
  513. this.recordList = [];
  514. this.nextPage = 1;
  515. this.isRefresh = false;
  516. this.getMyCustom()
  517. this.getFreeList();
  518. // this.getMarketingBusiness()
  519. this.isnorefresh = '';
  520. }
  521. },
  522. onPullDownRefresh() {
  523. this.isRefresh = true;
  524. this.nextPage = 1;
  525. this.getMyCustom()
  526. setTimeout(function() {
  527. uni.stopPullDownRefresh();
  528. }, 1000);
  529. },
  530. onReachBottom() {
  531. if (this.totalRecord == this.nextPage) {
  532. uni.showToast({
  533. icon: 'none',
  534. title: '到底了',
  535. duration: 2000
  536. });
  537. return
  538. } else {
  539. this.nextPage += 1;
  540. this.isRefresh = false;
  541. this.getMyCustom();
  542. }
  543. },
  544. methods: {
  545. // 获取销讲业务
  546. getMarketingBusiness() {
  547. this.$u.get('/customer/marketingBusiness', {
  548. houseId: this.buildingID,
  549. }).then(res => {
  550. this.templateList = res.map(item => {
  551. return {
  552. ...item,
  553. isShow: false,
  554. }
  555. })
  556. })
  557. },
  558. taptimetuisshow() {
  559. this.timetushow = true;
  560. },
  561. //选择标签
  562. selectCallback2(e) {
  563. this.sortText = e[0].label
  564. this.screen.orderBy = e[0].value;
  565. this.nextPage = 1;
  566. this.recordList = [];
  567. this.isRefresh = false;
  568. this.getMyCustom();
  569. },
  570. //时间选择
  571. tabtimetap(index, text) {
  572. this.timeshow = false;
  573. if (text) {
  574. this.arriveFilter = text
  575. }
  576. if (index == 4) {
  577. this.totalTimeShow = true;
  578. } else {
  579. this.activeTotal = index;
  580. this.staTime = '';
  581. this.endtime = '';
  582. this.nextPage = 1;
  583. this.recordList = [];
  584. this.isRefresh = false;
  585. this.getMyCustom();
  586. }
  587. },
  588. //自定义时间
  589. totalTimeChange(e) {
  590. this.staTime = e.startDate;
  591. this.endtime = e.endDate;
  592. this.activeTotal = 4;
  593. this.nextPage = 1;
  594. this.recordList = [];
  595. this.isRefresh = false;
  596. this.getMyCustom();
  597. },
  598. tapThevisiting(item) {
  599. let newmenulist = uni.getStorageSync('weapp_session_Menu_data');
  600. if (newmenulist.jdjl_ck != true) {
  601. return
  602. }
  603. this.wordFinishFraction = item.wordFinishFraction
  604. this.wordFraction = item.wordFraction
  605. uni.showLoading({
  606. title: '加载中',
  607. mask: true
  608. });
  609. if (item.status == 0) {
  610. setTimeout(function() {
  611. uni.hideLoading();
  612. }, 2000);
  613. uni.showToast({
  614. icon: "none",
  615. title: "排队中"
  616. })
  617. return
  618. } else {
  619. const parames = {
  620. pageNum: 1,
  621. pageSize: 100,
  622. query: {
  623. customerId: item.id,
  624. }
  625. }
  626. var item = {
  627. bg: 0,
  628. customerId: item.id,
  629. }
  630. uni.setStorageSync("searchobj", item); //写入缓存
  631. uni.setStorageSync("entrance", 1); //写入缓存
  632. this.$u.post("/corpus/findByPage", parames).then(res => {
  633. if (res == null) {
  634. setTimeout(function() {
  635. uni.hideLoading();
  636. }, 2000);
  637. uni.showToast({
  638. icon: "none",
  639. title: "暂无音频"
  640. })
  641. return
  642. } else {
  643. setTimeout(function() {
  644. uni.hideLoading();
  645. }, 2000);
  646. let newobj = res[0];
  647. if (res[0].merge == 0) {
  648. uni.navigateTo({
  649. url: `/pages/mine/details2?customerId=${newobj.customerId}&status=${newobj.status}&stateisshow=2&wordFraction=${this.wordFraction}&wordFinishFraction=${this.wordFinishFraction}`
  650. })
  651. } else {
  652. uni.navigateTo({
  653. url: `/pages/mine/details?customerId=${newobj.customerId}&status=${newobj.status}&stateisshow=1`
  654. })
  655. }
  656. }
  657. })
  658. }
  659. },
  660. getMyCustom() {
  661. let dateType = 0;
  662. let recDurationInterval = 0;
  663. if (this.activeTotal == 5) {
  664. dateType = null;
  665. } else if (this.activeTotal == 4) {
  666. dateType = null;
  667. } else {
  668. dateType = this.activeTotal;
  669. }
  670. if (this.activeTotal2 == 0) {
  671. recDurationInterval = null
  672. } else {
  673. recDurationInterval = this.activeTotal2
  674. }
  675. this.screen.jiedaiVal = []
  676. this.screen.wajueVal = []
  677. this.screen.wajueVals = []
  678. this.screen.xiaojiangVal = []
  679. this.screen.visitRecord = []
  680. this.screen.marketingBusiness = []
  681. // 到访次数
  682. this.visitList.forEach(i => {
  683. if (i.isShow) this.screen.visitRecord.push(i.value)
  684. })
  685. // 接待时长
  686. this.jiedaiList.forEach(i => {
  687. if (i.isShow) this.screen.jiedaiVal.push(i.value)
  688. })
  689. // 需求挖掘
  690. this.wajueList.forEach(i => {
  691. if (i.isShow) this.screen.wajueVal.push(i.value)
  692. })
  693. // 需求挖掘成功
  694. this.wajueLists.forEach(i => {
  695. if (i.isShow) this.screen.wajueVals.push(i.value)
  696. })
  697. // 销讲执行率
  698. this.xiaojiangList.forEach(i => {
  699. if (i.isShow) this.screen.xiaojiangVal.push(i.value)
  700. })
  701. // 销讲业务
  702. this.templateList.forEach(i => {
  703. if (i.isShow) this.screen.marketingBusiness.push(i.value)
  704. })
  705. var parames = {
  706. pageNum: this.nextPage,
  707. pageSize: 10,
  708. query: {
  709. projectId: this.buildingID,
  710. time: 1,
  711. staDate: this.staTime,
  712. endDate: this.endtime,
  713. markAdvisor: this.screen.markAdvisor,
  714. dateType: dateType,
  715. recDurationInterval: recDurationInterval,
  716. orderBy: this.screen.orderBy == '' ? '' : this.screen.orderBy, //排序,
  717. validInvalid: this.screen.validInvalid == 2 ? null : this.screen.validInvalid, //录音标识
  718. recording: this.screen.validInvalid == 2 ? 0 : null,
  719. visitRecords: this.screen.visitRecord.length ? this.screen.visitRecord.join(",") : '', //到访次数
  720. wordFractions: this.screen.wajueVal.length ? this.screen.wajueVal.join(',') : '', //需求挖掘
  721. wordFinishFractions: this.screen.wajueVals.length ? this.screen.wajueVals.join(',') : '', //需求挖掘
  722. duractionNums: this.screen.jiedaiVal.length ? this.screen.jiedaiVal.join(',') : '', //接待时长
  723. fractions: this.screen.xiaojiangVal.length ? this.screen.xiaojiangVal.join(',') : '', //销讲执行
  724. marketingBusiness: this.screen.marketingBusiness.length ? this.screen.marketingBusiness.join(
  725. ',') : '', //销讲执行
  726. }
  727. };
  728. if (this.screen.agentId) {
  729. parames.query.agentId = this.screen.agentId
  730. }
  731. this.$u.post("/customer/findbypage", parames).then(data => {
  732. this.LOADING = false
  733. // console.log(data)
  734. let list = data.records || [];
  735. if (this.isRefresh) {
  736. this.recordList = list;
  737. } else {
  738. this.recordList = [].concat(this.recordList, list)
  739. }
  740. this.totalRecord = data.pages;
  741. this.totalRecords = data.total;
  742. if (this.staTime && this.endtime) {
  743. this.arriveFilter = `${this.staTime}-${this.endtime}`
  744. }
  745. }).catch(e => {
  746. this.LOADING = false
  747. })
  748. },
  749. //获取顾问列表
  750. getFreeList() {
  751. this.$u.post("/cusLvStatistics/selectAllAccountIdByHouseId", {
  752. houseId: this.buildingID
  753. }).then(res => {
  754. this.freeList = res;
  755. this.freeList.forEach(item => {
  756. item.label = item.name;
  757. item.value = item.accountId
  758. })
  759. this.freeList.unshift({
  760. label: '全部',
  761. value: ''
  762. })
  763. })
  764. },
  765. //select接待顾问
  766. actionSelectCallback(e) {
  767. if (e[0].label == '全部') {
  768. this.counselorName = '接待顾问'
  769. this.screen.agentId = ''
  770. } else {
  771. this.screen.agentId = e[0].value;
  772. this.counselorName = e[0].label
  773. }
  774. this.recordList = [];
  775. this.nextPage = 1;
  776. this.isRefresh = false;
  777. this.getMyCustom();
  778. },
  779. reset() {
  780. this.screen.agentId = ''
  781. this.screen.validInvalid = ''
  782. this.screen.markAdvisor = ''
  783. this.screen.orderBy = '';
  784. this.screen.jiedaiVal = []
  785. this.screen.wajueVal = []
  786. this.screen.wajueVals = []
  787. this.screen.xiaojiangVal = []
  788. this.screen.visitRecord = []
  789. this.screen.marketingBusiness = []
  790. this.sortText = '排序';
  791. this.arriveFilter = '接待时间';
  792. this.staTime = '';
  793. this.endTime = '';
  794. this.nextPage = 1;
  795. this.activeTotal = 5;
  796. this.recordList = [];
  797. this.counselorName = '接待顾问';
  798. this.visitList.forEach(i => {
  799. i.isShow = false
  800. })
  801. this.jiedaiList.forEach(i => {
  802. i.isShow = false
  803. })
  804. this.wajueList.forEach(i => {
  805. i.isShow = false
  806. })
  807. this.xiaojiangList.forEach(i => {
  808. i.isShow = false
  809. })
  810. this.templateList.forEach(i => {
  811. i.isShow = false
  812. })
  813. this.isRefresh = false;
  814. this.getMyCustom();
  815. },
  816. chooseMores() {
  817. let change1 = this.templateList.some(item => item.isShow == true)
  818. let change2 = this.xiaojiangList.some(item => item.isShow == true)
  819. let change3 = this.wajueList.some(item => item.isShow == true)
  820. let change8 = this.wajueLists.some(item => item.isShow == true)
  821. let change4 = this.jiedaiList.some(item => item.isShow == true)
  822. let change5 = this.screen.validInvalid != null && this.screen.validInvalid != ''
  823. let change6 = this.screen.markAdvisor != null && this.screen.markAdvisor != ''
  824. let change7 = this.visitList.some(item => item.isShow == true)
  825. console.log(change1, change2, change3, change4, change5, change6, change7)
  826. if (change1 || change2 || change3 || change4 || change5 || change6 || change7 || change8) {
  827. return true
  828. } else {
  829. return false
  830. }
  831. },
  832. choice(item) {
  833. item.isShow = !item.isShow;
  834. },
  835. // 标记顾问
  836. screenvisitRecord(i) {
  837. if (this.screen.markAdvisor === i) {
  838. this.screen.markAdvisor = ''
  839. } else {
  840. this.screen.markAdvisor = i
  841. }
  842. },
  843. // 录音标识
  844. screenvisivalidInvalid(i) {
  845. if (this.screen.validInvalid == i) {
  846. this.screen.validInvalid = null
  847. } else {
  848. this.screen.validInvalid = i
  849. }
  850. },
  851. screensure() {
  852. this.chooseMore = this.chooseMores()
  853. this.screenShow = false;
  854. this.recordList = [];
  855. this.nextPage = 1;
  856. this.isRefresh = false;
  857. this.getMyCustom();
  858. },
  859. goSearch() {
  860. uni.navigateTo({
  861. url: '/pages/center/records/recordSearch'
  862. });
  863. },
  864. },
  865. filters: {
  866. // 加密手机号
  867. encryption(phone) {
  868. if (!phone) return
  869. return phone.replace(/(\d{3})\d{4}(\d{4})/, '$1****$2')
  870. }
  871. }
  872. }
  873. </script>
  874. <style lang="scss" scoped>
  875. .box {
  876. width: 100%;
  877. height: 100%;
  878. background: #F8F8F8;
  879. }
  880. .timeview {
  881. height: 90rpx;
  882. line-height: 90rpx;
  883. width: 100%;
  884. text-align: center;
  885. border-bottom: 1rpx solid #F8F8F8;
  886. }
  887. //时间切换的样式
  888. .boxtittab {
  889. position: sticky;
  890. top: var(--window-top);
  891. z-index: 999;
  892. width: 100;
  893. height: 92rpx;
  894. background: #FFFFFF;
  895. display: flex;
  896. align-items: center;
  897. .tabbox {
  898. flex-shrink: 0;
  899. flex-grow: 1;
  900. height: 100%;
  901. text-align: center;
  902. line-height: 92rpx;
  903. color: #666666;
  904. font-size: 28rpx;
  905. overflow: hidden;
  906. text-overflow: ellipsis;
  907. display: -webkit-box;
  908. /* 将对象作为弹性伸缩盒子模型显示 */
  909. -webkit-line-clamp: 1;
  910. /* 控制最多显示几行 */
  911. -webkit-box-orient: vertical;
  912. /* 设置或检索伸缩盒对象的子元素的排列方式 */
  913. }
  914. .activeColor {
  915. font-weight: bold;
  916. color: #2671E2;
  917. }
  918. }
  919. .search-box {
  920. width: 100%;
  921. height: 102rpx;
  922. background: #FFFFFF;
  923. display: flex;
  924. align-items: center;
  925. justify-content: center;
  926. .search {
  927. width: 94%;
  928. height: 70rpx;
  929. display: flex;
  930. align-items: center;
  931. background: #F8F8F8;
  932. border-radius: 33rpx;
  933. .search-img {
  934. width: 26rpx;
  935. height: 30rpx;
  936. margin-left: 20rpx;
  937. .search-img1 {
  938. width: 100%;
  939. height: 100%;
  940. margin-top: 2rpx;
  941. }
  942. }
  943. .search-text {
  944. font-size: 28rpx;
  945. font-weight: 400;
  946. color: #999999;
  947. margin-left: 10rpx;
  948. }
  949. }
  950. .search-screen {
  951. width: 40rpx;
  952. height: 40rpx;
  953. margin-left: 30rpx;
  954. .search-screen1 {
  955. width: 100%;
  956. height: 100%;
  957. }
  958. }
  959. }
  960. .count {
  961. width: 100%;
  962. height: 82rpx;
  963. line-height: 82rpx;
  964. display: flex;
  965. align-items: center;
  966. justify-content: center;
  967. background-color: #f8f8f8;
  968. font-size: 30rpx;
  969. font-family: PingFangSC-Regular, PingFang SC;
  970. font-weight: 400;
  971. color: #333333;
  972. text {
  973. color: #E7483C;
  974. }
  975. }
  976. .content {
  977. .content-tips {
  978. background: #fff;
  979. box-sizing: border-box;
  980. overflow: hidden;
  981. margin-bottom: 20rpx;
  982. &:last-child {
  983. margin-bottom: 0
  984. }
  985. .content-first {
  986. padding: 0 30rpx;
  987. height: 92rpx;
  988. border-bottom: 1rpx solid #D8D8D8;
  989. display: flex;
  990. align-items: center;
  991. justify-content: space-between;
  992. .left {
  993. flex-shrink: 0;
  994. min-width: 40%;
  995. display: flex;
  996. align-items: center;
  997. overflow: hidden;
  998. .adviser {
  999. margin-right: 10rpx;
  1000. padding: 5rpx 11rpx;
  1001. border-radius: 50%;
  1002. border: 1rpx solid #2671E2;
  1003. font-size: 30rpx;
  1004. color: #2671E2;
  1005. }
  1006. .img {
  1007. width: 52rpx;
  1008. height: 52rpx;
  1009. background: #FFFFFF;
  1010. border: 1px solid #C9C9C9;
  1011. border-radius: 50%;
  1012. text-align: center;
  1013. }
  1014. .name {
  1015. color: #333333;
  1016. font-size: 32rpx;
  1017. font-weight: bold;
  1018. }
  1019. .status {
  1020. margin-left: 19rpx;
  1021. width: 110rpx;
  1022. background: #FFF9F5;
  1023. border-radius: 4rpx;
  1024. font-size: 26rpx;
  1025. font-weight: 400;
  1026. color: #EC8D49;
  1027. text-align: center;
  1028. }
  1029. }
  1030. .right {
  1031. flex: 1;
  1032. display: flex;
  1033. font-size: 30rpx;
  1034. justify-content: flex-end;
  1035. view,
  1036. text {
  1037. flex-shrink: 0;
  1038. }
  1039. .point {
  1040. flex-shrink: 0;
  1041. width: 12rpx;
  1042. height: 12rpx;
  1043. background: #2B6EFF;
  1044. border-radius: 50%;
  1045. margin-right: 9rpx;
  1046. margin-top: 16rpx;
  1047. }
  1048. }
  1049. }
  1050. .content-sec {
  1051. padding: 28rpx 30rpx 32rpx;
  1052. display: flex;
  1053. justify-content: space-between;
  1054. .left {
  1055. display: flex;
  1056. align-items: center;
  1057. .adviser {
  1058. margin-right: 10rpx;
  1059. padding: 5rpx 11rpx;
  1060. border-radius: 50%;
  1061. border: 1rpx solid #2671E2;
  1062. background: #2671E2;
  1063. font-size: 30rpx;
  1064. color: #fff;
  1065. }
  1066. .cus {
  1067. font-size: 30rpx;
  1068. font-weight: 400;
  1069. color: #333;
  1070. overflow: hidden;
  1071. text-overflow: ellipsis;
  1072. display: -webkit-box;
  1073. line-height: 23px;
  1074. max-height: 46px;
  1075. -webkit-line-clamp: 1;
  1076. -webkit-box-orient: vertical;
  1077. }
  1078. .arriveNum {
  1079. font-size: 30rpx;
  1080. font-weight: 400;
  1081. margin-left: 10rpx;
  1082. }
  1083. }
  1084. .right {
  1085. font-size: 28rpx;
  1086. font-weight: 400;
  1087. display: flex;
  1088. align-items: center;
  1089. }
  1090. }
  1091. .content-newadd {
  1092. padding: 0 30rpx 34rpx;
  1093. display: flex;
  1094. align-items: center;
  1095. justify-content: space-between;
  1096. font-size: 30rpx;
  1097. color: #333;
  1098. }
  1099. .content-last {
  1100. padding: 0 30rpx 34rpx;
  1101. font-size: 30rpx;
  1102. font-weight: 400;
  1103. color: #666666;
  1104. display: flex;
  1105. align-items: center;
  1106. justify-content: space-between;
  1107. .c-items {
  1108. flex-shrink: 0;
  1109. display: flex;
  1110. align-items: center;
  1111. font-size: 28rpx;
  1112. .c-items-img {
  1113. margin-right: 10rpx;
  1114. width: 32rpx;
  1115. height: 32rpx;
  1116. }
  1117. }
  1118. }
  1119. }
  1120. }
  1121. // 这是弹出层
  1122. .screen {
  1123. width: 750rpx;
  1124. .screen-counselor {
  1125. display: flex;
  1126. height: 106rpx;
  1127. padding: 0 30rpx;
  1128. box-sizing: border-box;
  1129. border-bottom: 1px solid #EEEEEE;
  1130. .screen-text {
  1131. margin: 40rpx 0 36rpx 0;
  1132. font-size: 30rpx;
  1133. font-weight: 400;
  1134. color: #333333;
  1135. line-height: 30rpx;
  1136. }
  1137. .screen-sel {
  1138. display: flex;
  1139. justify-content: space-between;
  1140. width: 500rpx;
  1141. margin-left: 60rpx;
  1142. .screen-sel-img {
  1143. margin: 40rpx 0 36rpx 0;
  1144. width: 14rpx;
  1145. height: 30rpx;
  1146. }
  1147. .screen-inp {
  1148. margin-top: 20rpx;
  1149. }
  1150. }
  1151. }
  1152. .screen-record {
  1153. overflow: hidden;
  1154. padding: 0 30rpx;
  1155. box-sizing: border-box;
  1156. border-bottom: 1px solid #e0e0e0;
  1157. .screen-record-text {
  1158. padding: 30rpx 0;
  1159. font-size: 30rpx;
  1160. font-weight: 600;
  1161. color: #333333;
  1162. line-height: 30rpx;
  1163. display: flex;
  1164. align-items: center;
  1165. justify-content: space-between;
  1166. .arrow {
  1167. width: 30rpx;
  1168. height: 14rpx;
  1169. }
  1170. }
  1171. .screen-record-tab {
  1172. margin-top: 30rpx;
  1173. padding-bottom: 10rpx;
  1174. display: flex;
  1175. flex-wrap: wrap;
  1176. .screen-record-item {
  1177. min-width: 150rpx;
  1178. padding: 0 14rpx;
  1179. height: 60rpx;
  1180. border-radius: 8rpx;
  1181. text-align: center;
  1182. line-height: 60rpx;
  1183. margin: 0 22rpx 22rpx 0;
  1184. &:nth-child(4n) {
  1185. margin-right: 0;
  1186. }
  1187. }
  1188. .screen-record-chose {
  1189. background: #F1F6FD;
  1190. color: #2671E2;
  1191. }
  1192. .screen-record-nochose {
  1193. background: #F7F8FA;
  1194. color: #333;
  1195. }
  1196. }
  1197. }
  1198. .screen-foot {
  1199. width: 100%;
  1200. height: 78rpx;
  1201. display: flex;
  1202. margin: 30rpx 30rpx 0;
  1203. .screen-foot-reset {
  1204. width: 176rpx;
  1205. height: 78rpx;
  1206. line-height: 78rpx;
  1207. background: #FFFFFF;
  1208. border-radius: 8rpx;
  1209. border: 1px solid #2671E2;
  1210. margin-right: 30rpx;
  1211. font-size: 30rpx;
  1212. font-family: PingFangSC-Regular, PingFang SC;
  1213. font-weight: 400;
  1214. color: #2671E2;
  1215. text-align: center;
  1216. }
  1217. .screen-foot-sure {
  1218. width: 484rpx;
  1219. height: 78rpx;
  1220. line-height: 78rpx;
  1221. background: #2671E2;
  1222. border: 1px solid #2671E2;
  1223. border-radius: 8rpx;
  1224. font-size: 30rpx;
  1225. font-family: PingFangSC-Regular, PingFang SC;
  1226. font-weight: 400;
  1227. color: #FFFFFF;
  1228. text-align: center;
  1229. }
  1230. }
  1231. }
  1232. </style>