Browse Source

Merge branch 'dev' of http://192.168.1.220:10080/Amoy2/wlyy2.0 into dev

# Conflicts:
#	svr/svr-internet-hospital/src/main/java/com/yihu/jw/hospital/endpoint/consult/PatientConsultEndpoint.java
wangzhinan 4 years ago
parent
commit
259c9b6193

+ 4 - 1
business/base-service/src/main/java/com/yihu/jw/hospital/prescription/service/PrescriptionService.java

@ -3280,7 +3280,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
        return rs;
    }
    public BaseDoctorDO updateDoctorInfo(String id, String img,String background,String expertise,String visitHospital,String visitHospitalName,String visitDept,String visitDeptName,String backgroundId,String name,Integer sex,String learning){
    public BaseDoctorDO updateDoctorInfo(String id, String img,String background,String expertise,String visitHospital,String visitHospitalName,String visitDept,String visitDeptName,String backgroundId,String name,Integer sex,String learning,String introduce){
        if (StringUtils.isNoneBlank(id)){
            BaseDoctorDO baseDoctorDO = baseDoctorDao.findById(id);
            if (StringUtils.isNoneBlank(img)){
@ -3323,6 +3323,9 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
            if (sex!=null){
                baseDoctorDO.setSex(sex);
            }
            if (StringUtils.isNoneBlank(introduce)){
                baseDoctorDO.setIntroduce(introduce);
            }
            return baseDoctorDao.save(baseDoctorDO);
        }else {
            return null;

+ 3 - 0
business/base-service/src/main/java/com/yihu/jw/patient/dao/BasePatientBusinessDao.java

@ -13,4 +13,7 @@ public interface BasePatientBusinessDao extends PagingAndSortingRepository<BaseP
    @Query("select a from BasePatientBusinessDO a where a.del=1 and a.id=?1")
    BasePatientBusinessDO findByIdAndDel(String id);
    @Query("select a from BasePatientBusinessDO a where a.del=1 and a.patient=?1 and a.relationCode=?2")
    BasePatientBusinessDO findByPatientAndRelationCodeAndDel(String patient,String relationCode);
}

+ 4 - 2
svr/svr-internet-hospital/src/main/java/com/yihu/jw/hospital/endpoint/prescription/PrescriptionEndpoint.java

@ -592,9 +592,11 @@ public class PrescriptionEndpoint extends EnvelopRestEndpoint {
                                       @ApiParam(name = "sex", value = "性别")
                                           @RequestParam(value = "sex", required = false)Integer sex,
                                       @ApiParam(name = "learning", value = "学术背景")
                                           @RequestParam(value = "learning", required = false)String learning){
                                           @RequestParam(value = "learning", required = false)String learning,
                                       @ApiParam(name = "introduce", value = "简介")
                                           @RequestParam(value = "introduce", required = false)String introduce){
        try {
            return success(prescriptionService.updateDoctorInfo(id, img,background,expertise, visitHospital, visitHospitalName, visitDept, visitDeptName, backgroundId,name,sex,learning));
            return success(prescriptionService.updateDoctorInfo(id, img,background,expertise, visitHospital, visitHospitalName, visitDept, visitDeptName, backgroundId,name,sex,learning,introduce));
        } catch (Exception e) {
            e.printStackTrace();
            return ObjEnvelop.getError(e.getMessage());

+ 5 - 1
svr/svr-internet-hospital/src/main/java/com/yihu/jw/hospital/service/consult/KnowledgeArticleService.java

@ -208,9 +208,13 @@ public class KnowledgeArticleService extends BaseJpaService<KnowledgeArticleDO,
	 * @param businessDOS
	 * @return
	 */
	public List<BasePatientBusinessDO> sendBusinessToPatient(List<BasePatientBusinessDO> businessDOS){
	public List<BasePatientBusinessDO> sendBusinessToPatient(List<BasePatientBusinessDO> businessDOS) throws Exception {
		if (businessDOS!=null&&businessDOS.size()!=0){
			for (BasePatientBusinessDO patientBusinessDO:businessDOS){
				BasePatientBusinessDO basePatientBusinessDO = patientBusinessDao.findByPatientAndRelationCodeAndDel(patientBusinessDO.getPatient(),patientBusinessDO.getRelationCode());
				if (basePatientBusinessDO != null) {
					throw new Exception("已发送过!");
				}
				patientBusinessDO.setCreateTime(new Date());
				patientBusinessDO.setUpdateTime(new Date());
				patientBusinessDO.setCreateUser(patientBusinessDO.getDoctor());