Commit 5822a918 by wancheng

增加app异常状态

parent d7a6bef7
......@@ -55,6 +55,7 @@ public class ServiceHPKC002 extends ServiceBase {
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPKC002().eiMetadata);
inInfo.setBlock(InventTypeEnum.generatorEiBlock());
} catch (PlatException e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -77,6 +78,7 @@ public class ServiceHPKC002 extends ServiceBase {
queryRow.put("inventTypes", DEFAULT_INVENT_CODE);
inInfo = super.query(inInfo, HPKC002.QUERY, new HPKC002());
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......@@ -121,6 +123,7 @@ public class ServiceHPKC002 extends ServiceBase {
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据删除成功!");
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "删除失败");
}
return inInfo;
......
......@@ -73,6 +73,7 @@ public class ServiceHPKC002A extends ServiceEPBase {
}
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPKC010().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -92,6 +93,7 @@ public class ServiceHPKC002A extends ServiceEPBase {
queryRow.put("inventTypes", DEFAULT_INVENT_CODE);
inInfo = super.query(inInfo, HPKC010.QUERY, new HPKC010());
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......@@ -119,6 +121,7 @@ public class ServiceHPKC002A extends ServiceEPBase {
// 生成销售库单
this.saveData(resultRows, dbKc010Map, hpsc006Id);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setMsg(inInfo, e, "生成领料单失败");
}
return inInfo;
......
......@@ -53,6 +53,7 @@ public class ServiceHPKC003 extends ServiceBase {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.FACTORY_RECORD_BLOCK_ID), null, false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPKC003().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -74,6 +75,7 @@ public class ServiceHPKC003 extends ServiceBase {
StringUtil.DEFAULT_CHARACTER_TO_BE_REMOVED));
inInfo = super.query(inInfo, "HPKC003.query", new HPKC003());
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......@@ -121,6 +123,7 @@ public class ServiceHPKC003 extends ServiceBase {
eiInfo.setStatus(EiConstant.STATUS_SUCCESS);
eiInfo.setMsg("删除成功!");
} catch (Exception e) {
eiInfo.setStatus(500);
LogUtils.setDetailMsg(eiInfo, e, "删除失败");
}
return eiInfo;
......
......@@ -61,6 +61,7 @@ public class ServiceHPKC003A extends ServiceEPBase {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.GROUP_RECORD_BLOCK_ID), null, false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC005B().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -80,6 +81,7 @@ public class ServiceHPKC003A extends ServiceEPBase {
queryMap.put("isComplete", CommonConstant.YesNo.NO_0);
inInfo = super.query(inInfo, HPSC005B.QUERY, new HPSC005B());
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......@@ -154,6 +156,7 @@ public class ServiceHPKC003A extends ServiceEPBase {
newKc003.getAmount(), newKc003.getWeight(),fSc005b.getFactoryCode());
}
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "生成入库单失败");
}
return inInfo;
......
......@@ -45,6 +45,7 @@ public class ServiceHPSC002B extends ServiceEPBase {
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC002A().eiMetadata);
}
} catch (PlatException e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -68,6 +69,7 @@ public class ServiceHPSC002B extends ServiceEPBase {
inInfo = super.query(inInfo, "HPSC002B.queryDev", new HPSC002B());
}
} catch (Throwable e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......
......@@ -35,6 +35,7 @@ public class ServiceHPSC005 extends ServiceBase {
try {
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC005().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -56,6 +57,7 @@ public class ServiceHPSC005 extends ServiceBase {
DateUtils.formatShort(inInfo.getCellStr(EiConstant.queryBlock, ACConstants.ROW_CODE_0, HPSC003.FIELD_PLAN_COMPLETION_DATE)));
inInfo = super.query(inInfo, HPSC005.QUERY, new HPSC005());
} catch (Throwable e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......
......@@ -50,6 +50,7 @@ public class ServiceHPSC005A extends ServiceBase {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.FACTORY_RECORD_BLOCK_ID), null, false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC005A().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -67,6 +68,7 @@ public class ServiceHPSC005A extends ServiceBase {
try {
inInfo = super.query(inInfo, HPSC005A.QUERY, new HPSC005A());
} catch (Throwable e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......@@ -111,6 +113,7 @@ public class ServiceHPSC005A extends ServiceBase {
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据操作成功!");
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setMsg(inInfo, e, "新增失败");
}
return inInfo;
......@@ -190,6 +193,7 @@ public class ServiceHPSC005A extends ServiceBase {
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据删除成功!");
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setMsg(inInfo, e, "删除失败");
}
return inInfo;
......
......@@ -32,6 +32,7 @@ public class ServiceHPSC005B extends ServiceBase {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.GROUP_RECORD_BLOCK_ID), null, false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC005B().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -49,6 +50,7 @@ public class ServiceHPSC005B extends ServiceBase {
try {
inInfo = super.query(inInfo, HPSC005B.QUERY, new HPSC005B());
} catch (Throwable e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......
......@@ -46,6 +46,7 @@ public class ServiceHPSC005C extends ServiceBase {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.SUB_INVENT_RECORD_BLOCK_ID), null, false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC005C().eiMetadata);
} catch (Exception e) {
inInfo.setStatus(500);
LogUtils.setMsg(inInfo, e, "初始化失败");
}
return inInfo;
......@@ -64,6 +65,7 @@ public class ServiceHPSC005C extends ServiceBase {
Map queryRow = EiInfoUtils.getFirstRow(inInfo);
inInfo = super.query(inInfo, HPSC005C.QUERY, new HPSC005C());
} catch (Throwable e) {
inInfo.setStatus(500);
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
......
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