湖里妇幼都转成字符串上传

hlfyyy
qiuyt 3 months ago
parent 8de7758e99
commit 728b494350

@ -20,6 +20,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.StringUtils;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fasterxml.jackson.databind.JsonNode;
import com.glxp.mipsdl.client.CommonHttpClient;
import com.glxp.mipsdl.client.hlfyyy.entity.InvCodeResultEntity;
@ -2394,6 +2395,12 @@ public class HlfyyyClient extends CommonHttpClient {
private static final String WSDL_URL = "http://192.168.158.208:8152/ZoesoftHipService.asmx?WSDL";
public BaseResponse callInterface(String msgHeader, String msgBody) {
// 先将JSON字符串转为Map
Map<String, Object> map = JSONUtil.toBean(msgBody, Map.class);
// 遍历Map将所有值转换为字符串
map.replaceAll((key, value) -> value == null? null : value.toString());
// 再将转换后的Map转回JSON字符串此时所有值都已是字符串类型
msgBody = JSONUtil.toJsonStr(map);
String xml = "\n" +
"<soap:Envelope\n" +
" xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\"\n" +

Loading…
Cancel
Save