fix:密码被覆盖

This commit is contained in:
sugus 2025-08-22 19:52:54 +08:00
parent 3f6569ac17
commit a909c9e5c1
2 changed files with 2 additions and 0 deletions

View File

@ -100,6 +100,7 @@ public class CnCustomerController {
if (null == entity.getId()) { if (null == entity.getId()) {
throw new RuntimeException("id不能为空"); throw new RuntimeException("id不能为空");
} }
entity.setPassword(null);
entityService.updateById(entity); entityService.updateById(entity);
return new ResponseEntity<>("成功修改客户", HttpStatus.OK); return new ResponseEntity<>("成功修改客户", HttpStatus.OK);
} catch (Exception e) { } catch (Exception e) {

View File

@ -119,6 +119,7 @@ public class EmEmployeesServiceImpl extends ServiceImpl<EmEmployeesMapper, EmEmp
public void update(EmEmployees resources) { public void update(EmEmployees resources) {
EmEmployees emEmployees = getById(resources.getId()); EmEmployees emEmployees = getById(resources.getId());
emEmployees.copy(resources); emEmployees.copy(resources);
emEmployees.setPassword(null);
emEmployeesMapper.updateById(emEmployees); emEmployeesMapper.updateById(emEmployees);
} }