提交 76250c37 authored 作者: 000516's avatar 000516 提交者: Coding

上报计划异常报错信息抛出

Merge Request: 上报计划异常报错信息抛出 Created By: @李秋林 Accepted By: @李秋林 URL: https://g-pkkp8204.coding.net/p/promotion/d/promotion-service/git/merge/167?initial=true
......@@ -53,7 +53,7 @@ public class PromPlanCoreController {
String[] urlArr = activityPlanVo.getExcelUrl().split("/");
String fileId = urlArr[urlArr.length - 1];
String filePath = "/root/promotion/planv2/" + fileId;
//todo String filePath = "/Users/a02200059/Desktop/2.0/" + fileId;
// String filePath = "/Users/a02200059/Desktop/2.0/" + fileId;
FileUtils.downloadExcel(activityPlanVo.getExcelUrl(), filePath);
activityPlanVo.setExcelId(fileId);
Map<String, Object> map = promPlanCoreService.selfPlanUp(activityPlanVo, filePath);
......@@ -61,7 +61,7 @@ public class PromPlanCoreController {
} catch (DataException e) {
return new R(e.getCode(), e.getMsg(), null);
} catch (Exception e) {
return R.fail();
return R.fail(e.getMessage());
}
}
......@@ -95,7 +95,7 @@ public class PromPlanCoreController {
} catch (DataException e) {
return new R(e.getCode(), e.getMsg(), null);
} catch (Exception e) {
return R.fail();
return R.fail(e.getMessage());
}
}
......@@ -131,7 +131,7 @@ public class PromPlanCoreController {
if (fileId.length() > 53) {
throw new DataException(RCode.ACTIVITY_PLAN_FILENAME_LONG);
}
String filePath = "/home/" + fileId;
String filePath = "/root/promotion/planv2/" + fileId;
FileUtils.downloadExcel(activityPlanVo.getExcelUrl(), filePath);
// todo String filePath = "/Users/a02200059/Desktop/职能角色-新增-1.xlsx";
activityPlanVo.setExcelId(fileId);
......@@ -140,7 +140,7 @@ public class PromPlanCoreController {
} catch (DataException e) {
return new R(e.getCode(), e.getMsg(), null);
} catch (Exception e) {
return R.fail();
return R.fail(e.getMessage());
}
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论