|
@@ -167,20 +167,16 @@ public class POPomainController implements ApplicationContextAware {
|
|
|
//调用doPost
|
|
|
InterfaceConnUtils interfaceConnUtils = new InterfaceConnUtils();
|
|
|
//处理返回信息
|
|
|
- String informationJson = interfaceConnUtils.doPostToBearer(result, url,tokenUrl, "采购订单接口-");
|
|
|
- String jsonString = StringEscapeUtils.unescapeJava(informationJson);
|
|
|
- JSONObject jsonArr = JSONObject.parseObject(jsonString);
|
|
|
- JSONArray jsonArray = jsonArr.getJSONArray("payload");
|
|
|
+ JSONObject informationJson = interfaceConnUtils.doPostToBearer(result, url,tokenUrl, "采购订单接口-");
|
|
|
+ JSONObject jsonArray = informationJson.getJSONObject("payload");
|
|
|
+// String jsonString = StringEscapeUtils.unescapeJava(jsonArray1.toJSONString());
|
|
|
+// JSONObject jsonArr = JSONObject.parseObject(jsonString);
|
|
|
|
|
|
- log.info("payload数据:" + jsonArray);
|
|
|
-
|
|
|
-
|
|
|
- if (jsonArray.size() != 0) {
|
|
|
//获取4个账套值
|
|
|
String yi = "";
|
|
|
String er = "";
|
|
|
String san = "";
|
|
|
- String si = "";
|
|
|
+
|
|
|
for (String str : pkorgSplit) {
|
|
|
String pkorgStr = str;
|
|
|
String pkorgValue[] = pkorgStr.split(":");
|
|
@@ -195,9 +191,7 @@ public class POPomainController implements ApplicationContextAware {
|
|
|
}
|
|
|
}
|
|
|
//回写U8物料信息表是否同步成功字段
|
|
|
- Iterator<Object> it = jsonArray.iterator();
|
|
|
- while (it.hasNext()) {
|
|
|
- JSONObject jo = (JSONObject) it.next();
|
|
|
+ JSONObject jo = jsonArray;
|
|
|
//获取是否成功
|
|
|
String code = jo.getString("code");
|
|
|
//获取返回消息
|
|
@@ -247,8 +241,8 @@ public class POPomainController implements ApplicationContextAware {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- }
|
|
|
- }
|
|
|
+
|
|
|
+
|
|
|
//回写委外订单接口最后时间
|
|
|
Date datetome = sf.parse(beginTime);
|
|
|
dxpDataPlanService.updateLastTime(datetome, "senYu_poMain");
|