diff --git a/pom.xml b/pom.xml index e3e712f..d1e2781 100644 --- a/pom.xml +++ b/pom.xml @@ -213,7 +213,12 @@ lombok 1.18.12 - + + + com.alibaba + easyexcel + 2.1.1 + diff --git a/src/main/java/com/msdw/tms/common/utils/ExcelImportHelper.java b/src/main/java/com/msdw/tms/common/utils/ExcelImportHelper.java index 2897b6e..8e5ec3f 100644 --- a/src/main/java/com/msdw/tms/common/utils/ExcelImportHelper.java +++ b/src/main/java/com/msdw/tms/common/utils/ExcelImportHelper.java @@ -88,7 +88,7 @@ public class ExcelImportHelper { return list; } /** - * 读取学生管理 + * 读取员工管理 * @param file * @return */ @@ -109,6 +109,10 @@ public class ExcelImportHelper { Cell phone; Cell email; + Cell staffGradeName; + Cell staffProfessionalArchitectureName; + Cell staffGradeNameTwo; + Cell staffProfessionalArchitectureNameTwo; if (row != null) { staff = new StaffVo(); row.getCell(0).setCellType(CellType.STRING); @@ -119,27 +123,56 @@ public class ExcelImportHelper { Cell role = row.getCell(2); row.getCell(3).setCellType(CellType.STRING); Cell workNumber = row.getCell(3); - row.getCell(4).setCellType(CellType.STRING); - Cell staffGradeName = row.getCell(4); - row.getCell(5).setCellType(CellType.STRING); - Cell staffProfessionalArchitectureName = row.getCell(5); +// row.getCell(4).setCellType(CellType.STRING); +// Cell staffGradeName = row.getCell(4); + if (row.getCell(4)!=null){ + row.getCell(4).setCellType(CellType.STRING); + staffGradeName = row.getCell(4); + }else { + staffGradeName = row.createCell(4); + } + if (row.getCell(5)!=null){ + row.getCell(5).setCellType(CellType.STRING); + staffProfessionalArchitectureName = row.getCell(5); + }else { + staffProfessionalArchitectureName = row.createCell(5); + } if (row.getCell(6)!=null){ row.getCell(6).setCellType(CellType.STRING); - phone = row.getCell(6); + staffGradeNameTwo = row.getCell(6); }else { - phone = row.createCell(6); + staffGradeNameTwo = row.createCell(6); } if (row.getCell(7)!=null){ row.getCell(7).setCellType(CellType.STRING); - email = row.getCell(7); + staffProfessionalArchitectureNameTwo = row.getCell(7); }else { - email = row.createCell(7); + staffProfessionalArchitectureNameTwo = row.createCell(7); } - row.getCell(8).setCellType(CellType.STRING); - Cell schoolAppellationName = row.getCell(8); - row.getCell(9).setCellType(CellType.STRING); - Cell failureMsg = row.getCell(9); + +// row.getCell(5).setCellType(CellType.STRING); +// Cell staffProfessionalArchitectureName = row.getCell(5); +// row.getCell(6).setCellType(CellType.STRING); +// Cell staffGradeNameTwo = row.getCell(6); +// row.getCell(7).setCellType(CellType.STRING); +// Cell staffProfessionalArchitectureNameTwo = row.getCell(7); + if (row.getCell(8)!=null){ + row.getCell(8).setCellType(CellType.STRING); + phone = row.getCell(8); + }else { + phone = row.createCell(8); + } + if (row.getCell(9)!=null){ + row.getCell(9).setCellType(CellType.STRING); + email = row.getCell(9); + }else { + email = row.createCell(9); + } + row.getCell(10).setCellType(CellType.STRING); + Cell schoolAppellationName = row.getCell(10); +// row.getCell(11).setCellType(CellType.STRING); +// Cell failureMsg = row.getCell(11); String roleValue = role.getStringCellValue(); @@ -161,10 +194,14 @@ public class ExcelImportHelper { staff.setAccount(account.getStringCellValue()); // 学生学号 staff.setWorkNumber(workNumber.getStringCellValue()); - //专业名称 + //管理员的专业名称 staff.setStaffGradeName(staffGradeName.getStringCellValue()); - //组织架构名称 + //管理员的组织架构名称 staff.setStaffProfessionalArchitectureName(staffProfessionalArchitectureName.getStringCellValue()); + //老师的专业名称 + staff.setStaffGradeNameTwo(staffGradeNameTwo.getStringCellValue()); + //老师的组织架构名称 + staff.setStaffProfessionalArchitectureNameTwo(staffProfessionalArchitectureNameTwo.getStringCellValue()); //电话 staff.setPhone(phone.getStringCellValue()); //邮箱 diff --git a/src/main/java/com/msdw/tms/common/utils/poi/ExcelExportUtil.java b/src/main/java/com/msdw/tms/common/utils/poi/ExcelExportUtil.java index ffe4899..e43d0fb 100644 --- a/src/main/java/com/msdw/tms/common/utils/poi/ExcelExportUtil.java +++ b/src/main/java/com/msdw/tms/common/utils/poi/ExcelExportUtil.java @@ -44,8 +44,9 @@ public class ExcelExportUtil { XSSFWorkbook workbook = new XSSFWorkbook(is); //2.读取工作表 Sheet sheet = workbook.getSheetAt(0); + Row row1 = sheet.getRow(styleIndex); //3.提取公共的样式 - CellStyle[] styles = getTemplateStyles(sheet.getRow(styleIndex)); + CellStyle[] styles = getTemplateStyles(row1); //4.根据数据创建每一行和每一个单元格的数据2 AtomicInteger datasAi = new AtomicInteger(rowIndex); //数字 for (T t : objs) { @@ -77,8 +78,19 @@ public class ExcelExportUtil { CellStyle[] getTemplateStyles(Row row) { CellStyle[] styles = new CellStyle[row.getLastCellNum()]; for (int i = 0; i < row.getLastCellNum(); i++) { - styles[i] = row.getCell(i).getCellStyle(); + if (row.getCell(i)==null){ + styles[i] = row.createCell(i).getCellStyle(); + }else{ + styles[i] = row.getCell(i).getCellStyle(); + } } return styles; } +// CellStyle[] getTemplateStyles(Row row) { +// CellStyle[] styles = new CellStyle[row.getLastCellNum()]; +// for (int i = 0; i < row.getLastCellNum(); i++) { +// styles[i] = row.getCell(i).getCellStyle(); +// } +// return styles; +// } } diff --git a/src/main/java/com/msdw/tms/dao/SystemSetttingDao.java b/src/main/java/com/msdw/tms/dao/SystemSetttingDao.java index 084daba..88b747a 100644 --- a/src/main/java/com/msdw/tms/dao/SystemSetttingDao.java +++ b/src/main/java/com/msdw/tms/dao/SystemSetttingDao.java @@ -40,9 +40,17 @@ public interface SystemSetttingDao { List queryStaffInfo(Integer userId); - boolean addStaff(StaffEntity staffEntity,Integer userId); + boolean addStaffUpdata(StaffEntity staffEntity); boolean deleteStaffOnly(Integer userId); boolean updateStaffOnly(StaffVo staffVo); + + boolean addStaffManager(StaffVo staff); + + boolean addStaffTeacher(StaffVo staff); + + Integer queryDepartmentNameGrade(String staffGradeName,Integer organizationId); + + Integer queryDepartmentNameOrganization(String staffProfessionalArchitectureName,Integer schoolId); } diff --git a/src/main/java/com/msdw/tms/dao/UserInfoDao.java b/src/main/java/com/msdw/tms/dao/UserInfoDao.java index 3de1095..44b9409 100644 --- a/src/main/java/com/msdw/tms/dao/UserInfoDao.java +++ b/src/main/java/com/msdw/tms/dao/UserInfoDao.java @@ -38,7 +38,11 @@ public interface UserInfoDao extends BaseMapper { List queryPhone(String phone); - List queryAccount(String account); +// List queryAccount(String account); + + List queryAccount(String account); + + StaffVo queryAccountUpdate(Integer userId); boolean setNUM(Integer userId); diff --git a/src/main/java/com/msdw/tms/entity/vo/StaffExportVo.java b/src/main/java/com/msdw/tms/entity/vo/StaffExportVo.java index 4f364e4..0e383dd 100644 --- a/src/main/java/com/msdw/tms/entity/vo/StaffExportVo.java +++ b/src/main/java/com/msdw/tms/entity/vo/StaffExportVo.java @@ -2,10 +2,12 @@ package com.msdw.tms.entity.vo; import com.msdw.tms.common.utils.poi.ExcelAttribute; import lombok.Data; +import lombok.ToString; import lombok.experimental.Accessors; @Data @Accessors(chain = true) +@ToString public class StaffExportVo { //序列号 diff --git a/src/main/java/com/msdw/tms/entity/vo/StaffVo.java b/src/main/java/com/msdw/tms/entity/vo/StaffVo.java index e9f58e5..4da7cd6 100644 --- a/src/main/java/com/msdw/tms/entity/vo/StaffVo.java +++ b/src/main/java/com/msdw/tms/entity/vo/StaffVo.java @@ -1,5 +1,6 @@ package com.msdw.tms.entity.vo; +import com.msdw.tms.common.utils.poi.ExcelAttribute; import com.msdw.tms.entity.StaffEntity; import com.msdw.tms.entity.UserInfoEntity; import lombok.Data; @@ -54,6 +55,11 @@ public class StaffVo extends UserInfoEntity { private List staff; + //老师专业组织名称 + private String staffGradeNameTwo; + + //老师组织架构名称 + private String staffProfessionalArchitectureNameTwo; //----------------------------------部门 diff --git a/src/main/java/com/msdw/tms/service/impl/QuestionsServiceImpl.java b/src/main/java/com/msdw/tms/service/impl/QuestionsServiceImpl.java index f121590..2fafc67 100644 --- a/src/main/java/com/msdw/tms/service/impl/QuestionsServiceImpl.java +++ b/src/main/java/com/msdw/tms/service/impl/QuestionsServiceImpl.java @@ -632,7 +632,6 @@ public class QuestionsServiceImpl extends ServiceImpl resultA = userInfoDao.queryAccount(account); + List resultA = userInfoDao.queryAccount(account); // List resultW = systemSetttingDao.queryWorkNumber(workNumber); if(resultA.size()>0){ return R.error(400,"账号不能重复"); @@ -124,29 +125,35 @@ public class SystemSettingServiceImpl implements SystemSetttingService { String workNumber = staffVo.getWorkNumber(); List staff = staffVo.getStaff();//获取员工数据 - List result = userInfoDao.queryAccount(account); - String roleIds = result.get(0); + StaffVo result = userInfoDao.queryAccountUpdate(staffVo.getUserId()); +// String roleIds = result.get(0).getRoleId(); +// StaffVo staffVo1 = result.get(0); + String roleIds = result.getRoleId(); String[] splitOld = staffVo.getRoleId().split(","); String[] splitNew = roleIds.split(","); - if (splitOld.length==splitNew.length){ - for (int i = 0;i<=splitNew.length;i++){ + if (splitOld.length==splitNew.length&&splitNew.length<2){ + for (int i = 0;isplitOld.length){ boolean a = systemSetttingDao.updateStaff(staff.get(0)); - boolean b = systemSetttingDao.addStaff(staff.get(1),staffVo.getUserId()); + StaffEntity staffEntity = staff.get(1); + staffEntity.setUserId(staffVo.getUserId()); + boolean b = systemSetttingDao.addStaffUpdata(staffEntity); if (!a|!b){throw new RuntimeException();} - }else{ + }else if (splitNew.length resultA = userInfoDao.queryAccount(account); + List resultA = userInfoDao.queryAccount(account); List resultW = systemSetttingDao.queryWorkNumber(workNumber); if (phone!=null&&phone!=""){ List resultP = userInfoDao.queryPhone(phone); @@ -225,7 +232,7 @@ public class SystemSettingServiceImpl implements SystemSetttingService { int size = staffs.size(); Long ii = 1L; try { - for (int i = 0;i resultW = systemSetttingDao.queryWorkNumber(workNumber); - List resultA = userInfoDao.queryAccount(account); + List resultA = userInfoDao.queryAccount(account); List resultU = userInfoDao.queryUserInfo(staffVo); if (resultU.size()>0){//重复的数据 StaffExportVo vo = new StaffExportVo(); vo.setFailureMsg("用户信息已存在"); ++ii; - vo.setIndex(ii).setUserName(staff.getUserName()).setAccount(staff.getAccount()).setRole(staff.getRole()).setWorkNumber(staff.getWorkNumber()).setStaffGradeName(staff.getStaffGradeName()).setStaffProfessionalArchitectureName(staff.getStaffProfessionalArchitectureName()).setPhone(staff.getPhone()).setEmail(staff.getEmail()).setSchoolAppellationName(staff.getSchoolAppellationName()); + vo.setIndex(ii).setUserName(staffVo.getUserName()).setAccount(staffVo.getAccount()).setRole(staffVo.getRole()).setWorkNumber(staffVo.getWorkNumber()).setStaffGradeName(staffVo.getStaffGradeName()).setStaffProfessionalArchitectureName(staffVo.getStaffProfessionalArchitectureName()).setStaffGradeNameTwo(staffVo.getStaffGradeNameTwo()).setStaffProfessionalArchitectureNameTwo(staffVo.getStaffProfessionalArchitectureNameTwo()).setPhone(staffVo.getPhone()).setEmail(staffVo.getEmail()).setSchoolAppellationName(staffVo.getSchoolAppellationName()); staffs.remove(i); i--; + failVo1.add(vo); + continue; } if (resultW.size()>0){ StaffExportVo vo = new StaffExportVo(); vo.setFailureMsg("重复的工号"); ++ii; - vo.setIndex(ii).setUserName(staff.getUserName()).setAccount(staff.getAccount()).setRole(staff.getRole()).setWorkNumber(staff.getWorkNumber()).setStaffGradeName(staff.getStaffGradeName()).setStaffProfessionalArchitectureName(staff.getStaffProfessionalArchitectureName()).setPhone(staff.getPhone()).setEmail(staff.getEmail()).setSchoolAppellationName(staff.getSchoolAppellationName()); + vo.setIndex(ii).setUserName(staffVo.getUserName()).setAccount(staffVo.getAccount()).setRole(staffVo.getRole()).setWorkNumber(staffVo.getWorkNumber()).setStaffGradeName(staffVo.getStaffGradeName()).setStaffProfessionalArchitectureName(staffVo.getStaffProfessionalArchitectureName()).setStaffGradeNameTwo(staffVo.getStaffGradeNameTwo()).setStaffProfessionalArchitectureNameTwo(staffVo.getStaffProfessionalArchitectureNameTwo()).setPhone(staffVo.getPhone()).setEmail(staffVo.getEmail()).setSchoolAppellationName(staffVo.getSchoolAppellationName()); staffs.remove(i); i--; + failVo1.add(vo); continue; }else if (resultA.size()>0){ StaffExportVo vo = new StaffExportVo(); vo.setFailureMsg("重复的账号"); ++ii; - vo.setIndex(ii).setUserName(staff.getUserName()).setAccount(staff.getAccount()).setRole(staff.getRole()).setWorkNumber(staff.getWorkNumber()).setStaffGradeName(staff.getStaffGradeName()).setStaffProfessionalArchitectureName(staff.getStaffProfessionalArchitectureName()).setPhone(staff.getPhone()).setEmail(staff.getEmail()).setSchoolAppellationName(staff.getSchoolAppellationName()); + vo.setIndex(ii).setUserName(staffVo.getUserName()).setAccount(staffVo.getAccount()).setRole(staffVo.getRole()).setWorkNumber(staffVo.getWorkNumber()).setStaffGradeName(staffVo.getStaffGradeName()).setStaffProfessionalArchitectureName(staffVo.getStaffProfessionalArchitectureName()).setStaffGradeNameTwo(staffVo.getStaffGradeNameTwo()).setStaffProfessionalArchitectureNameTwo(staffVo.getStaffProfessionalArchitectureNameTwo()).setPhone(staffVo.getPhone()).setEmail(staffVo.getEmail()).setSchoolAppellationName(staffVo.getSchoolAppellationName()); staffs.remove(i); i--; + failVo1.add(vo); continue; }else if (phone!=null&&phone!=""){ List resultP = userInfoDao.queryPhone(phone); @@ -266,24 +277,36 @@ public class SystemSettingServiceImpl implements SystemSetttingService { StaffExportVo vo = new StaffExportVo(); vo.setFailureMsg("重复的手机号码"); ++ii; - vo.setIndex(ii).setUserName(staff.getUserName()).setAccount(staff.getAccount()).setRole(staff.getRole()).setWorkNumber(staff.getWorkNumber()).setStaffGradeName(staff.getStaffGradeName()).setStaffProfessionalArchitectureName(staff.getStaffProfessionalArchitectureName()).setPhone(staff.getPhone()).setEmail(staff.getEmail()).setSchoolAppellationName(staff.getSchoolAppellationName()); + vo.setIndex(ii).setUserName(staffVo.getUserName()).setAccount(staffVo.getAccount()).setRole(staffVo.getRole()).setWorkNumber(staffVo.getWorkNumber()).setStaffGradeName(staffVo.getStaffGradeName()).setStaffProfessionalArchitectureName(staffVo.getStaffProfessionalArchitectureName()).setStaffGradeNameTwo(staffVo.getStaffGradeNameTwo()).setStaffProfessionalArchitectureNameTwo(staffVo.getStaffProfessionalArchitectureNameTwo()).setPhone(staffVo.getPhone()).setEmail(staffVo.getEmail()).setSchoolAppellationName(staffVo.getSchoolAppellationName()); staffs.remove(i); i--; + failVo1.add(vo); continue; } } ++ii; if (!staffs.isEmpty()&&staffs.size()>0){ - staffVo.setPassword(ConstantUtils.INITIAL_PASSWORD); + staffVo.setPassword(ConstantUtils.INITIAL_PASSWORD).setUniqueIdentificationAccount(String.valueOf(System.currentTimeMillis())); userInfoDao.addUserinfo(staffVo); staff.setPlatformId(ConstantUtils.PLATFORMID).setUserId(staffVo.getUserId()); - boolean b = systemSetttingDao.addStaff(staff); - if(!b){ - throw new RuntimeException(); - } + String[] split = staffVo.getRoleId().split(","); + for (String str : split){ + if (Integer.parseInt(str)==2){ + Integer gradeId = systemSetttingDao.queryDepartmentNameGrade(staffVo.getStaffGradeName(),ConstantUtils.Keda_schoolId); + Integer organizationId = systemSetttingDao.queryDepartmentNameOrganization(staffVo.getStaffProfessionalArchitectureName(),ConstantUtils.Keda_schoolId); + staffVo.setStaffGradeId(gradeId).setStaffProfessionalArchitectureId(organizationId); + boolean b = systemSetttingDao.addStaffManager(staffVo); + if(!b){throw new RuntimeException();} + }else if (Integer.parseInt(str)==3){ + Integer organizationId = systemSetttingDao.queryDepartmentNameOrganization(staffVo.getStaffProfessionalArchitectureNameTwo(),ConstantUtils.Keda_schoolId); + Integer gradeId = systemSetttingDao.queryDepartmentNameGrade(staffVo.getStaffGradeNameTwo(),organizationId); + staffVo.setStaffGradeId(gradeId).setStaffProfessionalArchitectureId(organizationId); + boolean b = systemSetttingDao.addStaffTeacher(staffVo); + if(!b){throw new RuntimeException();} + } + } } - } }catch (RuntimeException e){ e.printStackTrace(); @@ -326,7 +349,10 @@ public class SystemSettingServiceImpl implements SystemSetttingService { //2.加载模板流数据 org.springframework.core.io.Resource resource = new ClassPathResource("excel-template/员工信息导入失败模板.xlsx"); +// org.springframework.core.io.Resource resource = new FileSystemResource("E:/JavaworkSpace2/msdw_tms/src/main/resources/excel-template/员工信息导入失败模板.xlsx"); InputStream inputStream = resource.getInputStream(); +// InputStream inputStream = new FileInputStream("E:/JavaworkSpace2/msdw_tms/src/main/resources/excel-template/员工信息导入失败模板.xlsx"); + //3、通过工具类下载文件 new ExcelExportUtil(StaffExportVo.class, Constant.ROW_INDEX, Constant.STYLE_INDEX). diff --git a/src/main/resources/excel-template/员工信息导入失败模板.xlsx b/src/main/resources/excel-template/员工信息导入失败模板.xlsx index 04bf779..d6cb0bc 100644 Binary files a/src/main/resources/excel-template/员工信息导入失败模板.xlsx and b/src/main/resources/excel-template/员工信息导入失败模板.xlsx differ diff --git a/src/main/resources/excel-template/员工信息导入模板.xlsx b/src/main/resources/excel-template/员工信息导入模板.xlsx index 6acd2c6..e4d75db 100644 Binary files a/src/main/resources/excel-template/员工信息导入模板.xlsx and b/src/main/resources/excel-template/员工信息导入模板.xlsx differ diff --git a/src/main/resources/mapper/tms/StudentDao.xml b/src/main/resources/mapper/tms/StudentDao.xml index 48d33a5..82024eb 100644 --- a/src/main/resources/mapper/tms/StudentDao.xml +++ b/src/main/resources/mapper/tms/StudentDao.xml @@ -12,7 +12,7 @@ u.logInNumber, u.schoolAppellationId, u.disableAccount, - lastLoginTime, + u.lastLoginTime, s.roleId, s.workNumber, s.isdel , diff --git a/src/main/resources/mapper/tms/SystemSetting.xml b/src/main/resources/mapper/tms/SystemSetting.xml index 23ed521..d71c596 100644 --- a/src/main/resources/mapper/tms/SystemSetting.xml +++ b/src/main/resources/mapper/tms/SystemSetting.xml @@ -22,14 +22,29 @@ VALUES (#{userId},#{schoolId},#{workNumber},#{staffGradeId},#{staffProfessionalArchitectureId},#{staffGradeName},#{staffProfessionalArchitectureName},#{platformId},#{roleId}) + + INSERT INTO staff (userId,schoolId,workNumber,staffGradeId,staffProfessionalArchitectureId,staffGradeName,staffProfessionalArchitectureName,platformId,roleId) + VALUES + (#{userId},#{schoolId},#{workNumber},#{staffGradeId},#{staffProfessionalArchitectureId},#{staffGradeName},#{staffProfessionalArchitectureName},#{platformId},2) + + + INSERT INTO staff (userId,schoolId,workNumber,staffGradeId,staffProfessionalArchitectureId,staffGradeName,staffProfessionalArchitectureName,platformId,roleId) + VALUES + (#{userId},#{schoolId},#{workNumber},#{staffGradeId},#{staffProfessionalArchitectureId},#{staffGradeNameTwo},#{staffProfessionalArchitectureNameTwo},#{platformId},3) + + + INSERT INTO staff (userId,schoolId,workNumber,staffGradeId,staffProfessionalArchitectureId,staffGradeName,staffProfessionalArchitectureName,platformId,roleId) + VALUES + (#{userId},#{schoolId},#{workNumber},#{staffGradeId},#{staffProfessionalArchitectureId},#{staffGradeName},#{staffProfessionalArchitectureName},#{platformId},#{roleId}) + UPDATE staff - =#{workNumber} - staffProfessionalArchitectureId=#{staffProfessionalArchitectureId} - staffProfessionalArchitectureName=#{staffProfessionalArchitectureName} - staffGradeId=#{staffGradeId} - staffGradeName=#{staffGradeName} + workNumber=#{workNumber}, + staffProfessionalArchitectureId=#{staffProfessionalArchitectureId}, + staffProfessionalArchitectureName=#{staffProfessionalArchitectureName}, + staffGradeId=#{staffGradeId}, + staffGradeName=#{staffGradeName}, roleId=#{roleId} WHERE @@ -53,11 +68,11 @@ UPDATE staff - =#{workNumber} - staffProfessionalArchitectureId=#{staffProfessionalArchitectureId} - staffProfessionalArchitectureName=#{staffProfessionalArchitectureName} - staffGradeId=#{staffGradeId} - staffGradeName=#{staffGradeName} + =#{workNumber}, + staffProfessionalArchitectureId=#{staffProfessionalArchitectureId}, + staffProfessionalArchitectureName=#{staffProfessionalArchitectureName}, + staffGradeId=#{staffGradeId}, + staffGradeName=#{staffGradeName}, roleId=#{roleId} WHERE @@ -77,6 +92,7 @@ u.logInNumber, u.lastLoginTime, u.schoolId, + s.staffId, s.workNumber, s.staffProfessionalArchitectureId, s.staffProfessionalArchitectureName, @@ -87,9 +103,14 @@ LEFT JOIN staff s ON u.userId = s.userId WHERE s.schoolId = #{schoolId} + AND + u.isdel=0 + AND + s.isdel=0 AND (u.userName LIKE CONCAT('%',#{searchContent},'%') OR s.workNumber LIKE CONCAT('%',#{searchContent},'%')) AND FIND_IN_SET(staffGradeId,#{staffGradeIds}) AND FIND_IN_SET(staffProfessionalArchitectureId,#{staffProfessionalArchitectureIds}) + GROUP BY s.userId ORDER BY u.lastLoginTime DESC,creationTime DESC + + + \ No newline at end of file diff --git a/src/main/resources/mapper/tms/UserInfoDao.xml b/src/main/resources/mapper/tms/UserInfoDao.xml index 4d628ee..9ffced5 100644 --- a/src/main/resources/mapper/tms/UserInfoDao.xml +++ b/src/main/resources/mapper/tms/UserInfoDao.xml @@ -81,7 +81,7 @@ - SELECT roleId FROM @@ -99,6 +99,16 @@ and isdel = 0 +