diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CommonGridIdFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CommonGridIdFormDTO.java new file mode 100644 index 0000000000..936aa4312b --- /dev/null +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CommonGridIdFormDTO.java @@ -0,0 +1,29 @@ +package com.epmet.dto.form; + +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.io.Serializable; + +/** + * @Description + * @ClassName CommonGridIdFormDTO + * @Author wangc + * @date 2020.04.24 14:17 + */ +@Data +public class CommonGridIdFormDTO implements Serializable { + private static final long serialVersionUID = 2496019865436084805L; + + /** + * 网格Id + * */ + @NotBlank(message = "网格Id不能为空") + private String gridId; + + /** + * 用户Id + * */ + @NotBlank(message = "用户Id不能为空") + private String userId; +} diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridFormDTO.java index c3c237e83a..c34d3c5870 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridFormDTO.java @@ -38,5 +38,4 @@ public class CustomerGridFormDTO implements Serializable { @NotBlank(message = "网格ID不能为空") private String gridId; - } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffAgencyController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffAgencyController.java index fa1976bf6d..1f6904f416 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffAgencyController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffAgencyController.java @@ -17,7 +17,9 @@ package com.epmet.controller; +import com.epmet.commons.tools.annotation.LoginUser; import com.epmet.commons.tools.page.PageData; +import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.ExcelUtils; import com.epmet.commons.tools.utils.Result; import com.epmet.commons.tools.validator.AssertUtils; @@ -26,6 +28,9 @@ import com.epmet.commons.tools.validator.group.AddGroup; import com.epmet.commons.tools.validator.group.UpdateGroup; import com.epmet.commons.tools.validator.group.DefaultGroup; import com.epmet.dto.CustomerStaffAgencyDTO; +import com.epmet.dto.form.CommonGridIdFormDTO; +import com.epmet.dto.form.CustomerGridFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.dto.result.LatestCustomerResultDTO; import com.epmet.excel.CustomerStaffAgencyExcel; import com.epmet.service.CustomerStaffAgencyService; @@ -103,5 +108,4 @@ public class CustomerStaffAgencyController { public Result getLatestCustomer(@PathVariable("userId") String userId) { return customerStaffAgencyService.getLatestCustomer(userId); } - } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java index 2f2b919b20..8367b6fc95 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java @@ -1,15 +1,25 @@ package com.epmet.controller; +import com.epmet.commons.tools.annotation.LoginUser; +import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.validator.ValidatorUtils; +import com.epmet.dto.form.CommonAgencyIdFormDTO; +import com.epmet.dto.form.CommonGridIdFormDTO; import com.epmet.dto.form.CustomerGridFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.dto.result.GridDetailResultDTO; +import com.epmet.dto.result.GridListInfoResultDTO; import com.epmet.service.CustomerGridService; +import com.epmet.service.CustomerStaffAgencyService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; +import java.util.List; + /** * @Auther zxc * @Create 2020-04-23 9:50 @@ -21,6 +31,8 @@ public class GridController { @Autowired private CustomerGridService customerGridService; + @Autowired + private CustomerStaffAgencyService customerStaffAgencyService; @PostMapping("griddetail") public Result griddetail(@RequestBody CustomerGridFormDTO customerGridFormDTO){ Result griddetail = customerGridService.griddetail(customerGridFormDTO); @@ -33,4 +45,31 @@ public class GridController { @PostMapping("deletegrid")*/ + /** + * @Description 查找指定机构下的网格列表 + * @Param CommonAgencyIdFormDTO -> gridId + * @return Result + * @Author wangc + * @Date 2020.04.23 14:45 + **/ + @PostMapping("gridlist") + public Result gridList(@LoginUser TokenDto tokenDto,@RequestBody CommonAgencyIdFormDTO agencyFormDTO){ + agencyFormDTO.setAgencyId(tokenDto.getUserId()); + ValidatorUtils.validateEntity(agencyFormDTO); + return customerGridService.getGridListByAgency(agencyFormDTO); + } + + /** + * @Description 在给网格添加工作人员时,查询当前机关下没有加入到此网格下的工作人员,禁用的也不能选(不显示) + * @Param CommonGridIdFormDTO + * @return Result> + * @Author wangc + * @Date 2020.04.24 14:14 + **/ + @PostMapping("selectablestaffs") + public Result> selectableStaffs(@LoginUser TokenDto tokenDto, @RequestBody CommonGridIdFormDTO gridIdFormDTO){ + gridIdFormDTO.setUserId(tokenDto.getUserId()); + ValidatorUtils.validateEntity(gridIdFormDTO); + return customerStaffAgencyService.getSelectableStaffs(gridIdFormDTO); + } } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffAgencyDao.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffAgencyDao.java index 828c6cdd98..4691c4ed9b 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffAgencyDao.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffAgencyDao.java @@ -19,8 +19,12 @@ package com.epmet.dao; import com.epmet.commons.mybatis.dao.BaseDao; import com.epmet.dto.CustomerStaffAgencyDTO; +import com.epmet.dto.form.CustomerGridFormDTO; import com.epmet.entity.CustomerStaffAgencyEntity; import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; + +import java.util.List; /** * 人员-机关单位关系表 @@ -37,5 +41,14 @@ public interface CustomerStaffAgencyDao extends BaseDao UserId列表 + * @Author wangc + * @Date 2020.04.24 14:01 + **/ + List getSelectableStaffsForGrid(@Param("gridId") String gridId); } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/EpmetUserFeignClient.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/EpmetUserFeignClient.java index 1774a21c15..f17f3e6261 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/EpmetUserFeignClient.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/EpmetUserFeignClient.java @@ -5,6 +5,8 @@ import com.epmet.commons.tools.utils.Result; import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffGridListDTO; +import com.epmet.dto.form.CommonUserIdListFormList; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.feign.fallback.EpmetUserFeignClientFallBack; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.PostMapping; @@ -33,4 +35,13 @@ public interface EpmetUserFeignClient { @PostMapping("/epmetuser/customerstaff/selectstaffgridlistbyuserid") Result> getStaffGridList(@RequestBody List customerStaffGridDTOS); + /** + * @Description 通过userId列表查询未被禁用的用户信息 + * @Param CommonUserIdListFormList :: getUserIdList + * @return Result> + * @Author wangc + * @Date 2020.04.24 15:44 + **/ + @PostMapping("/epmetuser/customerstaff/enabestaffmsglist") + Result> enableStaffMsgList(CommonUserIdListFormList userIdList); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/fallback/EpmetUserFeignClientFallBack.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/fallback/EpmetUserFeignClientFallBack.java index 05b26449b3..d8940ede62 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/fallback/EpmetUserFeignClientFallBack.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/feign/fallback/EpmetUserFeignClientFallBack.java @@ -6,6 +6,8 @@ import com.epmet.commons.tools.utils.Result; import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffGridListDTO; +import com.epmet.dto.form.CommonUserIdListFormList; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.feign.EpmetUserFeignClient; import org.springframework.stereotype.Component; @@ -25,4 +27,9 @@ public class EpmetUserFeignClientFallBack implements EpmetUserFeignClient { public Result> getStaffGridList(List customerStaffGridDTOS) { return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "getStaffGridList", customerStaffGridDTOS); } + + @Override + public Result> enableStaffMsgList(CommonUserIdListFormList userIdList) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "enableStaffMsgList", userIdList); + } } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffAgencyService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffAgencyService.java index 2aaee92578..4f531dc929 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffAgencyService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffAgencyService.java @@ -21,6 +21,8 @@ import com.epmet.commons.mybatis.service.BaseService; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.utils.Result; import com.epmet.dto.CustomerStaffAgencyDTO; +import com.epmet.dto.form.CommonGridIdFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.dto.result.LatestCustomerResultDTO; import com.epmet.entity.CustomerStaffAgencyEntity; @@ -102,4 +104,13 @@ public interface CustomerStaffAgencyService extends BaseService getLatestCustomer(String userId); + + /** + * @Description 获取添加网格成员的可选人员列表 + * @Param CommonGridIdFormDTO + * @return com.epmet.dto.result.CommonStaffInfoResultDTO[epmet-user-client] + * @Author wangc + * @Date 2020.04.23 16:15 + **/ + Result> getSelectableStaffs(CommonGridIdFormDTO gridIdFormDTO); } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java index 2199eda56d..cf5285b735 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java @@ -106,13 +106,4 @@ public interface CustomerStaffGridService extends BaseService getStaffGridOrderByGridName(LatestGridFormDTO latestGridFormDTO); - - /** - * @Description 获取添加网格成员的可选人员列表 - * @Param CustomerGridFormDTO - * @return com.epmet.dto.result.CommonStaffInfoResultDTO[epmet-user-client] - * @Author wangc - * @Date 2020.04.23 16:15 - **/ - Result> getSelectableStaffs(CustomerGridFormDTO customerGridFormDTO); } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java index 212e5246a1..df4c0114a5 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java @@ -20,6 +20,7 @@ package com.epmet.service.impl; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.utils.ConvertUtils; import com.epmet.commons.tools.constant.FieldConstant; @@ -28,6 +29,9 @@ import com.epmet.dao.CustomerStaffAgencyDao; import com.epmet.dto.CustomerDTO; import com.epmet.dto.CustomerStaffAgencyDTO; import com.epmet.dto.CustomerStaffDTO; +import com.epmet.dto.form.CommonGridIdFormDTO; +import com.epmet.dto.form.CommonUserIdListFormList; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.dto.result.LatestCustomerResultDTO; import com.epmet.entity.CustomerStaffAgencyEntity; import com.epmet.feign.EpmetUserFeignClient; @@ -39,6 +43,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.Map; @@ -133,4 +138,24 @@ public class CustomerStaffAgencyServiceImpl extends BaseServiceImpl().ok(resultDTO); } + /** + * @Description 获取添加网格成员的可选人员列表,先在本服务下查询userId,然后调用EpmetUserFeign校验账户是否被禁用,使用EpmetUser服务的DTO作为返回参数 + * @Param CustomerGridFormDTO -> gridId + * @return Result> -> CommonStaffInfoResultDTO [epmet-user-client] + * @Author wangc + * @Date 2020.04.23 16:28 + **/ + @Override + public Result> getSelectableStaffs(CommonGridIdFormDTO customerGridFormDTO) { + //1.去数据库查询是此网格所属机构且不在此网格下的工作人员,这里无法确认是否被禁用 + List userId = baseDao.getSelectableStaffsForGrid(customerGridFormDTO.getGridId()); + //2.去用户服务下拿取用户基本信息,并校验工作人员身份是否被禁用 + if(null != userId && userId.size() >= NumConstant.ONE){ + //直接返回结果 + return epmetUserFeignClient.enableStaffMsgList(new CommonUserIdListFormList(userId)); + + } + return new Result>().ok(new ArrayList<>()); + } + } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java index 0f63802be7..4bdf464241 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java @@ -127,18 +127,4 @@ public class CustomerStaffGridServiceImpl extends BaseServiceImpl().ok(result); } - - /** - * @Description 获取添加网格成员的可选人员列表,先在本服务下查询userId,然后调用EpmetUserFeign校验账户是否被禁用,使用EpmetUser服务的DTO作为返回参数 - * @Param CustomerGridFormDTO -> gridId - * @return Result> -> CommonStaffInfoResultDTO [epmet-user-client] - * @Author wangc - * @Date 2020.04.23 16:28 - **/ - @Override - public Result> getSelectableStaffs(CustomerGridFormDTO customerGridFormDTO) { - - return null; - } - } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml index b58526d55f..d0dbc092e2 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml @@ -141,27 +141,29 @@ \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffAgencyDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffAgencyDao.xml index 016f75962a..77a21938b0 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffAgencyDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffAgencyDao.xml @@ -29,4 +29,35 @@ LIMIT 1 + + + + + + \ No newline at end of file diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/CommonUserIdListFormList.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/CommonUserIdListFormList.java new file mode 100644 index 0000000000..86c49a60c9 --- /dev/null +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/CommonUserIdListFormList.java @@ -0,0 +1,26 @@ +package com.epmet.dto.form; + +import lombok.AllArgsConstructor; +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.io.Serializable; +import java.util.List; + +/** + * @Description 通用用户Id列表参数DTO + * @ClassName CommonUserIdListFormList + * @Author wangc + * @date 2020.04.24 15:42 + */ +@Data +@AllArgsConstructor +public class CommonUserIdListFormList implements Serializable{ + private static final long serialVersionUID = -7045691156972928671L; + + /** + * 用户列表 + * */ + @NotBlank(message = "用户列表不能为空") + private List userIdList; +} diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/CommonStaffInfoResultDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/CommonStaffInfoResultDTO.java index 69a668fc7a..f7b7f9b56e 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/CommonStaffInfoResultDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/CommonStaffInfoResultDTO.java @@ -17,15 +17,20 @@ public class CommonStaffInfoResultDTO implements Serializable { /** * 工作人员用户Id * */ - private String userId; + private String staffId; /** * 工作人员用户头像 * */ - private String userHeadPhoto; + private String staffHeadPhoto; /** * 工作人员用户显示昵称 * */ - private String userShowName; + private String staffName; + + /** + * 性别 1男2女0未知 + * */ + private Integer gender; } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java index 103d4163fc..683c7eaeed 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java @@ -28,8 +28,10 @@ import com.epmet.commons.tools.validator.group.UpdateGroup; import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffGridListDTO; +import com.epmet.dto.form.CommonUserIdListFormList; import com.epmet.dto.form.CustomerGridFormDTO; import com.epmet.dto.form.CustomerStaffFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.excel.CustomerStaffExcel; import com.epmet.service.CustomerStaffService; import org.springframework.beans.factory.annotation.Autowired; @@ -143,4 +145,17 @@ public class CustomerStaffController { public Result getCustomerStaffInfoByUserId(CustomerStaffDTO formDTO) { return customerStaffService.getCustomerStaffInfoByUserId(formDTO); } + + /** + * @Description 通过userId列表查询未被禁用的用户信息 + * @Param CommonUserIdListFormList :: getUserIdList + * @return Result> + * @Author wangc + * @Date 2020.04.24 15:44 + **/ + @PostMapping(value = "enabestaffmsglist") + public Result> enableStaffMsgList(@RequestBody CommonUserIdListFormList userIdList){ + ValidatorUtils.validateEntity(userIdList); + return customerStaffService.getEnableStaffMsgList(userIdList); + } } \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java index 14d91f75e9..367fe51ec8 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java @@ -22,8 +22,10 @@ import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffGridListDTO; import com.epmet.dto.form.CustomerStaffFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.entity.CustomerStaffEntity; import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; import java.util.List; @@ -62,4 +64,13 @@ public interface CustomerStaffDao extends BaseDao { * @return */ List selectStaffGridListByUserId(List customerStaffGridDTOS); + + /** + * @Description 根据UserId列表查询用信息,过滤掉被禁用的,包含未激活的 + * @Param List + * @return List + * @Author wangc + * @Date 2020.04.24 15:34 + **/ + List selectEnableStaffMsg(@Param("userIds") List userIds); } \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java index 3775510742..05cfa0aed6 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java @@ -23,8 +23,10 @@ import com.epmet.commons.tools.utils.Result; import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffGridListDTO; +import com.epmet.dto.form.CommonUserIdListFormList; import com.epmet.dto.form.CustomerGridFormDTO; import com.epmet.dto.form.CustomerStaffFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.entity.CustomerStaffEntity; import java.util.List; @@ -132,4 +134,13 @@ public interface CustomerStaffService extends BaseService { * @return */ Result> selectStaffGridListByUserId(List customerStaffGridDTOS); + + /** + * @Description 通过userId列表查询未被禁用的用户信息 + * @Param CommonUserIdListFormList :: getUserIdList + * @return Result> + * @Author wangc + * @Date 2020.04.24 15:44 + **/ + Result> getEnableStaffMsgList(CommonUserIdListFormList userIdList); } \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 4ac6f5a529..2cc9e539c8 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -30,8 +30,10 @@ import com.epmet.dao.CustomerStaffDao; import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffGridListDTO; +import com.epmet.dto.form.CommonUserIdListFormList; import com.epmet.dto.form.CustomerGridFormDTO; import com.epmet.dto.form.CustomerStaffFormDTO; +import com.epmet.dto.result.CommonStaffInfoResultDTO; import com.epmet.entity.CustomerStaffEntity; import com.epmet.redis.CustomerStaffRedis; import com.epmet.service.CustomerStaffService; @@ -149,4 +151,16 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl>().ok(staffGridListDTOS); } + /** + * @Description 通过userId列表查询未被禁用的用户信息 + * @Param CommonUserIdListFormList :: getUserIdList + * @return Result> + * @Author wangc + * @Date 2020.04.24 15:44 + **/ + @Override + public Result> getEnableStaffMsgList(CommonUserIdListFormList userIdList) { + return new Result>().ok(baseDao.selectEnableStaffMsg(userIdList.getUserIdList())); + } + } \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml index 2e44e2b582..e13443bd23 100644 --- a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml +++ b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml @@ -41,4 +41,22 @@ AND cs.del_flag = 0 + + + \ No newline at end of file