|
@@ -315,23 +315,24 @@ public class CamelRestConfiguration extends RouteBuilder {
|
315
|
int hours = (int) ((time2 - time1) / (1000 * 60 * 60));
|
315
|
int hours = (int) ((time2 - time1) / (1000 * 60 * 60));
|
316
|
//云平台和采集时间相差要小于4小时
|
316
|
//云平台和采集时间相差要小于4小时
|
317
|
// if (hours < 4 && !"".equals(gtsj) && hours1 < 4) {
|
317
|
// if (hours < 4 && !"".equals(gtsj) && hours1 < 4) {
|
318
|
- z.setZd_init_sgt(gtsj);//位移载荷点
|
|
|
319
|
- z.setProd_date(time.substring(0,10)+' '+time.substring(11,18));
|
|
|
|
|
318
|
+ z.setZd_init_sgt(gtsj);//位移载荷点
|
|
|
319
|
+ z.setProd_date(time.substring(0, 10) + ' ' + time.substring(11, 18));
|
320
|
// z.setSys_date(sysDate);
|
320
|
// z.setSys_date(sysDate);
|
321
|
// z.setIs_well_close(Double.valueOf(jsonObject.getString("minCurrent")) > 0 ? "开井": "关井");
|
321
|
// z.setIs_well_close(Double.valueOf(jsonObject.getString("minCurrent")) > 0 ? "开井": "关井");
|
322
|
// z.setPressure(0);
|
322
|
// z.setPressure(0);
|
323
|
- if (jsonObject.getString("strokeFrequency") != null) {
|
|
|
324
|
- z.setStroke(CALUtil.round((Double.valueOf(jsonObject.getString("strokeFrequency"))) * 100) / 100);//冲程,但GTSB_2的冲程是CC字段
|
|
|
325
|
- }
|
|
|
326
|
- if (jsonObject.getString("stroke") != null) {
|
|
|
327
|
- z.setFrequence(CALUtil.round((Double.valueOf(jsonObject.getString("stroke"))) * 100) / 100);//冲次,但GTSB_2的冲次是PJXC字段
|
|
|
328
|
- }
|
|
|
329
|
- z.setSxzh(Double.parseDouble(jsonObject.getString("maxLoad")));//最大载荷
|
|
|
330
|
- z.setXxzh(Double.parseDouble(jsonObject.getString("minLoad")));//最小载荷
|
|
|
331
|
- z.setWell_common_name(well_id);
|
|
|
332
|
- z.setMaxCurrent(jsonObject.getDoubleValue("maxCurrent"));
|
|
|
333
|
- z.setMinCurrent(jsonObject.getDoubleValue("minCurrent"));
|
|
|
|
|
323
|
+ if (jsonObject.getString("stroke") != null) {
|
|
|
324
|
+ z.setStroke(CALUtil.round((Double.valueOf(jsonObject.getString("stroke"))) * 100) / 100);
|
|
|
325
|
+ }
|
|
|
326
|
+ if (jsonObject.getString("strokeFrequency") != null) {
|
|
|
327
|
+ z.setFrequence(CALUtil.round((Double.valueOf(jsonObject.getString("strokeFrequency"))) * 100) / 100);
|
334
|
}
|
328
|
}
|
|
|
329
|
+
|
|
|
330
|
+ z.setSxzh(Double.parseDouble(jsonObject.getString("maxLoad")));//最大载荷
|
|
|
331
|
+ z.setXxzh(Double.parseDouble(jsonObject.getString("minLoad")));//最小载荷
|
|
|
332
|
+ z.setWell_common_name(well_id);
|
|
|
333
|
+ z.setMaxCurrent(jsonObject.getDoubleValue("maxCurrent"));
|
|
|
334
|
+ z.setMinCurrent(jsonObject.getDoubleValue("minCurrent"));
|
|
|
335
|
+ }
|
335
|
// System.out.println("step 3 ===="+z);
|
336
|
// System.out.println("step 3 ===="+z);
|
336
|
// }
|
337
|
// }
|
337
|
}
|
338
|
}
|
|
@@ -491,9 +492,9 @@ public class CamelRestConfiguration extends RouteBuilder {
|
491
|
aRow.put("frequency", zdjg_well.getFrequence());
|
492
|
aRow.put("frequency", zdjg_well.getFrequence());
|
492
|
aRow.put("dyna_create_time", zdjg_well.getProd_date());
|
493
|
aRow.put("dyna_create_time", zdjg_well.getProd_date());
|
493
|
aRow.put("well_name", zdjg_well.getStroke() == 0 || zdjg_well.getSxzh() == 0 ? "No01" : aRow.get("well_id"));
|
494
|
aRow.put("well_name", zdjg_well.getStroke() == 0 || zdjg_well.getSxzh() == 0 ? "No01" : aRow.get("well_id"));
|
494
|
- aRow.put("max_current",zdjg_well.getMaxCurrent());
|
|
|
495
|
- aRow.put("min_current",zdjg_well.getMinCurrent());
|
|
|
496
|
- aRow.put("phd",0);
|
|
|
|
|
495
|
+ aRow.put("max_current", zdjg_well.getMaxCurrent());
|
|
|
496
|
+ aRow.put("min_current", zdjg_well.getMinCurrent());
|
|
|
497
|
+ aRow.put("phd", 0);
|
497
|
})
|
498
|
})
|
498
|
// .log("${body[phd]}"+ "sql" + "${body[well_name]}")
|
499
|
// .log("${body[phd]}"+ "sql" + "${body[well_name]}")
|
499
|
// .filter(simple("${body[well_name]} != 'No01'"))
|
500
|
// .filter(simple("${body[well_name]} != 'No01'"))
|