长泰医保上传

jydyyy
qiuyt 4 months ago
parent ee59644756
commit b09691c5c6

@ -2194,13 +2194,13 @@ public class CtqyyClient extends CommonHttpClient {
// TODO: 2024/9/10 字段未完全正确对应
Kcbg3502Request kcbg3502Request = Kcbg3502Request.builder()
.med_list_codg(item.getYbbm())
.inv_chg_type("test")
.inv_chg_type("108")
.fixmedins_hilist_id(item.getThrCode())
.fixmedins_hilist_name(item.getCpmctymc())
.fixmedins_bchno("test")
.pric("1.11")
.fixmedins_bchno("0000")
.pric("0")
.cnt(item.getActCount())
.rx_flag("test")
.rx_flag("1")
.inv_chg_time(item.getUpdateTime())
.inv_chg_opter_name(ioCollectOrder.getCreateUser())
.memo(item.getRemark())
@ -2211,7 +2211,7 @@ public class CtqyyClient extends CommonHttpClient {
}
}
BaseKcbg3502Request baseKcbg3502Request = new BaseKcbg3502Request();
baseKcbg3502Request.setSelinfoDetail(kcbg3502Requests);
baseKcbg3502Request.setInvinfoDetail(kcbg3502Requests);
String jsonStr = JSONUtil.toJsonStr(baseKcbg3502Request);
JSONObject dataJson = JSONObject.parseObject(jsonStr);
return ybClient.ybPost("3502A", dataJson);

@ -6,13 +6,10 @@ import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.ReflectUtil;
import cn.hutool.core.util.StrUtil;
import cn.hutool.json.JSONConfig;
import cn.hutool.json.JSONUtil;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.TypeReference;
import com.alibaba.fastjson.serializer.SerializeConfig;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
@ -1978,7 +1975,7 @@ public class ScpwxyyClient extends CommonHttpClient {
}
}
BaseKcbg3502Request baseKcbg3502Request = new BaseKcbg3502Request();
baseKcbg3502Request.setSelinfoDetail(kcbg3502Requests);
baseKcbg3502Request.setInvinfoDetail(kcbg3502Requests);
String jsonStr = JSONUtil.toJsonStr(baseKcbg3502Request);
JSONObject dataJson = JSONObject.parseObject(jsonStr);
ybClient.ybPostScyh("3502A", dataJson);

@ -1960,7 +1960,7 @@ public class YxfyyyClient extends CommonHttpClient {
}
}
BaseKcbg3502Request baseKcbg3502Request = new BaseKcbg3502Request();
baseKcbg3502Request.setSelinfoDetail(kcbg3502Requests);
baseKcbg3502Request.setInvinfoDetail(kcbg3502Requests);
String jsonStr = JSONUtil.toJsonStr(baseKcbg3502Request);
JSONObject dataJson = JSONObject.parseObject(jsonStr);
ybClient.ybPost("3502A", dataJson);

@ -6,5 +6,5 @@ import java.util.List;
@Data
public class BaseKcbg3502Request {
private List<Kcbg3502Request> selinfoDetail;
private List<Kcbg3502Request> invinfoDetail;
}

@ -49,7 +49,7 @@ public class YbClient {
*/
public BaseResponse ybPost(String apiNo, JSONObject data) {
log.info("[" + apiNo + "]医保接口请求参数:" + data);
// log.info("[" + apiNo + "]医保接口请求参数:" + data);
ThrYbSetup thrYbSetup = thrYbSetupService.getSetUp();
if (thrYbSetup == null)
throw new RuntimeException("未配置医保接口");
@ -76,7 +76,20 @@ public class YbClient {
req.setInput(data);
req.setSignNo(thrYbSetup.getSignNo());
log.info("【" + apiNo + "】医保接口请求参数:" + JSONObject.toJSONString(req));
return ResultVOUtils.success("【" + apiNo + "】上传医保成功");
ChsMedicalResponse resp = client.execute(req);
log.info("【" + apiNo + "】医保接口返回结果:" + JSONObject.toJSONString(resp));
if(resp.getIsSuccess() == true
&& org.apache.commons.lang3.StringUtils.isNotEmpty(resp.getAppid())
&& "0".equals(resp.getInfCode())
&& org.apache.commons.lang3.StringUtils.isEmpty(resp.getErrMsg())
){
return ResultVOUtils.success("【" + apiNo + "】上传医保成功");
}
return ResultVOUtils.success("【" + apiNo + "】上传医保失败==="+resp.getErrMsg());
} catch (Exception e) {
return ResultVOUtils.success("【" + apiNo + "】上传医保失败"+e.getMessage());
}

Loading…
Cancel
Save