湖分管理
This commit is contained in:
@@ -39,6 +39,9 @@ public class UserContributionController {
|
||||
wrapper.like(MyUserEntity::getName,params.get("userName"));
|
||||
wrapper.like(MyUserEntity::getNickname,params.get("userName"));
|
||||
}
|
||||
if (params.containsKey("userId")&& StringUtils.isNotEmpty(params.get("userId").toString())) {
|
||||
wrapper.eq(MyUserEntity::getId,params.get("userId"));
|
||||
}
|
||||
if (params.containsKey("tel")&& StringUtils.isNotEmpty(params.get("tel").toString())) {
|
||||
wrapper.like(MyUserEntity::getTel,params.get("tel"));
|
||||
}
|
||||
@@ -67,8 +70,8 @@ public class UserContributionController {
|
||||
}
|
||||
|
||||
@RequestMapping("/delUserContribution")
|
||||
public R delMessage(String id) {
|
||||
contributionService.removeById(id);
|
||||
public R delMessage(@RequestBody UserContribution contribution) {
|
||||
contributionService.removeById(contribution.getId());
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
|
||||
@@ -205,7 +205,7 @@ public class UserManageServiceImpl implements UserManageService {
|
||||
mainExchangeWrapper.eq(UserContributionExchange :: getUserId,mainUser.getId());
|
||||
UserContributionExchange mainExchanges = exchangeDao.selectOne(mainExchangeWrapper);
|
||||
if (mainExchanges != null) {
|
||||
mainExchanges.setSurplus(mainExchanges.getSurplus()+exchange.getSurplus());
|
||||
mainExchanges.setSurplus(mainExchanges.getSurplus().add(exchange.getSurplus()));
|
||||
exchangeDao.updateById(mainExchanges);
|
||||
}else {
|
||||
exchange.setUserId(mainUser.getId());
|
||||
|
||||
Reference in New Issue
Block a user