长泰上传处方单

phxyy
qiuyt 1 month ago
parent 07e2983e58
commit ad3eac8e0d

@ -83,7 +83,7 @@ public class CtqyyClient extends CommonHttpClient {
// 目前只有3502调通过上传医保 其他先不配置怕自动上传出问题 // 目前只有3502调通过上传医保 其他先不配置怕自动上传出问题
private final String[] buyType_3501 = {}; private final String[] buyType_3501 = {};
private final String[] buyType_3502 = {"SC72889572632899"}; private final String[] buyType_3502 = {"SC72889572632899"};
private final String[] buyType_3505 = {}; private final String[] buyType_3505 = {"QXCF001", "YPCF002"};
// private final String[] buyType_3505 = {"QXCF001", "YPCF002"}; // private final String[] buyType_3505 = {"QXCF001", "YPCF002"};
private final String[] buyType_3506 = {}; private final String[] buyType_3506 = {};
@ -1690,7 +1690,7 @@ public class CtqyyClient extends CommonHttpClient {
} else if (matchBusType(busType, buyType_3502)) { } else if (matchBusType(busType, buyType_3502)) {
return optionUploadCollectOrder3502(ioCollectOrder); return optionUploadCollectOrder3502(ioCollectOrder);
} else if (matchBusType(busType, buyType_3505)) { } else if (matchBusType(busType, buyType_3505)) {
optionUploadCollectOrder3505(ioCollectOrder); return optionUploadCollectOrder3505(ioCollectOrder);
} else if (matchBusType(busType, buyType_3506)) { } else if (matchBusType(busType, buyType_3506)) {
optionUploadCollectOrder3506(ioCollectOrder); optionUploadCollectOrder3506(ioCollectOrder);
} else { } else {
@ -2058,19 +2058,36 @@ public class CtqyyClient extends CommonHttpClient {
} }
public void optionUploadCollectOrder3505(IoCollectOrder ioCollectOrder) { public BaseResponse optionUploadCollectOrder3505(IoCollectOrder ioCollectOrder) {
//摆药流水号 //摆药流水号
String stoout_no = ioCollectOrder.getBackupOrderRemark1(); // String stoout_no = StringUtils.isNotEmpty(ioCollectOrder.getBackupOrderRemark1()) ? ioCollectOrder.getBackupOrderRemark1() :ioCollectOrder.getBackupOrderRemark2();
// log.error("stoout_no===",stoout_no);
List<VYpzsPresInfo> list = vYpzsPresInfoMapper
.selectList(
new QueryWrapper<VYpzsPresInfo>().eq("STOOUT_NO",ioCollectOrder.getBillNo())
);
if ( CollUtil.isNotEmpty(list)) {
String stoout_no = list.get(0).getSTOOUT_NO();
log.error("stoout_no==="+stoout_no);
List<VInsurNationGoodsPhysic> vInsurNationGoodsPhysics = goodsPhysicMapper.selectList(new LambdaQueryWrapper<VInsurNationGoodsPhysic>().eq(VInsurNationGoodsPhysic::getSTOOUT_NO, stoout_no)); List<VInsurNationGoodsPhysic> vInsurNationGoodsPhysics = goodsPhysicMapper.selectList(new LambdaQueryWrapper<VInsurNationGoodsPhysic>().eq(VInsurNationGoodsPhysic::getSTOOUT_NO, stoout_no));
log.error("vInsurNationGoodsPhysics==="+vInsurNationGoodsPhysics);
if ( CollUtil.isNotEmpty(vInsurNationGoodsPhysics)) { if ( CollUtil.isNotEmpty(vInsurNationGoodsPhysics)) {
List<CollectOrderBizResponse> collectOrderBizResponseList = ioCollectOrder.getCollectOrderBizResponseList(); List<CollectOrderBizResponse> collectOrderBizResponseList = ioCollectOrder.getCollectOrderBizResponseList();
log.error("collectOrderBizResponseList==="+collectOrderBizResponseList);
List<Xsck3505Request> xsck3505Requests = new ArrayList<>(); List<Xsck3505Request> xsck3505Requests = new ArrayList<>();
for (CollectOrderBizResponse collectOrderBizResponse : collectOrderBizResponseList) { for (CollectOrderBizResponse collectOrderBizResponse : collectOrderBizResponseList) {
BasicUdirelEntity basicUdirelEntity = basicUdirelDao.selectById(collectOrderBizResponse.getRelId()); BasicUdirelEntity basicUdirelEntity = basicUdirelDao.selectById(collectOrderBizResponse.getRelId());
String itemCode = basicUdirelEntity.getMainId(); String itemCode = basicUdirelEntity.getMainId();
for (VInsurNationGoodsPhysic vInsurNationGoodsPhysic : vInsurNationGoodsPhysics) { for (VInsurNationGoodsPhysic vInsurNationGoodsPhysic : vInsurNationGoodsPhysics) {
if (vInsurNationGoodsPhysic.getFIXMEDINS_HILIST_ID().equals(itemCode)) { if (vInsurNationGoodsPhysic.getMED_LIST_CODG().equals(itemCode)) {
String[] codes = collectOrderBizResponse.getFinishUdiCode().split(","); String[] codes = new String[0];
if(StringUtils.isNotEmpty(collectOrderBizResponse.getFinishUdiCode())){
codes = collectOrderBizResponse.getFinishUdiCode().split(",");
}
List<DrugInfoRequest> drugTraceList = new ArrayList<>(); List<DrugInfoRequest> drugTraceList = new ArrayList<>();
// 遍历fruits数组 // 遍历fruits数组
for (String code : codes) { for (String code : codes) {
@ -2086,6 +2103,8 @@ public class CtqyyClient extends CommonHttpClient {
} }
} }
} }
log.error("vInsurNationGoodsPhysic==="+vInsurNationGoodsPhysic);
Xsck3505Request xsck3505Request = Xsck3505Request.builder() Xsck3505Request xsck3505Request = Xsck3505Request.builder()
.med_list_codg(vInsurNationGoodsPhysic.getMED_LIST_CODG()) .med_list_codg(vInsurNationGoodsPhysic.getMED_LIST_CODG())
.fixmedins_hilist_id(vInsurNationGoodsPhysic.getFIXMEDINS_HILIST_ID()) .fixmedins_hilist_id(vInsurNationGoodsPhysic.getFIXMEDINS_HILIST_ID())
@ -2124,6 +2143,8 @@ public class CtqyyClient extends CommonHttpClient {
.memo(vInsurNationGoodsPhysic.getMEMO()) .memo(vInsurNationGoodsPhysic.getMEMO())
.mdtrt_setl_type(vInsurNationGoodsPhysic.getMDTRT_SETL_TYPE()) .mdtrt_setl_type(vInsurNationGoodsPhysic.getMDTRT_SETL_TYPE())
.drugtracinfo(drugTraceList).build(); .drugtracinfo(drugTraceList).build();
log.error("xsck3505Request==="+xsck3505Request);
xsck3505Requests.add(xsck3505Request); xsck3505Requests.add(xsck3505Request);
} }
} }
@ -2132,8 +2153,14 @@ public class CtqyyClient extends CommonHttpClient {
baseXsck3505Request.setSelinfoDetail(xsck3505Requests); baseXsck3505Request.setSelinfoDetail(xsck3505Requests);
String jsonStr = JSONUtil.toJsonStr(baseXsck3505Request); String jsonStr = JSONUtil.toJsonStr(baseXsck3505Request);
JSONObject dataJson = JSONObject.parseObject(jsonStr); JSONObject dataJson = JSONObject.parseObject(jsonStr);
ybClient.ybPost("3505A", dataJson); return ybClient.ybPost("3505A", dataJson);
}
}else {
return ResultVOUtils.error(500,"上传医保数据为空请核实");
} }
return ResultVOUtils.error(500,"上传医保数据为空请核实");
} }

Loading…
Cancel
Save