|
@@ -1,5 +1,7 @@
|
1
|
1
|
package com.yunzhi.marketing.borker.controller;
|
2
|
2
|
|
|
3
|
+import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
4
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
3
|
5
|
import com.yunzhi.marketing.base.BaseController;
|
4
|
6
|
import com.yunzhi.marketing.base.ResponseBean;
|
5
|
7
|
import com.yunzhi.marketing.borker.entity.BkBankCard;
|
|
@@ -13,10 +15,7 @@ import io.swagger.annotations.ApiOperation;
|
13
|
15
|
import io.swagger.annotations.ApiParam;
|
14
|
16
|
import org.springframework.beans.BeanUtils;
|
15
|
17
|
import org.springframework.beans.factory.annotation.Autowired;
|
16
|
|
-import org.springframework.web.bind.annotation.RequestBody;
|
17
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
18
|
|
-import org.springframework.web.bind.annotation.RequestMethod;
|
19
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
18
|
+import org.springframework.web.bind.annotation.*;
|
20
|
19
|
|
21
|
20
|
import javax.servlet.http.HttpServletRequest;
|
22
|
21
|
|
|
@@ -30,6 +29,21 @@ public class BorkerController extends BaseController {
|
30
|
29
|
IBkBankCardService iBkBankCardService;
|
31
|
30
|
|
32
|
31
|
|
|
32
|
+ @RequestMapping(value="/admin/borker",method= RequestMethod.GET)
|
|
33
|
+ @ApiOperation(value="经纪人列表", notes = "经纪人列表", httpMethod = "GET", response = ResponseBean.class)
|
|
34
|
+ public ResponseBean getBorkerList(@ApiParam("页码") @RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
|
|
35
|
+ @ApiParam("单页数据量") @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize,
|
|
36
|
+ @ApiParam("手机号") @RequestParam(value ="phone", required = false) String phone,
|
|
37
|
+ @ApiParam("姓名") @RequestParam(value ="name", required = false) String name,
|
|
38
|
+ @ApiParam("排序规则") @RequestParam(value ="sortOrder", defaultValue = "DESC") String sortOrder,
|
|
39
|
+ @ApiParam("排序字段") @RequestParam(value ="sortField", defaultValue = "create_date") String sortField) throws Exception {
|
|
40
|
+
|
|
41
|
+ IPage<BorkerVO> page = new Page<>(pageNum, pageSize);
|
|
42
|
+ IPage<BorkerVO> result = iTaPersonService.getBorkerPage(page, name, phone, sortOrder, sortField);
|
|
43
|
+ return ResponseBean.success(result);
|
|
44
|
+ }
|
|
45
|
+
|
|
46
|
+
|
33
|
47
|
@RequestMapping(value="/wx/bindBorker",method= RequestMethod.PUT)
|
34
|
48
|
@ApiOperation(value="成为经纪人", notes = "成为经纪人", httpMethod = "PUT", response = ResponseBean.class)
|
35
|
49
|
public ResponseBean bindBorker(@ApiParam("经纪人信息") @RequestBody BorkerVO borkerVO,
|