This commit is contained in:
zds
2022-11-03 12:50:25 +08:00
parent 34b24798e4
commit a14719d6e3
4 changed files with 33 additions and 17 deletions

View File

@@ -34,7 +34,7 @@ public class DeviceBigScreenServiceImpl implements DeviceBigScreenService {
// 1.1获取当前日期 - 前14天的日期
String now = DateUtil.now();
for (int i = 0; i < 14; i++) {
for (int i = 13; i >= 0; i--) {
JSONObject json = new JSONObject();
String run_date = DateUtil.offsetDay(DateUtil.parse(now), -i).toString().substring(0, 10);
// 棒料事业部H900000 矿用合金事业部H800000 型材事业部H400000 混合料厂H1300000 武汉运营保障部H1200200 精密零件事业部H1000000

View File

@@ -209,6 +209,9 @@ public class DevicerepairmstServiceImpl implements DevicerepairmstService {
JSONArray tableData = whereJson.getJSONArray("tableData");
WQLObject mstTab = WQLObject.getWQLObject("EM_BI_DeviceRepairMst");
WQLObject dtlTab = WQLObject.getWQLObject("EM_BI_DeviceRepairDtl");
if(StrUtil.isEmpty(whereJson.getString("invstatus"))){
throw new BadRequestException("状态不能为空");
}
// 更新主表
JSONObject jsonMst = mstTab.query("repair_id = '" + whereJson.getString("repair_id") + "'").uniqueResult(0);
@@ -460,6 +463,9 @@ public class DevicerepairmstServiceImpl implements DevicerepairmstService {
WQLObject reDtlTab = WQLObject.getWQLObject("EM_BI_DeviceRepairDtl"); // 设备维修单明细表
String invstatus = map.getString("invstatus");
if(StrUtil.isEmpty(invstatus)){
throw new BadRequestException("状态不能为空");
}
JSONArray rows = map.getJSONArray("rows");
for(int m=0; m<rows.size();m++){
JSONObject whereJson = rows.getJSONObject(m);