Parcourir la source

Merge branch 'dev' of huangwenjie/patient-co-management into dev

yeshijie il y a 7 ans
Parent
commit
0779c27d8b

+ 17 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/PrescriptionController.java

@ -339,6 +339,23 @@ public class PrescriptionController extends BaseController{
			return Result.error(ex.getMessage());
		}
	}
	
	@RequestMapping(value = "getZyDataStatus",method = RequestMethod.POST)
	@ApiOperation("获取基卫处方的相关数据状态")
	public Result getZyDataStatus(@ApiParam(name="type",value="数据类型:1:挂号数据;2:处方数据;3:结算数据",defaultValue = "")
	                            @RequestParam(value = "type",required = true) String type,
	                            @ApiParam(name="jwid",value="基卫处方ID",defaultValue = "")
	                            @RequestParam(value = "jwid",required = true) String jwid,
	                            @ApiParam(name="hosipital",value="基卫机构编码",defaultValue = "")
	                            @RequestParam(value = "hosipital",required = true) String hosipital){
		try {
			String re = prescriptionService.getZyDataStatus(type,jwid,hosipital);
			return Result.success("查询成功!",re);
		} catch (Exception ex) {
			ex.printStackTrace();
			return Result.error(ex.getMessage());
		}
	}
	/************************************ CA认证 ************************************************************/
	@RequestMapping(value = "RequestRealNameSoftCertAndSign",method = RequestMethod.POST)

+ 24 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionService.java

@ -1178,4 +1178,28 @@ public class PrescriptionService extends ZysoftBaseService{
    
        return response;
    }
    
    /**
     * 获取基卫处方的相关数据状态
     * @param type
     * @param jwid
     * @param hosipital
     * @return
     */
    public String getZyDataStatus(String type, String jwid, String hosipital)  throws Exception{
        String[] hospitalMapping = getHospitalMapping(hosipital); //获取机构映射
        String hospital = hospitalMapping[0];
        String licence = hospitalMapping[1];
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
    
        Map<String,String> params = new HashMap<>();
        params.put("type",type);
        params.put("id",jwid);
    
        String response = postSecond("getDataStatus","获取基卫处方的相关数据状态",params,null,header,false,2,"2");
    
        return response;
    }
}

+ 4 - 4
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/consult/ConsultTeamService.java

@ -1151,15 +1151,15 @@ public class ConsultTeamService extends ConsultService {
            followup.setIdcard(patientObj.getIdcard());
            
            if(3 == type){
                followup.setFollowupType("1,2");
                followup.setFollowupClass("1,2");
            }else{
                followup.setFollowupType(String.valueOf(type));
                followup.setFollowupClass(String.valueOf(type));
            }
            
            if(2 == doctor.getLevel()){//全科
                followup.setFollowupClass("22");
                followup.setFollowupType("22");
            }else if(3 == doctor.getLevel()){//健管
                followup.setFollowupClass("10");
                followup.setFollowupType("10");
            }
            followup.setDataFrom("2");//数据来源 1基卫 2APP
            followup.setStatus("2");     //状态 0取消 1已完成 2未开始 3进行中

+ 4 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/prescription/PrescriptionInfoService.java

@ -4,6 +4,7 @@ import com.yihu.wlyy.adapter.PresModeAdapter;
import com.yihu.wlyy.entity.dict.SystemDict;
import com.yihu.wlyy.entity.doctor.profile.Doctor;
import com.yihu.wlyy.entity.doctor.team.admin.AdminTeam;
import com.yihu.wlyy.entity.followup.Followup;
import com.yihu.wlyy.entity.patient.Patient;
import com.yihu.wlyy.entity.patient.SignFamily;
import com.yihu.wlyy.entity.patient.prescription.*;
@ -495,6 +496,8 @@ public class PrescriptionInfoService extends BaseService {
        Patient p = patientDao.findByCode(patient);
        String rs = jwPrescriptionService.getRecipe(code, p.getSsc());
        com.alibaba.fastjson.JSONObject r = presModeAdapter.modelToSinglePrescription(rs);
    
        Followup followup = followUpDao.getFollowupByPrescriptionCode(code);
        String rState = presCheckStateObj(code);
        if ("1".equals(rState)) {
            r.put("reviewedState", 1);
@ -503,6 +506,7 @@ public class PrescriptionInfoService extends BaseService {
            r.put("reviewedState", 0);
            r.put("prescriptionCode", rState);
        }
        r.put("followup",followup);
        return r;
    }