Browse Source

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

# Conflicts:
#	svr/svr-iot/src/main/java/com/yihu/iot/service/monitorPlatform/MonitorPlatformService.java
wangzhinan 4 years ago
parent
commit
56a1428c1e

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

@ -4583,7 +4583,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
                " FROM " +
                " base_doctor d " +
                " JOIN base_doctor_hospital h ON h.doctor_code = d.id " +
                " Left join ( select count(id) as total,doctor from wlyy_outpatient where status = 2 GROUP BY doctor ) a on a.doctor = d.id ";
                " Left join ( select count(id) as total,doctor from wlyy_outpatient where status = 3 GROUP BY doctor ) a on a.doctor = d.id ";
        if ("1".equalsIgnoreCase(isAttention)) {
            sql += " join base_doctor_patient_follow follow on follow.doctor = d.id and follow.patient ='" + patientid + "' ";

+ 5 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/prescription/service/entrance/XzzxEntranceService.java

@ -1312,6 +1312,7 @@ public class XzzxEntranceService{
        WlyyOutpatientVO outpatientVO = new WlyyOutpatientVO();
        JSONArray array = new JSONArray();
        String response="";
        BasePatientDO patientDO = patientDao.findById(patient);
        PatientMappingDO patientMappingDO = patientMappingDao.findByPatient(patient);
        if (patientMappingDO!=null){
            patient = patientMappingDO.getMappingCode();
@ -1347,6 +1348,10 @@ public class XzzxEntranceService{
                outpatientVO.setCreateTime(DateUtil.strToDate(object.getString("CREATETIME")));
                outpatientVO.setStatus(isEmty(object.getString("STATUS")));
                outpatientVO.setConNo(isEmty(object.getString("VISITNUM")));
                outpatientVO.setHospitalName("厦门大学附属心血管病医院");
                outpatientVO.setHospital("350211A5010");
                outpatientVO.setSex(patientDO.getSex()+"");
                outpatientVO.setBirthday(patientDO.getBirthday());
            }
        }
        return outpatientVO;

+ 13 - 3
business/im-service/src/main/java/com/yihu/jw/im/service/ImService.java

@ -2236,8 +2236,18 @@ public class ImService {
			sql += " and a.id = '" + id + "'";
		}
		sql += " ORDER BY a.czrq desc ";
		
		return hibenateUtils.createSQLQuery(sql,page,pagesize);
		List<Map<String,Object>> mapList = hibenateUtils.createSQLQuery(sql,page,pagesize);
		for (Map<String,Object> map:mapList){
			if (map.get("patientIdcard")!=null){
				String idcard = map.get("patientIdcard").toString();
				Integer age = IdCardUtil.getAgeForIdcard(idcard);
				map.put("age",age);
			}else {
				map.put("age",null);
			}
		}
		return mapList;
	}
	
	/**
@ -2928,7 +2938,7 @@ public class ImService {
	 */
	public List<Map<String,Object>> doctorUpcomingList(String doctorCode, String type) {
		String sql = "";
		if("1,15".equals(type)) {
		if("1,15,17".equals(type)) {
			sql = "SELECT " +
					"a.id AS \"id\"," +
					"a.type AS \"type\"," +

+ 9 - 6
svr/svr-internet-hospital/src/main/java/com/yihu/jw/hospital/endpoint/Xzyy/XzyyController.java

@ -1,19 +1,19 @@
package com.yihu.jw.hospital.endpoint.Xzyy;
import com.yihu.jw.hospital.prescription.service.XzyyPrescriptionService;
import com.yihu.jw.hospital.prescription.service.entrance.XzzxEntranceService;
import com.yihu.jw.hospital.ykyy.service.YkyyService;
import com.yihu.jw.restmodel.hospital.prescription.WlyyPrescriptionVO;
import com.yihu.jw.restmodel.web.ListEnvelop;
import com.yihu.jw.restmodel.web.MixEnvelop;
import com.yihu.jw.restmodel.web.ObjEnvelop;
import com.yihu.jw.restmodel.web.endpoint.EnvelopRestEndpoint;
import com.yihu.jw.rm.hospital.BaseHospitalRequestMapping;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import oracle.jdbc.proxy.annotation.Post;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
 * Created by Trick on 2020/1/19.
 */
@ -107,7 +107,7 @@ public class XzyyController extends EnvelopRestEndpoint {
     */
    @GetMapping(value = "/getOriginPrescriptionList")
    @ApiOperation(value = "获取门诊下所有处方信息", notes = "获取门诊下所有处方信息")
    public ObjEnvelop getOriginPrescriptionList(@ApiParam(name = "registerSn", value = "流水号", required = false)
    public MixEnvelop getOriginPrescriptionList(@ApiParam(name = "registerSn", value = "流水号", required = false)
                                                @RequestParam(value = "registerSn",required = false)String registerSn,
                                                @ApiParam(name = "patNo", value = "病人id", required = false)
                                                @RequestParam(value = "patNo",required = false)String patNo,
@ -115,7 +115,10 @@ public class XzyyController extends EnvelopRestEndpoint {
                                                @RequestParam(value = "admNo",required = false)String admNo,
                                                @ApiParam(name = "realOrder", value = "处方号", required = false)
                                                @RequestParam(value = "realOrder",required = false)String realOrder)throws Exception{
        return ObjEnvelop.getSuccess("ok",xzzxEntranceService.selectPrescriptionList(registerSn,patNo,admNo,realOrder,null,null));
        MixEnvelop envelop = new MixEnvelop();
        List<WlyyPrescriptionVO> list = xzzxEntranceService.selectPrescriptionList(registerSn,patNo,admNo,realOrder,null,null);
        envelop.setDetailModelList(list);
        return envelop;
    }

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

@ -1150,7 +1150,9 @@ public class PrescriptionEndpoint extends EnvelopRestEndpoint {
                        consult.put("session_id", consult.get("patientId").toString()+"_"+ consult.get("doctorCode").toString()+"_1");
                    }else if(15 == consultType){//家医求助
                        consult.put("session_id", consult.get("patientId").toString()+"_"+ consult.get("generalDoctor").toString()+"_"+ consult.get("doctorCode").toString()+"_15");
                    }else{}
                    }else if (17==consultType){//视频咨询
                        consult.put("session_id", consult.get("patientId").toString()+"_"+ consult.get("doctorCode").toString()+"_17");
                    }
                }else if("9".equals(type)){//图文复诊
                    consult.put("session_id", consult.get("patientId").toString()+"_"+consult.get("outpatientId").toString()+"_9");