| | |
| | | public R unlock(@RequestParam("type")Integer type,@RequestParam("isReset")Integer isReset,@RequestParam("account")String account){ |
| | | stringRedisTemplate.delete("LOGIN_FAIL_"+account+"_"+type+"_"+this.getAppId()); |
| | | if(isReset==1){ |
| | | userService.resetPasswordAccount(type,account); |
| | | userService.resetPasswordAccount(type,account,this.getAppId()); |
| | | } |
| | | return R.ok(); |
| | | } |
| | |
| | | R resetPassword(@RequestParam("userId") Long userId); |
| | | |
| | | @GetMapping("/resetPasswordAccount") |
| | | R resetPasswordAccount(@RequestParam("type")Integer type,@RequestParam("account")String account); |
| | | R resetPasswordAccount(@RequestParam("type")Integer type,@RequestParam("account")String account,@RequestParam("appId")String appId); |
| | | |
| | | /** |
| | | * 批量重置密码用户登录密码默认admin123456 |
| | |
| | | } |
| | | |
| | | @GetMapping("/resetPasswordAccount") |
| | | public R resetPasswordAccount(@RequestParam("type")Integer type,@RequestParam("account")String account){ |
| | | return userService.resetPassword(type,account); |
| | | public R resetPasswordAccount(@RequestParam("type")Integer type,@RequestParam("account")String account,@RequestParam("appId")String appId){ |
| | | return userService.resetPassword(type,account,appId); |
| | | } |
| | | |
| | | @PostMapping("/tfLogin") |
| | |
| | | * @param account |
| | | * @return |
| | | */ |
| | | R resetPassword(Integer type,String account); |
| | | R resetPassword(Integer type,String account,String appId); |
| | | |
| | | /** |
| | | * 天府通办登录 |
| | |
| | | } |
| | | |
| | | @Override |
| | | public R resetPassword(Integer type, String account) { |
| | | SysUserDO sysUserDO=userDao.selectOne(new QueryWrapper<SysUserDO>().lambda().eq(SysUserDO::getAccount,account).eq(SysUserDO::getType,type)); |
| | | public R resetPassword(Integer type, String account,String appId) { |
| | | SysUserDO sysUserDO=userDao.selectOne(new QueryWrapper<SysUserDO>().lambda().eq(SysUserDO::getAccount,account).eq(SysUserDO::getType,type).eq(SysUserDO::getAppId,appId)); |
| | | if(sysUserDO!=null){ |
| | | sysUserDO.setPassword("$2a$10$F/2lE2NMhKNHJfi5.FLmfu7jIr7ImRWgCTTeO6m3IRNR2V4sv8YR."); |
| | | userDao.updateById(sysUserDO); |