ソースを参照

my report user

胡轶钦 5 年 前
コミット
6df885d706

+ 21
- 0
src/main/java/com/huiju/estateagents/controller/TaRecommendCustomerController.java ファイルの表示

1
 package com.huiju.estateagents.controller;
1
 package com.huiju.estateagents.controller;
2
 
2
 
3
 
3
 
4
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
5
+import com.baomidou.mybatisplus.core.metadata.IPage;
6
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
4
 import com.huiju.estateagents.base.ResponseBean;
7
 import com.huiju.estateagents.base.ResponseBean;
5
 import com.huiju.estateagents.common.CommConstant;
8
 import com.huiju.estateagents.common.CommConstant;
6
 import com.huiju.estateagents.common.JWTUtils;
9
 import com.huiju.estateagents.common.JWTUtils;
126
         }
129
         }
127
     }
130
     }
128
 
131
 
132
+    @GetMapping("/wx/customer/myReport")
133
+    public ResponseBean getCustomerIReport (@RequestParam(value ="personId") String personId,
134
+                                         @RequestParam(value ="pageNumber",defaultValue = "1") Integer pageNumber,
135
+                                         @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize){
136
+        try{
137
+            IPage<TaRecommendCustomer>pg = new Page<>(pageNumber,pageSize);
138
+            QueryWrapper<TaRecommendCustomer>queryWrapper = new QueryWrapper<>();
139
+            queryWrapper.eq("realty_consultant",personId);
140
+            queryWrapper.eq("report_recommend_status",CommConstant.REPORTED);
141
+            queryWrapper.orderByDesc("create_date");
142
+            IPage<TaRecommendCustomer>result = taRecommendCustomerService.page(pg,queryWrapper);
143
+            return ResponseBean.success(result);
144
+        }catch (Exception e){
145
+            e.printStackTrace();
146
+            return ResponseBean.error(e.getMessage(),ResponseBean.ERROR_UNAVAILABLE);
147
+        }
148
+    }
149
+
129
     @GetMapping("/admin/customer/recommend")
150
     @GetMapping("/admin/customer/recommend")
130
     public ResponseBean getCustomerList (@RequestParam(value ="name",required = false) String name,
151
     public ResponseBean getCustomerList (@RequestParam(value ="name",required = false) String name,
131
                                          @RequestParam(value ="tel",required = false) String tel,
152
                                          @RequestParam(value ="tel",required = false) String tel,

+ 1
- 0
src/main/java/com/huiju/estateagents/service/impl/TaRecommendCustomerServiceImpl.java ファイルの表示

343
         return taRecommendCustomerMapper.getCustomerList(page,building,name,tel,consultName,consultTel,entryType,verifyStatus,sex);
343
         return taRecommendCustomerMapper.getCustomerList(page,building,name,tel,consultName,consultTel,entryType,verifyStatus,sex);
344
     }
344
     }
345
 
345
 
346
+
346
     @Override
347
     @Override
347
     public IPage<TaRecommendCustomer> getRepCustomerList(int pageNumber, int pageSize,String building,String name,String tel,String consultName,String consultTel,String entryType,String verifyStatus,Integer sex){
348
     public IPage<TaRecommendCustomer> getRepCustomerList(int pageNumber, int pageSize,String building,String name,String tel,String consultName,String consultTel,String entryType,String verifyStatus,Integer sex){
348
         IPage<TaRecommendCustomer>page = new Page<>(pageNumber,pageSize);
349
         IPage<TaRecommendCustomer>page = new Page<>(pageNumber,pageSize);