|
@ -27,6 +27,7 @@ import com.yihu.jw.hospital.prescription.dao.OutpatientDao;
|
|
|
import com.yihu.jw.hospital.prescription.dao.PrescriptionDao;
|
|
|
import com.yihu.jw.hospital.prescription.dao.PrescriptionExpressageDao;
|
|
|
import com.yihu.jw.hospital.prescription.dao.PrescriptionInfoDao;
|
|
|
import com.yihu.jw.hospital.prescription.service.entrance.XzzxEntranceService;
|
|
|
import com.yihu.jw.patient.dao.BasePatientDao;
|
|
|
import com.yihu.jw.util.common.LatitudeUtils;
|
|
|
import com.yihu.jw.util.date.DateUtil;
|
|
@ -87,6 +88,8 @@ public class HealthCareService {
|
|
|
private YlzMedicailIcdDao ylzMedicailIcdDao;
|
|
|
@Autowired
|
|
|
private YlzMedicailMxDao ylzMedicailMxDao;
|
|
|
@Autowired
|
|
|
private XzzxEntranceService xzzxEntranceService;
|
|
|
|
|
|
private String ylzConfigUrl;
|
|
|
private String ylzConfigAppid;
|
|
@ -95,7 +98,7 @@ public class HealthCareService {
|
|
|
private String ylzConfigSignKey;
|
|
|
private String ylzConfigOrgCode;
|
|
|
|
|
|
public static String entranceUrl = "http://172.16.100.240:10023/xzzx/";
|
|
|
public static String entranceHealthCareUrl = "http://172.16.100.240:10023/healthCare/";
|
|
|
|
|
|
|
|
|
public void initConfig() throws Exception{
|
|
@ -307,19 +310,12 @@ public class HealthCareService {
|
|
|
|
|
|
JSONObject data;
|
|
|
//获取his处方信息
|
|
|
String presUploadUrl = entranceUrl + "presUpload?icCardNo="+icCardNo+"&his_serial="+his_serial+"&org_code="+org_code;
|
|
|
String infoResponse = httpClientUtil.get(presUploadUrl,"GBK");
|
|
|
logger.info("处方infoResponse:"+infoResponse);
|
|
|
String infoResponse = xzzxEntranceService.presUpload(icCardNo,his_serial,org_code);
|
|
|
JSONObject infoObject = JSONObject.parseObject(infoResponse);
|
|
|
if (infoObject.getString("status").equalsIgnoreCase("200")) {
|
|
|
JSONObject obj = infoObject.getJSONObject("obj");
|
|
|
if("0".equals(obj.getString("ret_code"))){
|
|
|
data = obj;
|
|
|
}else {
|
|
|
throw new Exception("获取his处方信息失败:"+obj.getString("ret_mess"));
|
|
|
}
|
|
|
if("0".equals(infoObject.getString("ret_code"))){
|
|
|
data = infoObject;
|
|
|
}else {
|
|
|
throw new Exception("获取his处方信息失败");
|
|
|
throw new Exception("获取his处方信息失败:"+infoObject.getString("ret_mess"));
|
|
|
}
|
|
|
|
|
|
data.remove("ret_code");
|
|
@ -369,19 +365,12 @@ public class HealthCareService {
|
|
|
|
|
|
JSONObject data;
|
|
|
//获取his处方信息
|
|
|
String presUploadUrl = entranceUrl + "presUpload?icCardNo="+icCardNo+"&his_serial="+his_serial+"&org_code="+org_code;
|
|
|
String infoResponse = httpClientUtil.get(presUploadUrl,"GBK");
|
|
|
logger.info("处方infoResponse:"+infoResponse);
|
|
|
String infoResponse = xzzxEntranceService.presUpload(icCardNo,his_serial,org_code);
|
|
|
JSONObject infoObject = JSONObject.parseObject(infoResponse);
|
|
|
if (infoObject.getString("status").equalsIgnoreCase("200")) {
|
|
|
JSONObject obj = infoObject.getJSONObject("obj");
|
|
|
if("0".equals(obj.getString("ret_code"))){
|
|
|
data = obj;
|
|
|
}else {
|
|
|
throw new Exception("获取his处方信息失败:"+obj.getString("ret_mess"));
|
|
|
}
|
|
|
if("0".equals(infoObject.getString("ret_code"))){
|
|
|
data = infoObject;
|
|
|
}else {
|
|
|
throw new Exception("获取his处方信息失败");
|
|
|
throw new Exception("获取his处方信息失败:"+infoObject.getString("ret_mess"));
|
|
|
}
|
|
|
|
|
|
data.remove("ret_code");
|