提交 86dda308 编写于 作者: shihao.bao's avatar shihao.bao

注销账号接口4

上级 ac5599ac
流水线 #40407 已失败 于阶段
......@@ -9,9 +9,6 @@ import io.swagger.annotations.ApiModelProperty;
*/
public class CancelAccountDto {
@ApiModelProperty("医生ID")
private Integer doctorId;
@ApiModelProperty("注销原因NO")
private Integer reasonNo;
......@@ -23,14 +20,6 @@ public class CancelAccountDto {
private String remarks;
public Integer getDoctorId() {
return doctorId;
}
public void setDoctorId(Integer doctorId) {
this.doctorId = doctorId;
}
public Integer getReasonNo() {
return reasonNo;
}
......
......@@ -280,8 +280,8 @@ public class DoctorServiceImpl implements DoctorService {
*/
@Override
public void cancelAccountByDoctorId(CancelAccountDto cancelAccountDto, PicaUser picaUser) {
logger.info("DoctorServiceImpl.deleteDoctorById CancelAccountDto:{}", JSON.toJSONString(cancelAccountDto));
Doctor doctor = doctorMapper.selectByPrimaryKey(cancelAccountDto.getDoctorId());
logger.info("DoctorServiceImpl.deleteDoctorById CancelAccountDto:{}; USER: {}", JSON.toJSONString(cancelAccountDto), JSON.toJSONString(picaUser));
Doctor doctor = doctorMapper.selectByPrimaryKey(picaUser.getId());
if (Objects.isNull(doctor)) {
throw new PicaException(PicaResultCode.PARAM_NOT_COMPLETE.code(), "未查询到要删除的用户");
}
......@@ -348,6 +348,7 @@ public class DoctorServiceImpl implements DoctorService {
/**log*/
CancelAccountLog cancelAccountLog = new CancelAccountLog();
BeanUtils.copyProperties(cancelAccountDto, cancelAccountLog);
cancelAccountLog.setDoctorId(picaUser.getId());
cancelAccountLog.setDeleteFlag(1);
cancelAccountLog.setCreatId(picaUser.getId());
cancelAccountLog.setCreatTime(new Date());
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册