Commit f3fcad63 authored by chenyuxi's avatar chenyuxi

feat: 改错误提示语返回格式

parent de0b3116
...@@ -659,7 +659,7 @@ public class ExcelUtil <T> implements Serializable { ...@@ -659,7 +659,7 @@ public class ExcelUtil <T> implements Serializable {
private String validateUtil(String c, ExcelAttribute attr, int i) { private String validateUtil(String c, ExcelAttribute attr, int i) {
//非空校验 //非空校验
if (attr.isNotEmpty() && !Common.isNotNull(c)) { if (attr.isNotEmpty() && !Common.isNotNull(c)) {
return errorInfo(attr, "_字段不可为空", i); return errorInfo(attr, "_不可为空", i);
} }
if (Common.isNotNull(c)) { if (Common.isNotNull(c)) {
//日期格式校验 //日期格式校验
...@@ -780,7 +780,7 @@ public class ExcelUtil <T> implements Serializable { ...@@ -780,7 +780,7 @@ public class ExcelUtil <T> implements Serializable {
if (null != errorMessageHashMap && null != errorMessage) { if (null != errorMessageHashMap && null != errorMessage) {
temp = errorMessageHashMap.get(errorMessage.getLineNum()); temp = errorMessageHashMap.get(errorMessage.getLineNum());
if (null != temp) { if (null != temp) {
temp.setMessage(temp.getMessage() + CommonConstants.DOWN_LINE_STRING + errorMessage.getMessage()); temp.setMessage(temp.getMessage() + ";" + errorMessage.getMessage());
errorMessageHashMap.put(temp.getLineNum(), temp); errorMessageHashMap.put(temp.getLineNum(), temp);
} else { } else {
errorMessageHashMap.put(errorMessage.getLineNum(), errorMessage); errorMessageHashMap.put(errorMessage.getLineNum(), errorMessage);
......
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