diff --git a/jcl-hrmorganization/secondev-jcl-hrmorganization/src/main/java/com/weaver/seconddev/jcl/organization/importAdvice/ImportEmployeeAdvice.java b/jcl-hrmorganization/secondev-jcl-hrmorganization/src/main/java/com/weaver/seconddev/jcl/organization/importAdvice/ImportEmployeeAdvice.java index 3ab43d5..e738ce4 100644 --- a/jcl-hrmorganization/secondev-jcl-hrmorganization/src/main/java/com/weaver/seconddev/jcl/organization/importAdvice/ImportEmployeeAdvice.java +++ b/jcl-hrmorganization/secondev-jcl-hrmorganization/src/main/java/com/weaver/seconddev/jcl/organization/importAdvice/ImportEmployeeAdvice.java @@ -22,11 +22,13 @@ public class ImportEmployeeAdvice implements ImportDataAdvice { public void dataAdvice(BaseImportDataAdviceDto req) { List> dataList = req.getDataList(); List> newDataList = Lists.newArrayList(); + List errorMsg = Lists.newArrayList(); for (List data:dataList){ boolean mark = true; for (DataForImportEntity entity:data){ if (entity.getDataKey().equals("手机号") && entity.getValue().equals("18816254117")){ entity.setErrorMsg("手机号重复"); + errorMsg.add("手机号重复"); mark = false; }else { @@ -36,6 +38,8 @@ public class ImportEmployeeAdvice implements ImportDataAdvice { newDataList.add(data); } } + Gson gson = new Gson(); + req.setErrorMessage(gson.toJson(errorMsg)); req.setDataList(newDataList); log.error("importjclEmployeeAdvice info :[{}] ",req.toString());