Browse Source

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

LAPTOP-KB9HII50\70708 3 years ago
parent
commit
5f2a3754a7

+ 160 - 251
business/base-service/src/main/java/com/yihu/jw/healthCare/service/HealthCareService.java

@ -10,6 +10,8 @@ import com.yihu.jw.entity.base.doctor.BaseDoctorHospitalDO;
import com.yihu.jw.entity.base.patient.BasePatientDO;
import com.yihu.jw.entity.hospital.consult.WlyyHospitalSysDictDO;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalBillDO;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalIcdDO;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalMxDO;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalRelationDO;
import com.yihu.jw.entity.hospital.httplog.YlzHttpLogDO;
import com.yihu.jw.entity.hospital.mapping.DoctorMappingDO;
@ -22,6 +24,8 @@ import com.yihu.jw.healthCare.utils.AES;
import com.yihu.jw.healthCare.utils.SafeUtil;
import com.yihu.jw.hospital.dict.WlyyHospitalSysDictDao;
import com.yihu.jw.hospital.healthCare.YlzMedicailBillDao;
import com.yihu.jw.hospital.healthCare.YlzMedicailIcdDao;
import com.yihu.jw.hospital.healthCare.YlzMedicailMxDao;
import com.yihu.jw.hospital.healthCare.YlzMedicailRelationDao;
import com.yihu.jw.hospital.httplog.dao.YlzHttpLogDao;
import com.yihu.jw.hospital.mapping.dao.PatientMappingDao;
@ -83,6 +87,10 @@ public class HealthCareService {
    private YlzMedicailRelationDao ylzMedicailRelationDao;
    @Autowired
    private YlzMedicailBillDao ylzMedicailBillDao;
    @Autowired
    private YlzMedicailIcdDao ylzMedicailIcdDao;
    @Autowired
    private YlzMedicailMxDao ylzMedicailMxDao;
    private String ylzConfigUrl;
    private String ylzConfigAppid;
@ -879,24 +887,24 @@ public class HealthCareService {
     */
    public String register(String outpatientId) throws Exception{
        String funid = "N20.17.04.01";
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("上传医保失败:门诊为空!");
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("上传医保挂号失败:结算信息为空!");
        }
        JSONObject data = new JSONObject();
        data.put("region_code","350200");//参保地区划代码
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("cert_type","01");//证件类型
        data.put("medical_mode","10");//医疗就诊方式
        data.put("medical_type","11");//医疗类别
        data.put("his_serial",outpatientDO.getRegisterNo());//his流水号
        data.put("his_dept_code",outpatientDO.getDept());//his内部科室编码
        data.put("his_dept_name",outpatientDO.getDeptName());//his内部科室名称
        data.put("emergency_sign",0);//急诊标志0 否,1 是
        data.put("trauma_sign",0);//外伤标志0 否,1 是
        data.put("date", DateUtil.dateToStrLong(outpatientDO.getAdmDate()));//实际门诊/入院日期 若为空,默认取系统时间
        data.put("data_source","53");//数据来源
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("cert_type",ylzMedicalRelationDO.getCertType());//证件类型
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("medical_type",ylzMedicalRelationDO.getMedicalType());//医疗类别
        data.put("his_serial",ylzMedicalRelationDO.getHisSerial());//his流水号
        data.put("his_dept_code",ylzMedicalRelationDO.getHisDeptCode());//his内部科室编码
        data.put("his_dept_name",ylzMedicalRelationDO.getHisDeptName());//his内部科室名称
        data.put("emergency_sign",ylzMedicalRelationDO.getEmergencySign());//急诊标志0 否,1 是
        data.put("trauma_sign",ylzMedicalRelationDO.getTraumaSign());//外伤标志0 否,1 是
        data.put("date", DateUtil.dateToStrLong(ylzMedicalRelationDO.getDate()));//实际门诊/入院日期 若为空,默认取系统时间
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        String result = requestYlz(data,funid,"医保挂号");
        if (result==null){
            throw new Exception("上传医保挂号失败!");
@ -905,9 +913,8 @@ public class HealthCareService {
        if (object.getString("flag").equalsIgnoreCase("1")){
            JSONObject encryptData = object.getJSONObject("encrypt_data");
            String insuranceSerial = encryptData.getString("insurance_serial");
            outpatientDO.setInsuranceSerial(insuranceSerial);
            outpatientDO.setMedicalStatus(1);
            outpatientDao.save(outpatientDO);
            ylzMedicalRelationDO.setInsuranceSerial(insuranceSerial);
            ylzMedicailRelationDao.save(ylzMedicalRelationDO);
            logger.info("医保挂号流水号保存成功");
        }
        return result;
@ -925,20 +932,20 @@ public class HealthCareService {
     */
    public String registerBack(String outpatientId) throws Exception{
        String funid = "N20.17.04.02";
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("上传医保失败:门诊为空!");
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("医保挂号冲销失败:结算信息为空!");
        }
        JSONObject data = new JSONObject();
        data.put("region_code","350200");//参保地区划代码
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("cert_type","01");//证件类型
        data.put("medical_mode","10");//医疗就诊方式
        data.put("medical_type","11");//医疗类别
        data.put("his_serial",outpatientDO.getRegisterNo());//his流水号
        data.put("insurance_serial",outpatientDO.getInsuranceSerial());//医保流水号
        data.put("data_source","53");//数据来源
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("cert_type",ylzMedicalRelationDO.getCertType());//证件类型
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("medical_type",ylzMedicalRelationDO.getMedicalType());//医疗类别
        data.put("his_serial",ylzMedicalRelationDO.getHisSerial());//his流水号
        data.put("insurance_serial",ylzMedicalRelationDO.getInsuranceSerial());//医保流水号
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        String result = requestYlz(data,funid,"医保挂号冲销");
        if (result==null){
            throw new Exception("上传医保挂号冲销失败!");
@ -947,9 +954,6 @@ public class HealthCareService {
        if (object.getString("flag").equalsIgnoreCase("1")){
            JSONObject encryptData = object.getJSONObject("encrypt_data");
            String invalidSerial = encryptData.getString("refund_serial");
            outpatientDO.setInvalidSerial(invalidSerial);
            outpatientDO.setMedicalStatus(0);
            outpatientDao.save(outpatientDO);
            logger.info("医保挂号冲销流水号保存成功");
        }
        return result;
@ -965,80 +969,64 @@ public class HealthCareService {
     */
    public String feeDetailUpload(String outpatientId) throws Exception{
        String funid = "N20.17.04.03";
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("上传医保费用明细失败:门诊信息为空!");
        }
        BaseDoctorDO doctorDO = doctorDao.findById(outpatientDO.getDoctor());
        if (doctorDO==null){
            throw new Exception("上传医保费用明细失败:医生信息为空!");
        }
        String peopleType = "";
        WlyyHospitalSysDictDO hospitalSysDictDO = hospitalSysDictDao.findByHospitalAndDictCode("doctorType",doctorDO.getJobTitleName());
        Double register = outpatientDO.getFee();
        Double drugFee= 0.0;
        List<WlyyPrescriptionDO> wlyyPrescriptionDOS = prescriptionDao.findByOutPatientIdList(outpatientId);
        for (WlyyPrescriptionDO wlyyPrescriptionDO:wlyyPrescriptionDOS){
            drugFee +=wlyyPrescriptionDO.getDrugFee();
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("医保费用明细上传:结算信息为空!");
        }
        JSONObject data = new JSONObject();
        data.put("region_code","350200");//参保地区划代码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("cert_type","01");//证件类型 TODO
        data.put("medical_mode","10");//医疗就诊方式
        data.put("insurance_serial",outpatientDO.getInsuranceSerial());//医保流水号
        data.put("his_serial",outpatientDO.getRegisterNo());//his流水号
        data.put("item_count",2);//明细项目数量
        data.put("total_amount",drugFee+register);//医疗费总金额
        data.put("data_source","53");//数据来源
        String icd10 = outpatientDO.getIcd10();
        String icd10Name = outpatientDO.getIcd10Name();
        String icd[] = icd10.split(",");
        String icdName[] = icd10Name.split(",");
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("cert_type",ylzMedicalRelationDO.getCertType());//证件类型 TODO
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("insurance_serial",ylzMedicalRelationDO.getInsuranceSerial());//医保流水号
        data.put("his_serial",ylzMedicalRelationDO.getHisSerial());//his流水号
        data.put("item_count",ylzMedicalRelationDO.getItemCount());//明细项目数量
        data.put("total_amount",ylzMedicalRelationDO.getTotalAmount());//医疗费总金额
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        List<YlzMedicalIcdDO> ylzMedicalIcdDOList = ylzMedicailIcdDao.findByMedicalId(ylzMedicalRelationDO.getId());
        if (ylzMedicalIcdDOList==null){
            throw new Exception("医保费用明细上传:诊断结算信息为空!");
        }
        JSONArray icdArray = new JSONArray();
        for (int i=0;i<icd.length;i++){
        for (YlzMedicalIcdDO ylzMI:ylzMedicalIcdDOList){
            JSONObject icdObj = new JSONObject();
            icdObj.put("disease_code_icd10",icd[i]);//诊断或症状编码
            icdObj.put("disease_name_icd10",icdName[i]);//诊断或症状名称
            icdObj.put("disease_type","01");//诊断或症状类型
            icdObj.put("disease_order",i);//诊断或症状序号
            icdObj.put("disease_code_icd10",ylzMI.getDiseaseCodeIcd10());//诊断或症状编码
            icdObj.put("disease_name_icd10",ylzMI.getDiseaseNameIcd10());//诊断或症状名称
            icdObj.put("disease_type",ylzMI.getDiseaseType());//诊断或症状类型
            icdObj.put("disease_order",ylzMI.getDiseaseOrder());//诊断或症状序号
            icdArray.add(icdObj);
        }
        data.put("zdlist",icdArray);
        List<YlzMedicalMxDO> ylzMedicalMxDOS = ylzMedicailMxDao.findByMedicalId(ylzMedicalRelationDO.getId());
        if (ylzMedicalIcdDOList==null){
            throw new Exception("医保费用明细上传:诊断结算信息为空!");
        }
        JSONArray infoArray = new JSONArray();
        for (WlyyPrescriptionDO wlyyPrescriptionDO:wlyyPrescriptionDOS){
            List<WlyyPrescriptionInfoDO> prescriptionInfoDOS = prescriptionInfoDao.findByPrescriptionId(wlyyPrescriptionDO.getId(),1);
            for (WlyyPrescriptionInfoDO wlyyPrescriptionInfoDO:prescriptionInfoDOS){
        for (YlzMedicalMxDO ylzMedicalMxDO:ylzMedicalMxDOS){
                JSONObject infoObj = new JSONObject();
                infoObj.put("prescription_code",wlyyPrescriptionDO.getRealOrder());//医院处方编号
                infoObj.put("his_detail_sn",wlyyPrescriptionDO.getVoucherNo());//his处方明细流水号
                infoObj.put("item_name","西药费");//医保项目名称
                infoObj.put("item_code","61");//医保项目编码
                infoObj.put("specification_type",wlyyPrescriptionInfoDO.getSpecification());//规格型号
                infoObj.put("dosage_form",wlyyPrescriptionInfoDO.getDosage());//剂型
                infoObj.put("charge_unit",wlyyPrescriptionInfoDO.getPackUnitName());//单位
                infoObj.put("price",wlyyPrescriptionInfoDO.getPackRetprice());//单价
                infoObj.put("amount",wlyyPrescriptionInfoDO.getQuantity());//数量
                infoObj.put("total_money",wlyyPrescriptionInfoDO.getPackRetprice()*Integer.parseInt(wlyyPrescriptionInfoDO.getQuantity()));//金额
                infoObj.put("prescription_date", DateUtil.dateToStrLong(wlyyPrescriptionDO.getCreateTime()));//处方日期
                infoObj.put("his_dept_code",wlyyPrescriptionDO.getDept());//his内部科室编码
                infoObj.put("his_dept_name",wlyyPrescriptionDO.getDeptName());//his内部科室名称
                infoObj.put("medical_per_name",wlyyPrescriptionDO.getDoctorName());//医疗服务人员姓名
                infoObj.put("medical_per_id",doctorDO.getIdcard());//医疗服务人员证件号码
                infoObj.put("limit_type","");//限制范围类别
                infoObj.put("actg_date",DateUtil.dateToStr(wlyyPrescriptionDO.getPrescribeTime(),DateUtil.YYYYMMDD));//记帐日期
                infoObj.put("his_item_name",wlyyPrescriptionInfoDO.getDrugName());//HIS院内项目名称
                infoObj.put("his_item_code",wlyyPrescriptionInfoDO.getDrugNo());//HIS院内项目编码
                infoObj.put("clerk_days",DateUtil.dateToStrLong(wlyyPrescriptionDO.getPrescribeTime()));//记帐日期
                if (hospitalSysDictDO==null){
                    infoObj.put("people_type","03");//医保服务人员类别
                }else {
                    infoObj.put("people_type",hospitalSysDictDO.getDictValue());//医保服务人员类别
                }
                infoObj.put("prescription_code",ylzMedicalMxDO.getPrescriptionCode());//医院处方编号
                infoObj.put("his_detail_sn",ylzMedicalMxDO.getHisDetailSn());//his处方明细流水号
                infoObj.put("item_name",ylzMedicalMxDO.getItemName());//医保项目名称
                infoObj.put("item_code",ylzMedicalMxDO.getItemCode());//医保项目编码
                infoObj.put("specification_type",ylzMedicalMxDO.getSpecificationType());//规格型号
                infoObj.put("dosage_form",ylzMedicalMxDO.getDosageForm());//剂型
                infoObj.put("charge_unit",ylzMedicalMxDO.getChargeUnit());//单位
                infoObj.put("price",ylzMedicalMxDO.getPrice());//单价
                infoObj.put("amount",ylzMedicalMxDO.getAmount());//数量
                infoObj.put("total_money",ylzMedicalMxDO.getTotalMoney());//金额
                infoObj.put("prescription_date", DateUtil.dateToStrLong(ylzMedicalMxDO.getPrescriptionDate()));//处方日期
                infoObj.put("his_dept_code",ylzMedicalMxDO.getHisDeptCode());//his内部科室编码
                infoObj.put("his_dept_name",ylzMedicalMxDO.getHisDeptName());//his内部科室名称
                infoObj.put("medical_per_name",ylzMedicalMxDO.getMedicalPerName());//医疗服务人员姓名
                infoObj.put("medical_per_id",ylzMedicalMxDO.getMedicalPerId());//医疗服务人员证件号码
                infoObj.put("limit_type",ylzMedicalMxDO.getLimitType());//限制范围类别
                infoObj.put("actg_date",DateUtil.dateToStr(ylzMedicalMxDO.getActgDate(),DateUtil.YYYYMMDD));//记帐日期
                infoObj.put("his_item_name",ylzMedicalMxDO.getHisItemName());//HIS院内项目名称
                infoObj.put("his_item_code",ylzMedicalMxDO.getHisItemCode());//HIS院内项目编码
                infoObj.put("clerk_days",DateUtil.dateToStrLong(ylzMedicalMxDO.getClerkDays()));//记帐日期
                infoObj.put("people_type",ylzMedicalMxDO.getPeopleType());//医保服务人员类别
                infoArray.add(infoObj);
            }
        }
        data.put("mxlist",infoArray);
        String result = requestYlz(data,funid,"医保费用明细上传");
@ -1049,11 +1037,8 @@ public class HealthCareService {
        if (object.getString("flag").equalsIgnoreCase("1")){
            JSONObject encryptData = object.getJSONObject("encrypt_data");
            String detailSerial = encryptData.getString("detail_serial");
            for (WlyyPrescriptionDO presDo:wlyyPrescriptionDOS){
                presDo.setDetailSerial(detailSerial);
                presDo.setMedicalStatus(1);
                prescriptionDao.save(presDo);
            }
            ylzMedicalRelationDO.setDetailSerial(detailSerial);
            ylzMedicailRelationDao.save(ylzMedicalRelationDO);
            logger.info("医保费用明细上传失败保存成功");
        }
        return result;
@ -1070,40 +1055,26 @@ public class HealthCareService {
     */
    public String feeDetailRefund(String outpatientId,String prescriptionId,String remark) throws Exception{
        String funid = "N20.17.04.04";
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("上传医保失败:门诊为空!");
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("医保费用明细上传:结算信息为空!");
        }
        JSONObject data = new JSONObject();
        data.put("region_code","350200");//参保地区划代码
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("medical_mode","10");//医疗就诊方式
        data.put("medical_type","11");//医疗类别
        if (StringUtils.isNoneBlank(prescriptionId)){
            WlyyPrescriptionDO wlyyPrescriptionDO = prescriptionDao.findOne(prescriptionId);
            data.put("detail_serial",wlyyPrescriptionDO.getDetailSerial());//医保明细流水号
        }
        data.put("insurance_serial",outpatientDO.getInsuranceSerial());//医保流水号
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("medical_type",ylzMedicalRelationDO.getMedicalType());//医疗类别
        data.put("detail_serial",ylzMedicalRelationDO.getDetailSerial());//医保明细流水号
        data.put("insurance_serial",ylzMedicalRelationDO.getInsuranceSerial());//医保流水号
        data.put("invalidation_reason",remark);//作废原因
        data.put("data_source","53");//数据来源
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        String result = requestYlz(data,funid,"医保费用明细上传冲销");
        if (result==null){
            throw new Exception("医保费用明细上传冲销失败!");
        }
        JSONObject object = JSONObject.parseObject(result);
        if (object.getString("flag").equalsIgnoreCase("1")){
            if (StringUtils.isNoneBlank(prescriptionId)){
                WlyyPrescriptionDO wlyyPrescriptionDO = prescriptionDao.findOne(prescriptionId);
                wlyyPrescriptionDO.setMedicalStatus(0);
                prescriptionDao.save(wlyyPrescriptionDO);
            }else {
                List<WlyyPrescriptionDO> prescriptionDOList = prescriptionDao.findByOutPatientIdListAndMedical(outpatientId);
                for (WlyyPrescriptionDO preDo:prescriptionDOList){
                    preDo.setMedicalStatus(0);
                    prescriptionDao.save(preDo);
                }
            }
            logger.info("医保费用明细上传冲销保存成功");
        }
        return result;
@ -1120,54 +1091,30 @@ public class HealthCareService {
     */
    public String preSettlement(String outpatientId) throws Exception{
        String funid = "N20.17.04.05";
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("上传医保预结算服务失败:门诊为空!");
        }
        BaseDoctorDO doctorDO = doctorDao.findById(outpatientDO.getDoctor());
        if (doctorDO==null){
            throw new Exception("上传医保预结算服务失败:医生信息为空!");
        }
        WlyyHospitalSysDictDO hospitalSysDictDO = hospitalSysDictDao.findByHospitalAndDictCode("doctorType",doctorDO.getJobTitleName());
        Double register = outpatientDO.getFee();
        Double drugFee= 0.0;
        List<WlyyPrescriptionDO> wlyyPrescriptionDOS = prescriptionDao.findByOutPatientIdList(outpatientId);
        List<String> list = new ArrayList<>();
        for (WlyyPrescriptionDO wlyyPrescriptionDO:wlyyPrescriptionDOS){
            drugFee +=wlyyPrescriptionDO.getDrugFee();
            if (list!=null&&list.size()!=0&&!list.contains(wlyyPrescriptionDO.getRealOrder())){
                list.add(wlyyPrescriptionDO.getRealOrder());
            }
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("医保费用明细上传:结算信息为空!");
        }
        JSONObject data = new JSONObject();
        data.put("region_code","350200");//参保地区划代码
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("cert_type","01");//证件类型
        data.put("medical_mode","10");//医疗就诊方式
        data.put("medical_type","11");//医疗类别
        data.put("his_bill_serial",outpatientDO.getXtgzh());//his收费单据流水号
        data.put("insurance_serial",outpatientDO.getInsuranceSerial());//医保流水号
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("cert_type",ylzMedicalRelationDO.getCertType());//证件类型
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("medical_type",ylzMedicalRelationDO.getMedicalType());//医疗类别
        data.put("his_bill_serial",ylzMedicalRelationDO.getHisBillSerial());//his收费单据流水号
        data.put("insurance_serial",ylzMedicalRelationDO.getInsuranceSerial());//医保流水号
        data.put("settlement_sign",0);//结算标识
        data.put("date",outpatientDO.getAdmDate());//实际就诊日期
        data.put("date",DateUtil.dateToStrLong(ylzMedicalRelationDO.getDate()));//实际就诊日期
        data.put("leave_method","09");//离院方式
        data.put("pre_count",list.size());//处方项目数
        data.put("total_amount",drugFee+register);//医疗费总金额
        data.put("data_source","53");//数据来源
        data.put("his_serial",outpatientDO.getRegisterNo());//his流水号
        if (hospitalSysDictDO==null){
            data.put("doctor_level","03");//医师诊查费等级
            data.put("trt_fee_level","03");//医师诊查费等级
        }else {
            data.put("doctor_level",hospitalSysDictDO.getDictValue());//医师诊查费等级
            data.put("trt_fee_level",hospitalSysDictDO.getDictValue());//医师诊查费等级
        }
        data.put("dept_code",outpatientDO.getDept());//科室编码
        data.put("charge_qty",1+list.size());//本次收费次数
        data.put("pre_count",ylzMedicalRelationDO.getPreCount());//处方项目数
        data.put("total_amount",ylzMedicalRelationDO.getTotalAmount());//医疗费总金额
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        data.put("his_serial",ylzMedicalRelationDO.getHisSerial());//his流水号
        data.put("doctor_level",ylzMedicalRelationDO.getDoctorLevel());//医师诊查费等级
        data.put("trt_fee_level",ylzMedicalRelationDO.getDoctorLevel());//医师诊查费等级
        data.put("dept_code",ylzMedicalRelationDO.getDeptCode());//科室编码
        data.put("charge_qty",1);//本次收费次数
        String result = requestYlz(data,funid,"医保预结算服务");
        if (result==null){
@ -1177,41 +1124,28 @@ public class HealthCareService {
        if (object.getString("flag").equalsIgnoreCase("1")){
            JSONObject encryptData = object.getJSONObject("encrypt_data");
            String billSerial = encryptData.getString("bill_serial");
            outpatientDO.setBillSerial(billSerial);
            outpatientDao.save(outpatientDO);
            YlzMedicalRelationDO ylzMr = new YlzMedicalRelationDO();
            ylzMr.setCardNo(encryptData.getString("card_no"));
            ylzMr.setInsuranceSerial(encryptData.getString("insurance_serial"));
            ylzMr.setBillSerial(encryptData.getString("bill_serial"));
            ylzMr.setHisBillSerial(encryptData.getString("his_bill_serial"));
            ylzMr.setMedicalMode(encryptData.getString("medical_mode"));
            ylzMr.setMedicalType(encryptData.getString("medical_type"));
            ylzMr.setPersonalCode(encryptData.getString("personal_code"));
            ylzMr.setName(encryptData.getString("name"));
            ylzMr.setSex(encryptData.getString("sex"));
            ylzMr.setSexMc(encryptData.getString("sex_mc"));
            ylzMr.setTotalAmount(encryptData.getString("total_amount"));
            ylzMr.setPersonCash(encryptData.getString("person_cash"));
            ylzMr.setPersonAccount(encryptData.getString("person_account"));
            ylzMr.setFundPrice(encryptData.getString("fund_price"));
            ylzMr.setJkzhPay(encryptData.getString("jkzh_pay"));
            ylzMr.setOwnPay(encryptData.getString("own_pay"));
            ylzMr.setAccountBalance(encryptData.getString("account_balance"));
            ylzMr.setHospitalizationQty(encryptData.getString("hospitalization_qty"));
            ylzMr.setDate(DateUtil.strToDateLong(encryptData.getString("date")));
            ylzMr.setPayDate(DateUtil.strToDateLong(encryptData.getString("pay_date")));
            ylzMr.setInvoiceJj(encryptData.getString("invoice_jj"));
            ylzMr.setInvoiceXj(encryptData.getString("invoice_xj"));
            ylzMr.setInvoiceZh(encryptData.getString("invoice_zh"));
            ylzMr.setDel(1);
            ylzMr.setRelationCode(outpatientId);
            ylzMr.setCreateTime(new Date());
            ylzMr = ylzMedicailRelationDao.save(ylzMr);
            ylzMedicalRelationDO.setInsuranceSerial(encryptData.getString("insurance_serial"));
            ylzMedicalRelationDO.setBillSerial(encryptData.getString("bill_serial"));
            ylzMedicalRelationDO.setHisBillSerial(encryptData.getString("his_bill_serial"));
            ylzMedicalRelationDO.setSexMc(encryptData.getString("sex_mc"));
            ylzMedicalRelationDO.setPersonCash(encryptData.getString("person_cash"));
            ylzMedicalRelationDO.setPersonAccount(encryptData.getString("person_account"));
            ylzMedicalRelationDO.setFundPrice(encryptData.getString("fund_price"));
            ylzMedicalRelationDO.setJkzhPay(encryptData.getString("jkzh_pay"));
            ylzMedicalRelationDO.setOwnPay(encryptData.getString("own_pay"));
            ylzMedicalRelationDO.setAccountBalance(encryptData.getString("account_balance"));
            ylzMedicalRelationDO.setHospitalizationQty(encryptData.getString("hospitalization_qty"));
            ylzMedicalRelationDO.setPayDate(DateUtil.strToDateLong(encryptData.getString("pay_date")));
            ylzMedicalRelationDO.setInvoiceJj(encryptData.getString("invoice_jj"));
            ylzMedicalRelationDO.setInvoiceXj(encryptData.getString("invoice_xj"));
            ylzMedicalRelationDO.setInvoiceZh(encryptData.getString("invoice_zh"));
            ylzMedicalRelationDO.setCreateTime(new Date());
            ylzMedicalRelationDO = ylzMedicailRelationDao.save(ylzMedicalRelationDO);
            JSONArray jsonArray = encryptData.getJSONArray("fplist");
            for (int i=0;i<jsonArray.size();i++){
                JSONObject jsonObject = jsonArray.getJSONObject(i);
                YlzMedicalBillDO ylzMb = new YlzMedicalBillDO();
                ylzMb.setMedicalId(ylzMr.getId());
                ylzMb.setMedicalId(ylzMedicalRelationDO.getId());
                ylzMb.setInvoicePay(jsonObject.getString("invoice_pay"));
                ylzMb.setInvoiceType(jsonObject.getString("invoice_type"));
                ylzMb.setInvoiceTypeName(jsonObject.getString("invoice_type_name"));
@ -1238,21 +1172,21 @@ public class HealthCareService {
     */
    public String preSettlementRefund(String outpatientId) throws Exception{
        String funid = "N20.17.04.06";
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("上传医保失败:门诊为空!");
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("医保结算冲销上传:结算信息为空!");
        }
        JSONObject data = new JSONObject();
        data.put("region_code","350200");//参保地区划代码
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("cert_type","01");//证件类型
        data.put("medical_mode","10");//医疗就诊方式
        data.put("bill_serial",outpatientDO.getBillSerial());//医保收费流水号
        data.put("his_bill_serial",outpatientDO.getXtgzh());//his收费单据流水号
        data.put("insurance_serial",outpatientDO.getInsuranceSerial());//医保流水号
        data.put("data_source","53");//数据来源
        data.put("refund_serial",outpatientDO.getRegisterNo());//医院退费操作流水号
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("cert_type",ylzMedicalRelationDO.getCertType());//证件类型
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("bill_serial",ylzMedicalRelationDO.getBillSerial());//医保收费流水号
        data.put("his_bill_serial",ylzMedicalRelationDO.getHisSerial());//his收费单据流水号
        data.put("insurance_serial",ylzMedicalRelationDO.getInsuranceSerial());//医保流水号
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        data.put("refund_serial",ylzMedicalRelationDO.getHisSerial());//医院退费操作流水号
        String result = requestYlz(data,funid,"医保结算冲销服务");
        if (result==null){
            throw new Exception("医保结算冲销服务失败!");
@ -1277,57 +1211,32 @@ public class HealthCareService {
    public String getSettlementResultUrl(String outpatientId) throws Exception{
        String funid = "N20.17.04.07";
        JSONObject data = new JSONObject();
        WlyyOutpatientDO outpatientDO = outpatientDao.findById(outpatientId);
        if (outpatientDO==null){
            throw new Exception("获取医保结算页面地址失败:门诊为空!");
        }
        YlzMedicalRelationDO ylzMedicalRelationDO =ylzMedicailRelationDao.findByOutpatient(outpatientId);
        YlzMedicalRelationDO ylzMedicalRelationDO = ylzMedicailRelationDao.findByOutpatient(outpatientId);
        if (ylzMedicalRelationDO==null){
            throw new Exception("获取医保结算页面地址失败:预结算信息为空");
            throw new Exception("获取医保结算页面地址:结算信息为空!");
        }
        WlyyHospitalSysDictDO wlyyHospitalSysDictDO = hospitalSysDictDao.findById("ResultRedirectUrl");
        if (wlyyHospitalSysDictDO==null){
            throw new Exception("获取医保结算页面地址失败:回调地址为空");
        }
        BaseDoctorDO doctorDO = doctorDao.findById(outpatientDO.getDoctor());
        if (doctorDO==null){
            throw new Exception("获取医保结算页面地址失败:医生信息为空!");
        }
        WlyyHospitalSysDictDO hospitalSysDictDO = hospitalSysDictDao.findByHospitalAndDictCode("doctorType",doctorDO.getJobTitleName());
        Double register = outpatientDO.getFee();
        Double drugFee= 0.0;
        List<WlyyPrescriptionDO> wlyyPrescriptionDOS = prescriptionDao.findByOutPatientIdList(outpatientId);
        List<String> list = new ArrayList<>();
        for (WlyyPrescriptionDO wlyyPrescriptionDO:wlyyPrescriptionDOS){
            drugFee +=wlyyPrescriptionDO.getDrugFee();
            if (list!=null&&list.size()!=0&&!list.contains(wlyyPrescriptionDO.getRealOrder())){
                list.add(wlyyPrescriptionDO.getRealOrder());
            }
        }
        data.put("region_code","350200");//参保地区划代码
        data.put("name",outpatientDO.getPatientName());//姓名
        data.put("idcard",outpatientDO.getIdcard());//证件号码
        data.put("cert_type","01");//证件类型
        data.put("region_code",ylzMedicalRelationDO.getRegionCode());//参保地区划代码
        data.put("name",ylzMedicalRelationDO.getName());//姓名
        data.put("idcard",ylzMedicalRelationDO.getIdcard());//证件号码
        data.put("cert_type",ylzMedicalRelationDO.getCertType());//证件类型
        data.put("medical_mode",ylzMedicalRelationDO.getMedicalMode());//医疗就诊方式
        data.put("medical_type",ylzMedicalRelationDO.getMedicalType());//医疗类别
        data.put("insurance_serial",ylzMedicalRelationDO.getInsuranceSerial());//
        data.put("his_bill_serial",ylzMedicalRelationDO.getHisBillSerial());//his收费单据流水号
        data.put("date",ylzMedicalRelationDO.getDate());//实际就诊日期
        data.put("leave_method","09");//离院方式
        data.put("pre_count",list.size());//处方项目数
        data.put("pre_count",ylzMedicalRelationDO.getPreCount());//处方项目数
        data.put("total_amount",ylzMedicalRelationDO.getTotalAmount());//医疗费总金额
        data.put("person_cash",ylzMedicalRelationDO.getPersonCash());//个人现金支付金额(实付现金)
        data.put("person_account",ylzMedicalRelationDO.getPersonAccount());//个人账户支付金额
        data.put("fund_price",ylzMedicalRelationDO.getFundPrice());//基金支付总额
        data.put("data_source","53");//数据来源
        data.put("his_serial",outpatientDO.getRegisterNo());//his流水号
        if (hospitalSysDictDO==null){
            data.put("doctor_level","03");//医师诊查费等级
        }else {
            data.put("doctor_level",hospitalSysDictDO.getDictValue());//医师诊查费等级
        }
        data.put("data_source",ylzMedicalRelationDO.getDataSource());//数据来源
        data.put("his_serial",ylzMedicalRelationDO.getHisSerial());//his流水号
        data.put("doctor_level",ylzMedicalRelationDO.getDoctorLevel());//医师诊查费等级
        data.put("redirect_url",wlyyHospitalSysDictDO.getDictValue());//回调地址
        String result = requestYlz(data,funid,"获取医保结算结果");
        if (result==null){

+ 19 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/healthCare/YlzMedicailIcdDao.java

@ -0,0 +1,19 @@
package com.yihu.jw.hospital.healthCare;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalIcdDO;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalRelationDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
import java.util.List;
/**
 * Created by wangzhinan 20211003
 */
public interface YlzMedicailIcdDao extends PagingAndSortingRepository<YlzMedicalIcdDO, String>, JpaSpecificationExecutor<YlzMedicalIcdDO> {
    @Query("from YlzMedicalIcdDO a where a.medicalId = ?1 ")
    List<YlzMedicalIcdDO> findByMedicalId(String medicalId);
}

+ 19 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/healthCare/YlzMedicailMxDao.java

@ -0,0 +1,19 @@
package com.yihu.jw.hospital.healthCare;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalIcdDO;
import com.yihu.jw.entity.hospital.healthCare.YlzMedicalMxDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
import java.util.List;
/**
 * Created by wangzhinan 20211003
 */
public interface YlzMedicailMxDao extends PagingAndSortingRepository<YlzMedicalMxDO, String>, JpaSpecificationExecutor<YlzMedicalMxDO> {
    @Query("from YlzMedicalMxDO a where a.medicalId = ?1 ")
    List<YlzMedicalMxDO> findByMedicalId(String medicalId);
}

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

@ -2197,6 +2197,47 @@ public class XzzxEntranceService{
        return "-2";
    }
//=====医保===================================
    /**
     * 2.1.1	获取患者结算信息
     * @return
     */
    public String getSettleInfo(String icCardNo,String his_serial,String org_code)throws Exception{
        String api = "getSettleInfo";
        String msgHeader ="<?xml version=\"1.0\" encoding=\"utf-8\"?> " +
                "<root> " +
                "   <serverName>"+api+"</serverName>  " +
                "   <format>xml</format>" +
                "   <callOperator></callOperator> " +
                "   <certificate>"+key+"</certificate> " +
                "</root>";
        String condition ="";
        if (!StringUtils.isEmpty(icCardNo)){
            condition += "<icCardNo>"+icCardNo+"</icCardNo>";
        }
        if (!StringUtils.isEmpty(his_serial)){
            condition += "<his_serial>"+his_serial+"</his_serial>";
        }
        if (!StringUtils.isEmpty(org_code)){
            condition += "<org_code>"+org_code+"</org_code>";
        }
        String msgBody ="<?xml version=\"1.0\" encoding=\"utf-8\"?>" +
                "<root>"+condition+"</root>";
        Map<String,String> params = new HashedMap();
        params.put("msgHeader",msgHeader);
        params.put("msgBody",msgBody);
        logger.info("getSettleInfo params:"+params.toString());
        String xml = getXzzxWebServiceInfo("CallInterface",params,getSelectUrl());
        XMLSerializer xmlSerializer = new XMLSerializer();
        String json = xmlSerializer.read(xml).toString();
        JSONObject object = JSONObject.parseObject(json);
        logger.info("getSettleInfo json:"+xml);
        return xml;
    }

+ 82 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/healthCare/YlzMedicalIcdDO.java

@ -0,0 +1,82 @@
package com.yihu.jw.entity.hospital.healthCare;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by wangzhinan on 20211003
 */
@Entity
@Table(name = "base_ylz_medical_icd")
public class YlzMedicalIcdDO extends UuidIdentityEntity {
    private String medicalId;
    private String diseaseCodeIcd10;
    private String diseaseNameIcd10;
    private String diseaseType;
    private String diseaseOrder;
    private String del;
    private Date createTime;
    public String getMedicalId() {
        return medicalId;
    }
    public void setMedicalId(String medicalId) {
        this.medicalId = medicalId;
    }
    public String getDiseaseCodeIcd10() {
        return diseaseCodeIcd10;
    }
    public void setDiseaseCodeIcd10(String diseaseCodeIcd10) {
        this.diseaseCodeIcd10 = diseaseCodeIcd10;
    }
    public String getDiseaseNameIcd10() {
        return diseaseNameIcd10;
    }
    public void setDiseaseNameIcd10(String diseaseNameIcd10) {
        this.diseaseNameIcd10 = diseaseNameIcd10;
    }
    public String getDiseaseType() {
        return diseaseType;
    }
    public void setDiseaseType(String diseaseType) {
        this.diseaseType = diseaseType;
    }
    public String getDiseaseOrder() {
        return diseaseOrder;
    }
    public void setDiseaseOrder(String diseaseOrder) {
        this.diseaseOrder = diseaseOrder;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    @Column(name="create_time")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}

+ 304 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/healthCare/YlzMedicalMxDO.java

@ -0,0 +1,304 @@
package com.yihu.jw.entity.hospital.healthCare;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by wangzhinan on 20211003
 */
@Entity
@Table(name = "base_ylz_medical_mx")
public class YlzMedicalMxDO extends UuidIdentityEntity {
    private String medicalId;
    private String prescriptionCode;
    private String hisDetailSn;
    private String itemName;
    private String itemCode;
    private String invoiceType;
    private String specificationType;
    private String dosageForm;
    private String chargeUnit;
    private String price;
    private String amount;
    private String totalMoney;
    private String singleDose;
    private String useFrequency;
    private String medicalWay;
    private Date prescriptionDate;
    private String medicationDays;
    private String deptCode;
    private String deptName;
    private String hisDeptCode;
    private String hisDeptName;
    private String medicalPerName;
    private String medicalPerId;
    private String limitType;
    private Date actgDate;
    private String hisItemName;
    private String hisItemCode;
    private Date clerkDays;
    private String peopleType;
    private String del;
    private Date createTime;
    public String getMedicalId() {
        return medicalId;
    }
    public void setMedicalId(String medicalId) {
        this.medicalId = medicalId;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    @Column(name="create_time")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public String getPrescriptionCode() {
        return prescriptionCode;
    }
    public void setPrescriptionCode(String prescriptionCode) {
        this.prescriptionCode = prescriptionCode;
    }
    public String getHisDetailSn() {
        return hisDetailSn;
    }
    public void setHisDetailSn(String hisDetailSn) {
        this.hisDetailSn = hisDetailSn;
    }
    public String getItemName() {
        return itemName;
    }
    public void setItemName(String itemName) {
        this.itemName = itemName;
    }
    public String getItemCode() {
        return itemCode;
    }
    public void setItemCode(String itemCode) {
        this.itemCode = itemCode;
    }
    public String getInvoiceType() {
        return invoiceType;
    }
    public void setInvoiceType(String invoiceType) {
        this.invoiceType = invoiceType;
    }
    public String getSpecificationType() {
        return specificationType;
    }
    public void setSpecificationType(String specificationType) {
        this.specificationType = specificationType;
    }
    public String getDosageForm() {
        return dosageForm;
    }
    public void setDosageForm(String dosageForm) {
        this.dosageForm = dosageForm;
    }
    public String getChargeUnit() {
        return chargeUnit;
    }
    public void setChargeUnit(String chargeUnit) {
        this.chargeUnit = chargeUnit;
    }
    public String getPrice() {
        return price;
    }
    public void setPrice(String price) {
        this.price = price;
    }
    public String getAmount() {
        return amount;
    }
    public void setAmount(String amount) {
        this.amount = amount;
    }
    public String getTotalMoney() {
        return totalMoney;
    }
    public void setTotalMoney(String totalMoney) {
        this.totalMoney = totalMoney;
    }
    public String getSingleDose() {
        return singleDose;
    }
    public void setSingleDose(String singleDose) {
        this.singleDose = singleDose;
    }
    public String getUseFrequency() {
        return useFrequency;
    }
    public void setUseFrequency(String useFrequency) {
        this.useFrequency = useFrequency;
    }
    public String getMedicalWay() {
        return medicalWay;
    }
    public void setMedicalWay(String medicalWay) {
        this.medicalWay = medicalWay;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    @Column(name="prescription_date")
    public Date getPrescriptionDate() {
        return prescriptionDate;
    }
    public void setPrescriptionDate(Date prescriptionDate) {
        this.prescriptionDate = prescriptionDate;
    }
    public String getMedicationDays() {
        return medicationDays;
    }
    public void setMedicationDays(String medicationDays) {
        this.medicationDays = medicationDays;
    }
    public String getDeptCode() {
        return deptCode;
    }
    public void setDeptCode(String deptCode) {
        this.deptCode = deptCode;
    }
    public String getDeptName() {
        return deptName;
    }
    public void setDeptName(String deptName) {
        this.deptName = deptName;
    }
    public String getHisDeptCode() {
        return hisDeptCode;
    }
    public void setHisDeptCode(String hisDeptCode) {
        this.hisDeptCode = hisDeptCode;
    }
    public String getHisDeptName() {
        return hisDeptName;
    }
    public void setHisDeptName(String hisDeptName) {
        this.hisDeptName = hisDeptName;
    }
    public String getMedicalPerName() {
        return medicalPerName;
    }
    public void setMedicalPerName(String medicalPerName) {
        this.medicalPerName = medicalPerName;
    }
    public String getMedicalPerId() {
        return medicalPerId;
    }
    public void setMedicalPerId(String medicalPerId) {
        this.medicalPerId = medicalPerId;
    }
    public String getLimitType() {
        return limitType;
    }
    public void setLimitType(String limitType) {
        this.limitType = limitType;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    @Column(name="actg_date")
    public Date getActgDate() {
        return actgDate;
    }
    public void setActgDate(Date actgDate) {
        this.actgDate = actgDate;
    }
    public String getHisItemName() {
        return hisItemName;
    }
    public void setHisItemName(String hisItemName) {
        this.hisItemName = hisItemName;
    }
    public String getHisItemCode() {
        return hisItemCode;
    }
    public void setHisItemCode(String hisItemCode) {
        this.hisItemCode = hisItemCode;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    @Column(name="clerk_days")
    public Date getClerkDays() {
        return clerkDays;
    }
    public void setClerkDays(Date clerkDays) {
        this.clerkDays = clerkDays;
    }
    public String getPeopleType() {
        return peopleType;
    }
    public void setPeopleType(String peopleType) {
        this.peopleType = peopleType;
    }
}

+ 172 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/healthCare/YlzMedicalRelationDO.java

@ -40,7 +40,34 @@ public class YlzMedicalRelationDO extends UuidIdentityEntity {
    private String invoiceJj;//发票打印基金应支付
    private String invoiceXj;//发票打印现金应支付
    private String invoiceZh;//发票打印账户应支付
    private String logNo;//系统跟踪号
    private String orgCode;//医院编码
    private String regionCode;//参保地区划代码
    private String idcard;//证件号码
    private String certType;//证件类型
    private String hisSerial;//his流水号
    private String hisSettleNo;//his結算流水号
    private String deptCode;//标准科室编码
    private String deptName;//标准科室名称
    private String hisDeptCode;//his内部科室编码
    private String hisDeptName;//his内部科室名称
    private String emergencySign;//急诊标志
    private String traumaSign;//外伤标志
    private String itemCount;//明细项目数量
    private String preCharges;//预扣费金额
    private String dataSource;//数据来源
    private String preCount;//处方项目数
    private String doctorLevel;//医师诊察费等级
    private Date createTime;//创建时间',
    private String detailSerial;//医保明细流水号
    public String getDetailSerial() {
        return detailSerial;
    }
    public void setDetailSerial(String detailSerial) {
        this.detailSerial = detailSerial;
    }
    public String getInsuranceSerial() {
        return insuranceSerial;
@ -256,4 +283,149 @@ public class YlzMedicalRelationDO extends UuidIdentityEntity {
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public String getLogNo() {
        return logNo;
    }
    public void setLogNo(String logNo) {
        this.logNo = logNo;
    }
    public String getOrgCode() {
        return orgCode;
    }
    public void setOrgCode(String orgCode) {
        this.orgCode = orgCode;
    }
    public String getRegionCode() {
        return regionCode;
    }
    public void setRegionCode(String regionCode) {
        this.regionCode = regionCode;
    }
    public String getIdcard() {
        return idcard;
    }
    public void setIdcard(String idcard) {
        this.idcard = idcard;
    }
    public String getCertType() {
        return certType;
    }
    public void setCertType(String certType) {
        this.certType = certType;
    }
    public String getHisSerial() {
        return hisSerial;
    }
    public void setHisSerial(String hisSerial) {
        this.hisSerial = hisSerial;
    }
    public String getHisSettleNo() {
        return hisSettleNo;
    }
    public void setHisSettleNo(String hisSettleNo) {
        this.hisSettleNo = hisSettleNo;
    }
    public String getDeptCode() {
        return deptCode;
    }
    public void setDeptCode(String deptCode) {
        this.deptCode = deptCode;
    }
    public String getDeptName() {
        return deptName;
    }
    public void setDeptName(String deptName) {
        this.deptName = deptName;
    }
    public String getHisDeptCode() {
        return hisDeptCode;
    }
    public void setHisDeptCode(String hisDeptCode) {
        this.hisDeptCode = hisDeptCode;
    }
    public String getHisDeptName() {
        return hisDeptName;
    }
    public void setHisDeptName(String hisDeptName) {
        this.hisDeptName = hisDeptName;
    }
    public String getEmergencySign() {
        return emergencySign;
    }
    public void setEmergencySign(String emergencySign) {
        this.emergencySign = emergencySign;
    }
    public String getTraumaSign() {
        return traumaSign;
    }
    public void setTraumaSign(String traumaSign) {
        this.traumaSign = traumaSign;
    }
    public String getItemCount() {
        return itemCount;
    }
    public void setItemCount(String itemCount) {
        this.itemCount = itemCount;
    }
    public String getPreCharges() {
        return preCharges;
    }
    public void setPreCharges(String preCharges) {
        this.preCharges = preCharges;
    }
    public String getDataSource() {
        return dataSource;
    }
    public void setDataSource(String dataSource) {
        this.dataSource = dataSource;
    }
    public String getPreCount() {
        return preCount;
    }
    public void setPreCount(String preCount) {
        this.preCount = preCount;
    }
    public String getDoctorLevel() {
        return doctorLevel;
    }
    public void setDoctorLevel(String doctorLevel) {
        this.doctorLevel = doctorLevel;
    }
}