|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195 |
- <template>
- <view class="box">
- <view style="width: 690rpx;margin: 0 auto;margin-top: 20rpx;">
- <u-search @search='searchinfo()' placeholder="请输入" v-model="keyword"></u-search>
- </view>
- <!-- <view @click="searchinfo()">搜索</view> -->
- <view class="content">
-
- <view class="content-tips" v-for="(item,index) in recordList" :key='index'>
- <view class="content-first">
- <view class="left">
- <view class="img">{{item.agentName.slice(0,1)}}</view>
- <view class="name">{{item.agentName}}</view>
- <view class="status">代接待</view>
- </view>
- <!-- <view class="right">
- <view class="point"></view>
- <view class="">优秀案例</view>
- </view> -->
- </view>
- <view class="content-sec">
- <view class="left">
- <view class="cus">客户:{{item.name || '--'}} |</view>
- <view class="arriveNum">{{item.visitRecord || "0"}}次到访</view>
- </view>
- <view class="right">
- {{item.fraction || '0'}}% | {{item.fraction || '0'}}分
- </view>
- </view>
- <view class="content-last">
- {{item.createTime}} | {{item.mm || '0'}}分钟
- </view>
- </view>
- </view>
- </view>
- </template>
-
- <script>
- export default{
- data(){
- return{
- keyword:'',
- recordList:[],
- buildingID:'',
- nextPage:1,
- totalRecord:"",
- }
- },
- onShow() {
- this.buildingID = uni.getStorageSync('buildingID').id;
- },
- onReachBottom() {
- if(this.totalRecord==this.nextPage){
- uni.showToast({
- icon:'none',
- title: '到底了',
- duration: 2000
- });
- return
- }else{
- this.nextPage+=1;
- this.getMyCustom();
- }
- },
- methods:{
- searchinfo(){
- this.nextPage=1;
- this.recordList=[];
- this.getMyCustom();
- },
- getMyCustom(){
- var parames = {
- pageNum: this.nextPage,
- pageSize: 10,
- query: {
- projectId:this.buildingID,
- time:1,
- nameOrPhone:this.keyword
- }
- };
- this.$u.post("/customer/findbypage", parames).then(data => {
- var list = data.results || [];
- this.recordList = [...this.recordList, ...list];
- this.totalRecord=data.totalPage;
- })
- },
- }
- }
- </script>
-
- <style lang="scss" scoped>
- .box {
- width: 100%;
- height: 100vh;
- background: #F8F8F8;
- }
- .content{
- .content-tips{
- background: #fff;
- padding: 0 20rpx;
- box-sizing: border-box;
- overflow: hidden;
- margin-top: 20rpx;
- .content-first{
- margin-top: 19rpx;
- display: flex;
- justify-content: space-between;
- .left{
- display: flex;
- .img{
- width: 52rpx;
- height: 52rpx;
- background: #FFFFFF;
- border: 1px solid #C9C9C9;
- border-radius: 50%;
- text-align: center;
- line-height: 52rpx;
- }
- .name{
- font-weight: 600;
- color: #333333;
- margin-left: 20rpx;
- margin-top: 11rpx;
- }
- .status{
- width: 110rpx;
- height: 42rpx;
- background: #FFF9F5;
- border-radius: 4rpx;
- font-size: 26rpx;
- font-weight: 400;
- color: #EC8D49;
- line-height: 42rpx;
- text-align: center;
- margin-left: 19rpx;
- margin-top: 11rpx;
- }
- }
- .right{
- display: flex;
- margin-top: 11rpx;
- .point{
- width: 12rpx;
- height: 12rpx;
- background: #2B6EFF;
- border-radius: 50%;
- margin-right: 9rpx;
- margin-top: 16rpx;
-
- }
- }
- }
-
-
- .content-sec{
- display: flex;
- justify-content: space-between;
- margin-top: 19rpx;
- .left{
- display: flex;
- .cus{
- font-size: 30rpx;
- font-weight: 400;
- color: #666666;
- line-height: 30rpx;
- }
- .arriveNum{
- font-size: 30rpx;
- font-weight: 400;
- line-height: 30rpx;
- margin-left: 10rpx;
- }
- }
- .right{
- width: 192rpx;
- height: 46rpx;
- background: #F4F8FD;
- border-radius: 6rpx;
- text-align: center;
- line-height: 46rpx;
- font-weight: 400;
- color: #2671E2;
- }
- }
- .content-last{
- margin: 30rpx 0;
- font-size: 30rpx;
- font-weight: 400;
- color: #666666;
- line-height: 30rpx;
- }
-
- }
- }
- </style>
|