人员修改
This commit is contained in:
parent
ccdc9ca8ab
commit
f39abe1c86
@ -267,7 +267,7 @@ public class XzWorkerInfoAuditRecordController {
|
||||
if (i > 0) {
|
||||
builder.append(",");
|
||||
}
|
||||
builder.append(contract.getJSONObject(i).getString("name") + "*" + object.getJSONArray("contract").getJSONObject(0).getString("url"));
|
||||
builder.append(contract.getJSONObject(i).getString("name") + "*" + contract.getJSONObject(i).getString("url"));
|
||||
}
|
||||
WorkerContract workerContract = new WorkerContract();
|
||||
workerContract.setImageUrl(builder.toString());
|
||||
@ -282,10 +282,11 @@ public class XzWorkerInfoAuditRecordController {
|
||||
if (i > 0) {
|
||||
builder.append(",");
|
||||
}
|
||||
builder.append(insurance.getJSONObject(i).getString("name") + "*" + object.getJSONArray("insurance").getJSONObject(0).getString("url"));
|
||||
builder.append(insurance.getJSONObject(i).getString("name") + "*" + insurance.getJSONObject(i).getString("url"));
|
||||
}
|
||||
WorkerInsurance workerInsurance = new WorkerInsurance();
|
||||
workerInsurance.setPhotoUrl(builder.toString());
|
||||
insuranceList.add(workerInsurance);
|
||||
}
|
||||
infoAuditRecord.setInsuranceInfo(JSON.toJSONString(insuranceList));
|
||||
List<WorkerCertificate> certificateList = new ArrayList<>();
|
||||
@ -295,13 +296,21 @@ public class XzWorkerInfoAuditRecordController {
|
||||
WorkerCertificate workerCertificate = new WorkerCertificate();
|
||||
JSONObject jsonObject = certificate.getJSONObject(i);
|
||||
for (String s : jsonObject.keySet()) {
|
||||
Object o1 = jsonObject.getJSONArray(s).get(0);
|
||||
if (o1 instanceof JSONObject) {
|
||||
System.out.println("====json");
|
||||
workerCertificate.setPhotoUrl(jsonObject.getJSONArray(s).getJSONObject(0).getString("name") + "*" + jsonObject.getJSONArray(s).getJSONObject(0).getString("url"));
|
||||
} else {
|
||||
System.out.println("====number");
|
||||
workerCertificate.setCertificateType(Integer.parseInt(jsonObject.getJSONArray(s).get(0).toString()));
|
||||
JSONArray o1 = jsonObject.getJSONArray(s);
|
||||
StringBuilder phoneUrl = new StringBuilder();
|
||||
for (int j = 0; j < o1.size(); j++) {
|
||||
if (o1.get(j) instanceof JSONObject) {
|
||||
if (i > 0) {
|
||||
phoneUrl.append(",");
|
||||
}
|
||||
JSONObject object1 = JSONObject.parseObject(JSON.toJSONString(o1.get(j)));
|
||||
phoneUrl.append(object1.getString("name") + "*" + object1.getString("url"));
|
||||
} else {
|
||||
workerCertificate.setCertificateType(Integer.parseInt(o1.get(j).toString()));
|
||||
}
|
||||
}
|
||||
if (phoneUrl.length() > 0) {
|
||||
workerCertificate.setPhotoUrl(phoneUrl.toString());
|
||||
}
|
||||
}
|
||||
certificateList.add(workerCertificate);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user