up
This commit is contained in:
@@ -4,6 +4,7 @@ import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import com.core.common.utils.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
@@ -11,10 +12,6 @@ import org.springframework.web.bind.annotation.*;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.core.common.core.domain.R;
|
||||
import com.core.common.enums.AssignSeqEnum;
|
||||
import com.core.common.utils.AssignSeqUtil;
|
||||
import com.core.common.utils.ChineseConvertUtils;
|
||||
import com.core.common.utils.MessageUtils;
|
||||
import com.core.common.utils.StringUtils;
|
||||
import com.core.common.utils.bean.BeanUtils;
|
||||
import com.openhis.administration.domain.Patient;
|
||||
import com.openhis.administration.service.IPatientService;
|
||||
@@ -184,7 +181,11 @@ public class PatientInformationController {
|
||||
patient.setPyStr(ChineseConvertUtils.toPinyinFirstLetter(patient.getName()));
|
||||
// 设置五笔首拼
|
||||
patient.setWbStr(ChineseConvertUtils.toWBFirstLetter(patient.getName()));
|
||||
|
||||
//设置死亡时间
|
||||
if(patientService.isFuture(patientInformationDto.getDeceasedDate())){
|
||||
return R.fail(MessageUtils.createMessage(PromptMsgConstant.Common.M00003, new Object[] {"死亡时间未来时"}));
|
||||
}
|
||||
patient.setDeceasedDate(DateUtils.parseDate(patientInformationDto.getDeceasedDate()));
|
||||
// 调用服务层保存病人信息
|
||||
boolean savePatientSuccess = patientService.save(patient);
|
||||
|
||||
@@ -212,6 +213,11 @@ public class PatientInformationController {
|
||||
patient.setPyStr(ChineseConvertUtils.toPinyinFirstLetter(patient.getName()));
|
||||
// 设置五笔首拼
|
||||
patient.setWbStr(ChineseConvertUtils.toWBFirstLetter(patient.getName()));
|
||||
//设置死亡时间
|
||||
if(patientService.isFuture(patientInformationDto.getDeceasedDate())){
|
||||
return R.fail(MessageUtils.createMessage(PromptMsgConstant.Common.M00007, new Object[] {"死亡时间未来时"}));
|
||||
}
|
||||
patient.setDeceasedDate(DateUtils.parseDate(patientInformationDto.getDeceasedDate()));
|
||||
|
||||
// 调用服务层更新病人信息
|
||||
return patientService.updateById(patient)
|
||||
|
||||
Reference in New Issue
Block a user