|
@@ -3170,19 +3170,27 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
|
|
|
continue;
|
|
|
}
|
|
|
XSSFCell participatorCell = row.getCell(5);
|
|
|
+ XSSFCell inchargerCell = row.getCell(6);
|
|
|
if (participatorCell!=null)participatorCell.setCellType(CellType.STRING);
|
|
|
+ if (inchargerCell != null)inchargerCell.setCellType(CellType.STRING);
|
|
|
String part = participatorCell.getStringCellValue().trim();
|
|
|
+ String inchargerName = inchargerCell.getStringCellValue().trim();
|
|
|
+ if(part.equals("参与人")){
|
|
|
+ continue;
|
|
|
+ }
|
|
|
String[] partSplit = part.split("\\,|\\,");
|
|
|
for (String s : partSplit) {
|
|
|
- if(userNameList.contains(s)){
|
|
|
- continue;
|
|
|
+ if(!userNameList.contains(s)&&!s.equals("")){
|
|
|
+ userNameList.add(s);
|
|
|
}
|
|
|
- userNameList.add(s);
|
|
|
+ }
|
|
|
+ if(!userNameList.contains(inchargerName)&&!inchargerName.equals("")){
|
|
|
+ userNameList.add(inchargerName);
|
|
|
}
|
|
|
}
|
|
|
- System.out.println("参与搜素的人员列表"+userNameList);
|
|
|
+ System.out.println("参与搜素的人员列表"+userNameList + userNameList.size());
|
|
|
HttpRespMsg respMsg=new HttpRespMsg();
|
|
|
- if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
|
|
|
+ if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1&&userNameList.size()>0){
|
|
|
respMsg = wxCorpInfoService.getBatchSearchUserInfo(wxCorpInfo, userNameList,null);
|
|
|
if(respMsg.code.equals("0")){
|
|
|
msg.setError("姓名为["+String.valueOf(respMsg.data)+"]的人员存在重复,请使用工号!");
|
|
@@ -3557,28 +3565,38 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
|
|
|
continue;
|
|
|
}
|
|
|
HSSFCell participatorCell=null;
|
|
|
+ HSSFCell inchargerCell=null;
|
|
|
int c=0;
|
|
|
if(company.getId()==936){
|
|
|
c++;
|
|
|
}
|
|
|
if(timeType.getMainProjectState()==1){
|
|
|
participatorCell = row.getCell(4+c);
|
|
|
+ inchargerCell = row.getCell(5+c);
|
|
|
}else {
|
|
|
participatorCell = row.getCell(5+c);
|
|
|
+ inchargerCell = row.getCell(6+c);
|
|
|
}
|
|
|
if (participatorCell!=null)participatorCell.setCellType(CellType.STRING);
|
|
|
+ if (inchargerCell != null)inchargerCell.setCellType(CellType.STRING);
|
|
|
String part = participatorCell.getStringCellValue().trim();
|
|
|
+ String inchargerName = inchargerCell.getStringCellValue().trim();
|
|
|
+ if(part.equals("参与人")){
|
|
|
+ continue;
|
|
|
+ }
|
|
|
String[] partSplit = part.split("\\,|\\,");
|
|
|
for (String s : partSplit) {
|
|
|
- if(userNameList.contains(s)){
|
|
|
- continue;
|
|
|
+ if(!userNameList.contains(s)&&!s.equals("")){
|
|
|
+ userNameList.add(s);
|
|
|
}
|
|
|
- userNameList.add(s);
|
|
|
+ }
|
|
|
+ if(!userNameList.contains(inchargerName)&&!inchargerName.equals("")){
|
|
|
+ userNameList.add(inchargerName);
|
|
|
}
|
|
|
}
|
|
|
- System.out.println("参与搜素的人员列表"+userNameList);
|
|
|
+ System.out.println("参与搜素的人员列表"+userNameList + userNameList.size());
|
|
|
HttpRespMsg respMsg=new HttpRespMsg();
|
|
|
- if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
|
|
|
+ if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1&&userNameList.size()>0){
|
|
|
respMsg = wxCorpInfoService.getBatchSearchUserInfo(wxCorpInfo, userNameList,null);
|
|
|
if(respMsg.code.equals("0")){
|
|
|
msg.setError("姓名为["+String.valueOf(respMsg.data)+"]的人员存在重复,请使用工号!");
|