提交 a78a2767 authored 作者: 刘涛's avatar 刘涛

修改日志格式

上级 b4a53020
...@@ -31,6 +31,8 @@ public class ImsLogUtil { ...@@ -31,6 +31,8 @@ public class ImsLogUtil {
public Boolean ImsLog(String request,String result,String name,String code){ public Boolean ImsLog(String request,String result,String name,String code){
Imslog imslog=new Imslog(); Imslog imslog=new Imslog();
Boolean flag=false; Boolean flag=false;
Object message = "";
Object success ="";
//将返回结果转成JSON //将返回结果转成JSON
String s = XmlUtil.xmltoJson(result); String s = XmlUtil.xmltoJson(result);
//逐步拆分出对应的信息 //逐步拆分出对应的信息
...@@ -38,13 +40,18 @@ public class ImsLogUtil { ...@@ -38,13 +40,18 @@ public class ImsLogUtil {
Object o = maps.get("SOAP-ENV:Body"); Object o = maps.get("SOAP-ENV:Body");
Map map1 = (Map)JSON.parse(o.toString()); Map map1 = (Map)JSON.parse(o.toString());
Object o1 = map1.get("NS1:updateIMSDataResponse"); Object o1 = map1.get("NS1:updateIMSDataResponse");
Map map2 = (Map)JSON.parse(o1.toString()); if(null!=o1){
Object msg = map2.get("ResultMsg"); Map map2 = (Map)JSON.parse(o1.toString());
Map map3 = (Map)JSON.parse(msg.toString()); Object msg = map2.get("ResultMsg");
Object aReturn = map2.get("return"); Map map3 = (Map)JSON.parse(msg.toString());
Map map4 = (Map)JSON.parse(aReturn.toString()); Object aReturn = map2.get("return");
Object message = map3.get("#text"); Map map4 = (Map)JSON.parse(aReturn.toString());
Object success = map4.get("#text"); message = map3.get("#text");
success = map4.get("#text");
}else {
message = "用户信息为空";
success ="false";
}
//设置日志信息 //设置日志信息
imslog.setName(name); imslog.setName(name);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论