Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -64,6 +64,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
|
|||||||
"/api/wx-official/**",
|
"/api/wx-official/**",
|
||||||
"/api/system/user/loginByPhoneForTest",
|
"/api/system/user/loginByPhoneForTest",
|
||||||
"/api/system/user/updateUserBalanceWithoutLogin",
|
"/api/system/user/updateUserBalanceWithoutLogin",
|
||||||
|
"/api/system/user/addUserBalanceWithoutLogin",
|
||||||
"/api/system/user/getUserWithoutLogin",
|
"/api/system/user/getUserWithoutLogin",
|
||||||
"/api/system/user/batchBackUserId",
|
"/api/system/user/batchBackUserId",
|
||||||
"/api/system/user/getByPhone/**",
|
"/api/system/user/getByPhone/**",
|
||||||
|
|||||||
@@ -456,7 +456,20 @@ public class UserController extends BaseController {
|
|||||||
public ApiResult<?> updateUserBalanceWithoutLogin(@RequestBody User user) {
|
public ApiResult<?> updateUserBalanceWithoutLogin(@RequestBody User user) {
|
||||||
if (user.getAuthCode() == null || !user.getAuthCode().equals("1700083"))
|
if (user.getAuthCode() == null || !user.getAuthCode().equals("1700083"))
|
||||||
return fail("参数错误");
|
return fail("参数错误");
|
||||||
if (userService.updateUser(user)) {
|
if (userService.updateById(user)) {
|
||||||
|
return success("操作成功");
|
||||||
|
}
|
||||||
|
return fail("操作失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/addUserBalanceWithoutLogin")
|
||||||
|
@ApiOperation("增加用户余额(无需登陆)")
|
||||||
|
public ApiResult<?> addUserBalanceWithoutLogin(@RequestBody User user) {
|
||||||
|
if (user.getAuthCode() == null || !user.getAuthCode().equals("1700083"))
|
||||||
|
return fail("参数错误");
|
||||||
|
User user1 = userService.getByIdRel(user.getUserId());
|
||||||
|
user1.setBalance(user1.getBalance().add(user.getBalance()));
|
||||||
|
if (userService.updateById(user1)) {
|
||||||
return success("操作成功");
|
return success("操作成功");
|
||||||
}
|
}
|
||||||
return fail("操作失败");
|
return fail("操作失败");
|
||||||
|
|||||||
Reference in New Issue
Block a user