You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.vue 14 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601
  1. <template>
  2. <view class="box">
  3. <!-- 搜索框点击跳转 -->
  4. <view>
  5. <view class="search-box">
  6. <view class="search" @click="goSearch">
  7. <view class="search-img">
  8. <image class="search-img1" src="../../../static/images/search.png" mode=""></image>
  9. </view>
  10. <view class="search-text">输入客户姓名/手机号</view>
  11. </view>
  12. <view class="search-screen" @click="screenshow">
  13. <image class="search-screen1" src="../../../static/images/screen.png" mode=""></image>
  14. </view>
  15. </view>
  16. </view>
  17. <!-- 选择器 -->
  18. <view class="boxtittab">
  19. <view class="tabbox">
  20. <view :class="{ activecllasscet: activeTotal == 0 }" @click="tabtimetap(0)">今日</view>
  21. </view>
  22. <view class="tabbox">
  23. <view :class="{ activecllasscet: activeTotal == 1 }" @click="tabtimetap(1)">昨日</view>
  24. </view>
  25. <view class="tabbox">
  26. <view :class="{ activecllasscet: activeTotal == 2 }" @click="tabtimetap(2)">近一周</view>
  27. </view>
  28. <view class="tabbox">
  29. <view :class="{ activecllasscet: activeTotal == 3 }" @click="tabtimetap(3)">自定义</view>
  30. </view>
  31. </view>
  32. <view class="content">
  33. <view v-if="recordList.length==0" style="width: 100%;height: 100%;display: flex;align-items: center;background: #FFFFFF;">
  34. <view style="width: 100%;padding-top: 200rpx;">
  35. <view style="width: 100%;text-align: center;">
  36. <image style="width: 220rpx;height: 200rpx;" src="https://static.quhouse.com/zhikong_xcx_img/nodatalist.png" mode=""></image>
  37. </view>
  38. <view style="text-align: center;width: 100%;margin-top: 20rpx;color: #999999;">暂无数据</view>
  39. </view>
  40. </view>
  41. <view v-if="recordList.length!=0" class="content-tips" v-for="(item,index) in recordList" :key='index' @click="tapThevisiting(item)">
  42. <view class="content-first">
  43. <view class="left">
  44. <!-- <view class="img">{{item.agentName.slice(0,1)}}</view> -->
  45. <view class="name">{{item.agentName}}</view>
  46. <view class="status" v-if="item.replaceReception==1">代接待</view>
  47. </view>
  48. <view class="right">
  49. <!-- <view class="point"></view> -->
  50. <view v-if="item.markAdvisor==0" class="">未标记</view>
  51. <view v-if="item.markAdvisor==1" class="">已标记</view>
  52. </view>
  53. </view>
  54. <view class="content-sec">
  55. <view class="left">
  56. <view class="cus">客户:{{item.name || '--'}} |</view>
  57. <view class="arriveNum">{{item.visitRecord || "--"}}次到访</view>
  58. </view>
  59. <view class="right">
  60. <!-- {{item.fraction || '0'}}% | {{item.fraction || '0'}}分 -->
  61. {{item.fraction || '0'}}%
  62. </view>
  63. </view>
  64. <view class="content-last">
  65. {{item.createTime}} | {{item.mm || '0'}} min
  66. </view>
  67. </view>
  68. </view>
  69. <u-popup v-model="screenShow" mode="top" height="590">
  70. <view class="screen">
  71. <!-- 顾问选择 -->
  72. <view class="screen-counselor">
  73. <view class="screen-text">
  74. 所属顾问
  75. </view>
  76. <view class="screen-sel">
  77. <u-input v-model="screen.counselorName" type="text" placeholder='请选择' @click="selectshow = true" class="screen-inp" disabled />
  78. <image class="screen-sel-img" src="../../../static/images/right.png" mode=""></image>
  79. </view>
  80. </view>
  81. <!-- 录音标示 -->
  82. <!-- <view class="screen-record">
  83. <view class="screen-record-text">录音标识</view>
  84. <view class="screen-record-tab">
  85. <view :class="[screen.record==0?'screen-record-chose':'screen-record-nochose']" @click="screen.record=0">
  86. 有效录音
  87. </view>
  88. <view :class="[screen.record==1?'screen-record-chose':'screen-record-nochose']" @click="screen.record=1">
  89. 无效录音
  90. </view>
  91. </view>
  92. </view> -->
  93. <view class="screen-record">
  94. <view class="screen-record-text">
  95. 标记顾问
  96. </view>
  97. <view class="screen-record-tab">
  98. <view :class="[screen.markAdvisor==1?'screen-record-chose':'screen-record-nochose']" @click="screenvisitRecord(1)">
  99. 标记
  100. </view>
  101. <view :class="[screen.markAdvisor==0?'screen-record-chose':'screen-record-nochose']" @click="screenvisitRecord(0)">
  102. 未标记
  103. </view>
  104. </view>
  105. </view>
  106. <view class="screen-record">
  107. <view class="screen-record-text">
  108. 到访次数
  109. </view>
  110. <view class="screen-record-tab">
  111. <view :class="[screen.visitRecord==1?'screen-record-chose':'screen-record-nochose']" @click="recordclick(1)">
  112. 首次到访
  113. </view>
  114. <view :class="[screen.visitRecord==2?'screen-record-chose':'screen-record-nochose']" @click="recordclick(2)">
  115. 第二次
  116. </view>
  117. <view :class="[screen.visitRecord==3?'screen-record-chose':'screen-record-nochose']" @click="recordclick(3)">
  118. 第三次
  119. </view>
  120. <view :class="[screen.visitRecord==4?'screen-record-chose':'screen-record-nochose']" @click="recordclick(4)">
  121. 三次以上
  122. </view>
  123. </view>
  124. </view>
  125. <view class="screen-foot">
  126. <view class="screen-foot-reset" @click="reset">
  127. 重置
  128. </view>
  129. <view class="screen-foot-sure" @click="screensure">
  130. 确定
  131. </view>
  132. </view>
  133. </view>
  134. </u-popup>
  135. <!-- 选择顾问的选择框 -->
  136. <u-select v-model="selectshow" :list="freeList" @confirm="actionSelectCallback"></u-select>
  137. <u-calendar v-model="totalTimeShow" mode="range" @change="totalTimeChange"></u-calendar>
  138. </view>
  139. </template>
  140. <script>
  141. export default{
  142. data(){
  143. return{
  144. activeTotal: 2,
  145. value:'',
  146. screenShow:false,
  147. selectshow:false,
  148. totalTimeShow: false,
  149. screen:{
  150. agentId:'',//顾问id
  151. record:'0',
  152. markAdvisor:null,
  153. visitRecord:null
  154. },
  155. freeList:[],//顾问
  156. recordList:[],
  157. buildingID:'',
  158. nextPage:1,
  159. totalRecord:"",
  160. staTime:'',
  161. endtime:''
  162. }
  163. },
  164. onShow() {
  165. this.buildingID = uni.getStorageSync('buildingID').id;
  166. this.recordList=[];
  167. this.nextPage=1;
  168. this.getMyCustom()
  169. this.getFreeList();
  170. },
  171. onReachBottom() {
  172. if(this.totalRecord==this.nextPage){
  173. uni.showToast({
  174. icon:'none',
  175. title: '到底了',
  176. duration: 2000
  177. });
  178. return
  179. }else{
  180. this.nextPage+=1;
  181. this.getMyCustom();
  182. }
  183. },
  184. methods:{
  185. tapThevisiting(item) {
  186. if(item.status==0){
  187. uni.showToast({
  188. icon: "none",
  189. title: "排队中"
  190. })
  191. return
  192. }else{
  193. const parames = {
  194. pageNum: 1,
  195. pageSize: 100,
  196. query: {
  197. customerId: item.id,
  198. }
  199. }
  200. var item={
  201. bg:0,
  202. customerId:item.id,
  203. }
  204. this.$u.post("/corpus/findByPage", parames).then(res => {
  205. if(res==null){
  206. uni.showToast({
  207. icon: "none",
  208. title: "暂无音频"
  209. })
  210. return
  211. }else{
  212. let newobj = res[0];
  213. if(res[0].merge==0){
  214. uni.navigateTo({
  215. url: `/pages/mine/details2?customerId=${newobj.customerId}&status=${newobj.status}&itemobj=${JSON.stringify(item)}&stateisshow=${"2"}`
  216. })
  217. }else{
  218. uni.navigateTo({
  219. url: `/pages/mine/details?customerId=${newobj.customerId}&status=${newobj.status}&itemobj=${JSON.stringify(item)}&stateisshow=${"1"}`
  220. })
  221. }
  222. }
  223. })
  224. }
  225. },
  226. getMyCustom(){
  227. let dateType=0;
  228. if(this.activeTotal==3){
  229. dateType=null;
  230. }else{
  231. dateType=this.activeTotal
  232. }
  233. var parames = {
  234. pageNum: this.nextPage,
  235. pageSize: 10,
  236. query: {
  237. projectId:this.buildingID,
  238. time:1,
  239. staTime:this.staTime,
  240. endtime:this.endtime,
  241. visitRecord:this.screen.visitRecord,
  242. markAdvisor:this.screen.markAdvisor,
  243. dateType:dateType
  244. }
  245. };
  246. if(this.screen.agentId){
  247. parames.query.agentId = this.screen.agentId
  248. }
  249. this.$u.post("/customer/findbypage", parames).then(data => {
  250. var list = data.results || [];
  251. this.recordList = [...this.recordList, ...list];
  252. this.totalRecord=data.totalPage;
  253. })
  254. },
  255. //获取顾问列表
  256. getFreeList() {
  257. this.$u.get("/zkAgentPool/freeList?itemId="+this.buildingID).then(res => {
  258. this.freeList = res;
  259. this.freeList.forEach(item=>{
  260. item.label=item.name;
  261. item.value=item.agentId
  262. })
  263. })
  264. },
  265. tabtimetap(index){
  266. if (index == 3) {
  267. this.totalTimeShow = true;
  268. } else {
  269. this.activeTotal = index;
  270. this.staTime='';
  271. this.endtime='';
  272. this.nextPage=1;
  273. this.recordList=[];
  274. this.getMyCustom();
  275. }
  276. },
  277. //自定义时间
  278. totalTimeChange(e) {
  279. this.staTime=e.startDate;
  280. this.endtime=e.endDate;
  281. this.activeTotal=3;
  282. this.nextPage=1;
  283. this.recordList=[];
  284. this.getMyCustom();
  285. },
  286. // 筛选
  287. screenshow(){
  288. this.screenShow=true
  289. },
  290. actionSelectCallback(e){
  291. this.screen.agentId=e[0].value;
  292. this.screenShow=false;
  293. this.recordList=[];
  294. this.nextPage=1;
  295. this.getMyCustom();
  296. },
  297. reset(){
  298. this.screen={
  299. counselorName:'',
  300. record:'0',
  301. markAdvisor:null,
  302. visitRecord:null
  303. }
  304. this.screenShow=false;
  305. this.nextPage=1;
  306. this.recordList=[];
  307. this.getMyCustom();
  308. },
  309. recordclick(i){
  310. if(this.screen.visitRecord==i){
  311. this.screen.visitRecord=null
  312. }else{
  313. this.screen.visitRecord=i
  314. }
  315. },
  316. screenvisitRecord(i){
  317. if(this.screen.markAdvisor==i){
  318. this.screen.markAdvisor=null
  319. }else{
  320. this.screen.markAdvisor=i
  321. }
  322. },
  323. screensure(){
  324. this.screenShow=false;
  325. this.recordList=[];
  326. this.nextPage=1;
  327. this.getMyCustom();
  328. },
  329. goSearch(){
  330. uni.navigateTo({
  331. url: '/pages/center/records/recordSearch'
  332. });
  333. },
  334. },
  335. }
  336. </script>
  337. <style lang="scss" scoped>
  338. .box {
  339. width: 100%;
  340. height: 100%;
  341. background: #F8F8F8;
  342. }
  343. .search-box{
  344. width: 100%;
  345. height: 102rpx;
  346. background: #FFFFFF;
  347. display: flex;
  348. align-items: center;
  349. justify-content: center;
  350. .search{
  351. width: 620rpx;
  352. height: 70rpx;
  353. display: flex;
  354. align-items: center;
  355. background: #F8F8F8;
  356. border-radius: 33rpx;
  357. .search-img{
  358. width: 26rpx;
  359. height: 30rpx;
  360. margin-left: 20rpx;
  361. .search-img1{
  362. width: 100%;
  363. height: 100%;
  364. margin-top: 2rpx;
  365. }
  366. }
  367. .search-text{
  368. font-size: 28rpx;
  369. font-weight: 400;
  370. color: #999999;
  371. margin-left:10rpx;
  372. }
  373. }
  374. .search-screen{
  375. width: 40rpx;
  376. height: 40rpx;
  377. margin-left: 30rpx;
  378. .search-screen1{
  379. width: 100%;
  380. height: 100%;
  381. }
  382. }
  383. }
  384. .content{
  385. .content-tips{
  386. background: #fff;
  387. padding: 0 20rpx;
  388. box-sizing: border-box;
  389. overflow: hidden;
  390. margin-top: 20rpx;
  391. .content-first{
  392. margin-top: 19rpx;
  393. display: flex;
  394. justify-content: space-between;
  395. .left{
  396. display: flex;
  397. .img{
  398. width: 52rpx;
  399. height: 52rpx;
  400. background: #FFFFFF;
  401. border: 1px solid #C9C9C9;
  402. border-radius: 50%;
  403. text-align: center;
  404. line-height: 52rpx;
  405. }
  406. .name{
  407. font-weight: 600;
  408. color: #333333;
  409. // margin-left: 20rpx;
  410. margin-top: 11rpx;
  411. }
  412. .status{
  413. width: 110rpx;
  414. height: 42rpx;
  415. background: #FFF9F5;
  416. border-radius: 4rpx;
  417. font-size: 26rpx;
  418. font-weight: 400;
  419. color: #EC8D49;
  420. line-height: 42rpx;
  421. text-align: center;
  422. margin-left: 19rpx;
  423. margin-top: 11rpx;
  424. }
  425. }
  426. .right{
  427. display: flex;
  428. margin-top: 11rpx;
  429. .point{
  430. width: 12rpx;
  431. height: 12rpx;
  432. background: #2B6EFF;
  433. border-radius: 50%;
  434. margin-right: 9rpx;
  435. margin-top: 16rpx;
  436. }
  437. }
  438. }
  439. .content-sec{
  440. display: flex;
  441. justify-content: space-between;
  442. margin-top: 19rpx;
  443. .left{
  444. display: flex;
  445. .cus{
  446. font-size: 30rpx;
  447. font-weight: 400;
  448. color: #666666;
  449. // line-height: 30rpx;
  450. }
  451. .arriveNum{
  452. font-size: 30rpx;
  453. font-weight: 400;
  454. // line-height: 30rpx;
  455. margin-left: 10rpx;
  456. }
  457. }
  458. .right{
  459. width: 120rpx;
  460. height: 46rpx;
  461. background: #F4F8FD;
  462. border-radius: 6rpx;
  463. text-align: center;
  464. line-height: 46rpx;
  465. font-weight: 400;
  466. color: #2671E2;
  467. }
  468. }
  469. .content-last{
  470. // margin: 30rpx 0;
  471. font-size: 30rpx;
  472. font-weight: 400;
  473. color: #666666;
  474. line-height: 30rpx;
  475. margin-top: 22rpx;
  476. margin-bottom: 30rpx;
  477. }
  478. }
  479. }
  480. // 这是弹出层
  481. .screen{
  482. // box-sizing: border-box;
  483. // padding: 0 30rpx;
  484. position:absolute;
  485. .screen-counselor{
  486. display: flex;
  487. height: 106rpx;
  488. // padding: 40rpx 30rpx 36rpx 30rpx;
  489. padding: 0 30rpx;
  490. box-sizing: border-box;
  491. border-bottom: 1px solid #EEEEEE;
  492. .screen-text{
  493. margin: 40rpx 0 36rpx 0;
  494. font-size: 30rpx;
  495. font-weight: 400;
  496. color: #333333;
  497. line-height: 30rpx;
  498. }
  499. .screen-sel{
  500. display: flex;
  501. justify-content: space-between;
  502. width: 500rpx;
  503. margin-left: 60rpx;
  504. .screen-sel-img{
  505. margin: 40rpx 0 36rpx 0;
  506. width: 14rpx;
  507. height: 30rpx;
  508. }
  509. .screen-inp{
  510. margin-top: 20rpx;
  511. }
  512. }
  513. }
  514. .screen-record{
  515. height: 192rpx;
  516. // width: 100%;
  517. overflow: hidden;
  518. padding: 0 30rpx;
  519. box-sizing: border-box;
  520. border-bottom: 1px solid #EEEEEE;
  521. .screen-record-text{
  522. margin-top: 36rpx;
  523. font-size: 30rpx;
  524. font-weight: 400;
  525. color: #333333;
  526. line-height: 30rpx;
  527. }
  528. .screen-record-tab{
  529. margin-top: 30rpx;
  530. display: flex;
  531. // justify-content: space-around;
  532. .screen-record-chose{
  533. width: 156rpx;
  534. height: 60rpx;
  535. background: #2671E2;
  536. border-radius: 4rpx;
  537. border: 1px solid #2671E2;
  538. text-align: center;
  539. line-height: 60rpx;
  540. margin-right: 22rpx;
  541. color: #FFFFFF;
  542. }
  543. .screen-record-nochose{
  544. width: 156rpx;
  545. height: 60rpx;
  546. background: #FFFFFF;
  547. border-radius: 4rpx;
  548. border: 1px solid #C9C9C9;
  549. text-align: center;
  550. line-height: 60rpx;
  551. margin-right: 22rpx;
  552. }
  553. }
  554. }
  555. .screen-foot{
  556. width: 100%;
  557. height: 100rpx;
  558. display: flex;
  559. .screen-foot-reset{
  560. width: 50%;
  561. text-align: center;
  562. height: 100rpx;
  563. line-height: 100rpx;
  564. font-size: 30rpx;
  565. font-weight: 400;
  566. color: #666666;
  567. }
  568. .screen-foot-sure{
  569. width: 50%;
  570. text-align: center;
  571. line-height: 100rpx;
  572. height: 100rpx;
  573. font-size: 30rpx;
  574. font-weight: 400;
  575. color: #FFFFFF;
  576. background: #2671E2;
  577. }
  578. }
  579. }
  580. </style>