Commit 09593bec authored by libin's avatar libin

身份信息

parent 52b4fa03
......@@ -149,13 +149,16 @@ public class AppUserPositionTempBiz extends BaseBiz<AppUserPositionTempMapper, A
for (int i = 0; i < userPostionData.size(); i++) {
String[] data = userPostionData.get(i);
Integer postionId = null;
String name="";
String phone="";
String postionName="";
try {
String name = data[0];
String phone = data[1];
name = data[0];
phone = data[1];
if (StringUtils.isEmpty(phone)){
throw new BaseException("手机号为空");
}
String postionName = data[2];
postionName = data[2];
if (StringUtils.isEmpty(postionName)){
throw new BaseException("身份为空");
}
......@@ -184,7 +187,19 @@ public class AppUserPositionTempBiz extends BaseBiz<AppUserPositionTempMapper, A
errorResultMap.put("num", i);
errorResultMap.put("msg",ex.getMessage());
errorResult.add(errorResultMap);
}catch (Exception ex){
}catch (ArrayIndexOutOfBoundsException ex){
errorResultMap = new HashMap<>(1);
errorResultMap.put("num", i);
String msg= "";
if(StringUtils.isEmpty(phone)){
msg+="手机号码缺失";
}
if (StringUtils.isEmpty(postionName)){
msg+=",身份信息缺失";
}
errorResultMap.put("msg",msg);
errorResult.add(errorResultMap);
} catch (Exception ex){
errorResultMap = new HashMap<>(1);
errorResultMap.put("num", i);
errorResultMap.put("msg","数据"+Arrays.toString(data)+"保存失败");
......
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