fix bug 40764 会员项目-资料网员-导入成员-提示语格式建议修改

This commit is contained in:
lijiarao
2021-10-18 10:56:24 +08:00
parent c759aaea61
commit 842ebcaddc
@@ -198,6 +198,7 @@ public class PayMemberProjectSubitemController extends JeroController<PayMemberP
@ApiOperation(value = "会员项目成员表-导入数据", notes = "会员项目成员表-通过id查询") @ApiOperation(value = "会员项目成员表-导入数据", notes = "会员项目成员表-通过id查询")
@RequestMapping(value = "/importExcel", method = RequestMethod.POST) @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) { public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
request.getParameter("");
List<Object> excelData = super.getExcelData(request, PayMemberProjectSubitemExcel.class); List<Object> excelData = super.getExcelData(request, PayMemberProjectSubitemExcel.class);
if (excelData.isEmpty()) { if (excelData.isEmpty()) {
throw new JeroBootException("导入数据为空,请填写数据之后重新导入!"); throw new JeroBootException("导入数据为空,请填写数据之后重新导入!");
@@ -246,7 +247,11 @@ public class PayMemberProjectSubitemController extends JeroController<PayMemberP
} }
} }
if (!errorMessage.isEmpty()) { if (!errorMessage.isEmpty()) {
throw new JeroBootException("excel导入失败,错误信息为" + errorMessage); StringBuilder msg = new StringBuilder();
for (String s : errorMessage) {
msg.append(s).append(",请修改。<br/>");
}
throw new JeroBootException(msg.toString());
} }
return Result.OK("文件导入成功!"); return Result.OK("文件导入成功!");
} }