新增:签到积分累加接口
This commit is contained in:
@@ -325,6 +325,17 @@ public class UserController extends BaseController {
|
||||
return fail("更新失败");
|
||||
}
|
||||
|
||||
@PostMapping("/updatePointsBySign")
|
||||
@ApiOperation("签到成功累加积分")
|
||||
public ApiResult<?> updatePointsBySign(){
|
||||
final User loginUser = getLoginUser();
|
||||
loginUser.setPoints(loginUser.getPoints() + 1);
|
||||
if (userService.updateUser(loginUser)) {
|
||||
return success("签到成功");
|
||||
}
|
||||
return fail("签到失败");
|
||||
}
|
||||
|
||||
@PreAuthorize("hasAuthority('sys:user:list')")
|
||||
@OperationLog
|
||||
@ApiOperation("统计用户余额")
|
||||
|
||||
Reference in New Issue
Block a user