Commit 1cfeee1f authored by hongguangwu's avatar hongguangwu

Merge branch 'MVP1.6.4' into develop

parents 2e837662 5b9f4544
......@@ -30,6 +30,7 @@ import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.security.MessageDigest;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.TimeUnit;
......@@ -175,9 +176,16 @@ public class SocialConfig {
if (!"200".equals(code)) {
throw new CheckedException("获取社保士兵【可执行的设备接口】失败,code="+code);
}
JSONArray dataArr = (JSONArray) bodyObject.get("data");
if (dataArr != null && !dataArr.isEmpty()) {
terminalId = ((JSONObject)dataArr.get(0)).getString("value");
List<HashMap> dataList = JSON.parseArray(bodyObject.getString("data"), HashMap.class);
String label;
if (dataList != null && !dataList.isEmpty()) {
for (HashMap data : dataList) {
terminalId = String.valueOf(data.get("value"));
label = String.valueOf(data.get("label"));
if (Common.isNotNull(label) && label.contains("空闲")) {
break;
}
}
}
}
if (Common.isEmpty(terminalId)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment