|
@@ -15,6 +15,7 @@ import cn.hutool.core.util.StrUtil;
|
|
import cn.hutool.crypto.SecureUtil;
|
|
import cn.hutool.crypto.SecureUtil;
|
|
import com.github.pagehelper.PageHelper;
|
|
import com.github.pagehelper.PageHelper;
|
|
import com.github.pagehelper.PageInfo;
|
|
import com.github.pagehelper.PageInfo;
|
|
|
|
+import com.txz.cif.enums.BizTypeEnum;
|
|
import com.txz.cif.util.IpUtils;
|
|
import com.txz.cif.util.IpUtils;
|
|
import com.txz.cif.web.bo.UserBo;
|
|
import com.txz.cif.web.bo.UserBo;
|
|
import com.txz.cif.web.bo.UserBo2;
|
|
import com.txz.cif.web.bo.UserBo2;
|
|
@@ -49,6 +50,9 @@ public class UserController extends AbstractApiController {
|
|
@Resource
|
|
@Resource
|
|
private FlowService flowService;
|
|
private FlowService flowService;
|
|
|
|
|
|
|
|
+ @Resource
|
|
|
|
+ private AccountService accountService;
|
|
|
|
+
|
|
|
|
|
|
@PostMapping("/list")
|
|
@PostMapping("/list")
|
|
@ApiOperation(value = "获取用户",httpMethod = "POST")
|
|
@ApiOperation(value = "获取用户",httpMethod = "POST")
|
|
@@ -99,10 +103,14 @@ public class UserController extends AbstractApiController {
|
|
bo.setTeamNum(inviteNum+inviteNextNum);
|
|
bo.setTeamNum(inviteNum+inviteNextNum);
|
|
//付款过的订单
|
|
//付款过的订单
|
|
c = new Condition(Flow.class);
|
|
c = new Condition(Flow.class);
|
|
- c.createCriteria().andEqualTo("bizType",2001);
|
|
|
|
|
|
+ c.createCriteria().andIn("bizType", CollUtil.newArrayList(BizTypeEnum.OPEN_GROUP_PAY.getKey(),BizTypeEnum.JOIN_GROUP_PAY.getKey()));
|
|
Integer payNum = flowService.countByCondition(c);
|
|
Integer payNum = flowService.countByCondition(c);
|
|
bo.setSuccessGroupNum(payNum);
|
|
bo.setSuccessGroupNum(payNum);
|
|
-
|
|
|
|
|
|
+ //钱包余额
|
|
|
|
+ Account wallet = accountService.getAccount(u.getId(), 1);
|
|
|
|
+ bo.setWalletBalance(wallet.getBalance());
|
|
|
|
+ Account earnings = accountService.getAccount(u.getId(), 2);
|
|
|
|
+ bo.setEarningsBalance(earnings.getBalance());
|
|
return bo;
|
|
return bo;
|
|
}).collect(Collectors.toList()));
|
|
}).collect(Collectors.toList()));
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
@@ -112,5 +120,12 @@ public class UserController extends AbstractApiController {
|
|
return ResultGenerator.genSuccessResult(pageInfo);
|
|
return ResultGenerator.genSuccessResult(pageInfo);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ @GetMapping("/detail")
|
|
|
|
+ @ApiOperation(value = "获取用户详情",httpMethod = "GET")
|
|
|
|
+ public Result<List<UserBo2>> list(@RequestParam Long userId) {
|
|
|
|
+
|
|
|
|
+ return ResultGenerator.genSuccessResult();
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
|
|
}
|
|
}
|