|
@@ -618,24 +618,26 @@ public class MESHelperServiceImpl implements MESHelperService {
|
|
|
Map<Object, Object> rmap = new HashMap<Object, Object>();
|
|
|
Map<String, Object> map=null;
|
|
|
JSONObject object = JSONObject.fromObject(data);
|
|
|
- JSONArray object1=object.getJSONArray("NonconformData");
|
|
|
+ Object object1 = object.get("data");
|
|
|
+ JSONObject obj = JSONObject.fromObject(object1);
|
|
|
+ JSONArray object2=obj.getJSONArray("NonconformData");
|
|
|
|
|
|
- Object Barcode=object.get("Barcode");
|
|
|
- Object EquipmentEncode=object.get("EquipmentEncode");
|
|
|
- Object ModelType=object.get("ModelType");
|
|
|
- Object CheckNumber=object.get("CheckNumber");
|
|
|
- Object NcmNumber=object.get("NcmNumber");
|
|
|
- Object NonconformNumber=object.get("NonconformNumber");
|
|
|
- Object CheckDate=object.get("CheckDate");
|
|
|
- Object ShiftName=object.get("ShiftName");
|
|
|
- Object LineBody=object.get("LineBody");
|
|
|
- Object Inspector=object.get("Inspector");
|
|
|
+ Object Barcode=obj.get("Barcode");
|
|
|
+ Object EquipmentEncode=obj.get("EquipmentEncode");
|
|
|
+ Object ModelType=obj.get("ModelType");
|
|
|
+ Object CheckNumber=obj.get("CheckNumber");
|
|
|
+ Object NcmNumber=obj.get("NcmNumber");
|
|
|
+ Object NonconformNumber=obj.get("NonconformNumber");
|
|
|
+ Object CheckDate=obj.get("CheckDate");
|
|
|
+ Object ShiftName=obj.get("ShiftName");
|
|
|
+ Object LineBody=obj.get("LineBody");
|
|
|
+ Object Inspector=obj.get("Inspector");
|
|
|
int XT_ID = baseDao.getSeqId("xraytest_seq");
|
|
|
baseDao.execute("insert into xraytest(XT_ID, BARCODE, EQUIPMENTENCODE, MODELTYPE, CHECKNUMBER, NCMNUMBER, NONCONFORMNUMBER, CHECKDATE, SHIFTNAME, LINEBODY, INSPECTOR)" +
|
|
|
"values("+XT_ID+",'"+Barcode+"','"+EquipmentEncode+"','"+ModelType+"','"+CheckNumber+"','"+NcmNumber+"','"+NonconformNumber+"',to_date('"+CheckDate+"','yyyy-mm-dd hh24:mi:ss')" +
|
|
|
",'"+ShiftName+"','"+LineBody+"','"+Inspector+"')");
|
|
|
- for (int i=0;i<object1.size();i++){
|
|
|
- JSONObject map1=object1.getJSONObject(i);
|
|
|
+ for (int i=0;i<object2.size();i++){
|
|
|
+ JSONObject map1=object2.getJSONObject(i);
|
|
|
String NonconformANo=map1.getString("NonconformANo");
|
|
|
String NonconformDescription=map1.getString("NonconformDescription");
|
|
|
baseDao.execute("insert into XrayTestdetail(xtd_xtid,xtd_id,NONCONFORMANO, NONCONFORMDESCRIPTION)" +
|
|
@@ -644,7 +646,6 @@ public class MESHelperServiceImpl implements MESHelperService {
|
|
|
rmap.put("code","0");
|
|
|
rmap.put("result","OK");
|
|
|
rmap.put("ServerMessage","MES:检查数据上传成功!");
|
|
|
-
|
|
|
return rmap;
|
|
|
}
|
|
|
|