| | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.github.pagehelper.util.StringUtil; |
| | | import com.whyc.dto.Response; |
| | | import com.whyc.mapper.TableMapper; |
| | | import com.whyc.mapper.UserInfMapper; |
| | | import com.whyc.pojo.UserInf; |
| | | import com.whyc.util.AESUtil; |
| | |
| | | @Resource |
| | | private UserInfMapper userInfMapper; |
| | | |
| | | @Resource |
| | | private TableMapper tableMapper; |
| | | |
| | | /*public Response<String> preCheck(String name) { |
| | | Response<String> response = new Response<>(); |
| | | QueryWrapper<UserInf> queryWrapper = Wrappers.query(); |
| | |
| | | response.setMsg(encryptType); |
| | | return response; |
| | | }*/ |
| | | |
| | | @Transactional |
| | | public void bakUserInfo(){ |
| | | QueryWrapper<UserInf> queryWrapper = Wrappers.query(); |
| | | queryWrapper.select("uId as id","uSnId as SNId","upassword as password","uName as name"); |
| | | List<UserInf> userInfList = userInfMapper.selectList(queryWrapper); |
| | | |
| | | tableMapper.createUserBak(); |
| | | tableMapper.insertRecordToUserBak(userInfList); |
| | | } |
| | | |
| | | @Transactional |
| | | public void passwordReset(){ |
| | |
| | | userInf.setPassword(passwordRSA); |
| | | //userInfMapper.updateById(userInf); |
| | | }); |
| | | userInfMapper.updateBatch(userInfList); |
| | | //userInfMapper.updateBatch(userInfList); |
| | | } |
| | | |
| | | private String parsePassword(String passwordData){ |