| | |
| | | @ApiOperation("修改推荐关系") |
| | | public Result<Page<UserRecomDto>> update(@Valid @RequestBody UserRecomUpdateModel model) { |
| | | |
| | | model.setLoginSafeword(passwordManager.decryptPassword(model.getLoginSafeword())); |
| | | SysUser sysUser = sysUserService.getSysUserById( SecurityUtils.getSysUser().getUserId()); |
| | | if(!passwordEncoder.matches(model.getLoginSafeword(), sysUser.getSafePassword())) { |
| | | throw new YamiShopBindException("资金密码不正确!"); |
| | | } |
| | | UserRecom userRecom= userRecomService.getById(model.getId()); |
| | | if (userRecom==null){ |
| | | throw new YamiShopBindException("参数错误!"); |