Browse Source

Merge remote-tracking branch 'remotes/origin/dev'

dev_shibei_match
jianjun 4 years ago
parent
commit
3d6ff089ef
  1. 1
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerGridController.java
  2. 14
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java
  3. 45
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerGridDao.java
  4. 19
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerGridService.java
  5. 5
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerGridServiceImpl.java
  6. 13
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml
  7. 20
      epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/CustomerFootBarController.java
  8. 11
      epmet-user/epmet-user-server/src/main/java/com/epmet/feign/GovOrgFeignClient.java
  9. 5
      epmet-user/epmet-user-server/src/main/java/com/epmet/feign/fallback/GovOrgFeignClientFallBack.java
  10. 116
      epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/RegisterRelationServiceImpl.java
  11. 11
      epmet-user/epmet-user-server/src/main/resources/mapper/RegisterRelationDao.xml
  12. 4
      epmet-user/epmet-user-server/src/main/resources/mapper/UserBaseInfoDao.xml

1
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerGridController.java

@ -104,6 +104,7 @@ public class CustomerGridController {
public Result<CustomerGridDTO> getCustomerGridByGridId(@RequestBody CustomerGridFormDTO customerGridFormDTO) {
return customerGridService.getCustomerGridByGridId(customerGridFormDTO);
}
/**
* @Description 陌生人导览模块调用 根据陌生揽客传入的地区码进行分页查询显示
* @Param ListCustomerGridFormDTO

14
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java

@ -5,8 +5,9 @@ import com.epmet.commons.tools.annotation.RequirePermission;
import com.epmet.commons.tools.enums.RequirePermissionEnum;
import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.*;
import com.epmet.commons.tools.validator.ValidatorUtils;
import com.epmet.dto.CustomerGridDTO;
import com.epmet.dto.form.*;
import com.epmet.dto.result.*;
import com.epmet.service.CustomerGridService;
import com.epmet.service.CustomerStaffAgencyService;
@ -165,4 +166,15 @@ public class GridController {
public Result<List<OrgInfoResultDTO>> selectOrgInfo(@RequestBody OrgInfoFormDTO orgInfoFormDTO){
return new Result<List<OrgInfoResultDTO>>().ok(customerGridService.selectOrgInfo(orgInfoFormDTO));
}
/**
* 供epmet-user服务调用 查询客户网格表数据
* @author sun
* @param customerGridFormDTO
* @return
* @throws Exception
*/
@PostMapping("getbaseinfo")
public Result<CustomerGridDTO> getBaseInfo(@RequestBody CustomerGridFormDTO customerGridFormDTO) {
return customerGridService.getBaseInfo(customerGridFormDTO);
}
}

45
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerGridDao.java

@ -18,7 +18,6 @@
package com.epmet.dao;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.CustomerAgencyDTO;
import com.epmet.dto.CustomerGridDTO;
import com.epmet.dto.UserIdAndPidDTO;
import com.epmet.dto.UserIdDTO;
@ -60,11 +59,11 @@ public interface CustomerGridDao extends BaseDao<CustomerGridEntity> {
List<CustomerGridForStrangerResultDTO> selectRestGridWithoutGivenAreaCode(Map<String, Object> paramsMap);
/**
* @Description 通过gridId查询网格信息网格名称格式 上级组织名称-网格名称
* @param customerGridFormDTO
* @Description 通过gridId查询网格信息网格名称格式 上级组织名称-网格名称
* @author wangc
* @date 2020.04.30 13:57
**/
**/
CustomerGridDTO getCustomerGridByGridId(CustomerGridFormDTO customerGridFormDTO);
/**
@ -156,8 +155,8 @@ public interface CustomerGridDao extends BaseDao<CustomerGridEntity> {
List<AllGridsByUserIdResultDTO> selectGridByIds(@Param("gridIdList") List<String> gridIdList);
/**
* @Description 获取所属网格
* @param formDTO
* @Description 获取所属网格
* @author zxc
* @date 2020/5/11 18:50
*/
@ -178,12 +177,12 @@ public interface CustomerGridDao extends BaseDao<CustomerGridEntity> {
List<CustomerGridDTO> selectGridListByIds(@Param("gridIdList") List<String> gridIdList);
/**
* @Description 通过网格Id获取网格所需要的数据权限信息
* @param gridId
* @Description 通过网格Id获取网格所需要的数据权限信息
* @author wangc
* @date 2020.05.13 11:01
**/
CommonDataFilterResultDTO getGridDataFilterMsg(@Param("gridId")String gridId);
CommonDataFilterResultDTO getGridDataFilterMsg(@Param("gridId") String gridId);
/**
* @param agencyId
@ -218,41 +217,55 @@ public interface CustomerGridDao extends BaseDao<CustomerGridEntity> {
List<PublicCustomerGridForStrangerResultDTO> selectThirdRestGridWithoutGivenAreaCode(Map<String, Object> map);
/**
* @Description 查询当前客户已有网格数量
* @param customerId
* @Description 查询当前客户已有网格数量
* @author zxc
* @date 2020/8/12 5:10 下午
*/
Integer selectGridCount(@Param("customerId")String customerId);
Integer selectGridCount(@Param("customerId") String customerId);
/**
* 删除工作人员与网格关联
* @author zhaoqifeng
* @date 2020/8/28 15:32
*
* @param staffId
* @return void
* @author zhaoqifeng
* @date 2020/8/28 15:32
*/
void deleteGridStaff(@Param("staffId") String staffId);
/**
* 查询工作人员所在网格
* @author zhaoqifeng
* @date 2020/8/28 15:41
*
* @param staffId
* @return java.util.List<com.epmet.entity.CustomerGridEntity>
* @author zhaoqifeng
* @date 2020/8/28 15:41
*/
List<CustomerGridEntity> selectGridByStaff(@Param("staffId") String staffId);
List<OrgInfoResultDTO> selectOrgInfoByAgency(@Param("orgIds")List<String> orgIds);
List<OrgInfoResultDTO> selectOrgInfoByGrid(@Param("orgIds")List<String> orgIds);
List<OrgInfoResultDTO> selectOrgInfoByDept(@Param("orgIds")List<String> orgIds);
List<OrgInfoResultDTO> selectOrgInfoByAgency(@Param("orgIds") List<String> orgIds);
List<OrgInfoResultDTO> selectOrgInfoByGrid(@Param("orgIds") List<String> orgIds);
List<OrgInfoResultDTO> selectOrgInfoByDept(@Param("orgIds") List<String> orgIds);
/**
* @param gridId
* @return com.epmet.commons.tools.utils.Result<java.util.List<java.lang.String>>
* @return com.epmet.commons.tools.utils.Result<java.util.List < java.lang.String>>
* @Author zy
* @Description 根据 网格id查询同属于一个社区下的所有网格id
* @Date 2020/12/28 23:16
**/
List<String> selectListGridIdsInCommunity(@Param("gridId") String gridId);
/**
* desc: 根据网格Id获取网格基础信息 单表查询
*
* @param gridId
* @return com.epmet.commons.tools.utils.Result<com.epmet.dto.CustomerGridDTO>
* @author LiuJanJun
* @date 2021/4/19 11:56 上午
*/
CustomerGridDTO getGridBaseInfoById(@Param("gridId") String gridId);
}

19
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerGridService.java

@ -23,17 +23,8 @@ import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.CustomerGridDTO;
import com.epmet.dto.form.*;
import com.epmet.dto.result.AddGridResultDTO;
import com.epmet.dto.form.CommonAgencyIdFormDTO;
import com.epmet.dto.form.CustomerGridFormDTO;
import com.epmet.dto.form.ListCustomerGridFormDTO;
import com.epmet.dto.form.SelectGridNameByGridIdFormDTO;
import com.epmet.dto.result.CustomerGridForStrangerResultDTO;
import com.epmet.dto.result.SelectGridNameByGridIdResultDTO;
import com.epmet.dto.result.GridInfoResultDTO;
import com.epmet.dto.result.*;
import com.epmet.entity.CustomerGridEntity;
import org.springframework.web.bind.annotation.RequestBody;
import java.util.List;
import java.util.Map;
@ -286,4 +277,14 @@ public interface CustomerGridService extends BaseService<CustomerGridEntity> {
* @Date 2020/12/28 23:16
**/
List<String> listGridIdsInCommunity(String gridId);
/**
* desc: 获取网格基础数据单表查询
*
* @param customerGridFormDTO
* @return com.epmet.commons.tools.utils.Result<com.epmet.dto.CustomerGridDTO>
* @author LiuJanJun
* @date 2021/4/19 11:53 上午
*/
Result<CustomerGridDTO> getBaseInfo(CustomerGridFormDTO customerGridFormDTO);
}

5
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerGridServiceImpl.java

@ -696,4 +696,9 @@ public class CustomerGridServiceImpl extends BaseServiceImpl<CustomerGridDao, Cu
public List<String> listGridIdsInCommunity(String gridId) {
return baseDao.selectListGridIdsInCommunity(gridId);
}
@Override
public Result<CustomerGridDTO> getBaseInfo(CustomerGridFormDTO customerGridFormDTO) {
return new Result<CustomerGridDTO>().ok(baseDao.getGridBaseInfoById(customerGridFormDTO.getGridId()));
}
}

13
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml

@ -600,4 +600,17 @@
</if>
) AND DEL_FLAG = 0
</select>
<select id="getGridBaseInfoById" resultType="com.epmet.dto.CustomerGridDTO">
SELECT
cg.ID,
cg.GRID_NAME,
cg.PID,
cg.LONGITUDE,
cg.LATITUDE,
cg.AREA_CODE
FROM customer_grid cg
WHERE
cg.ID = #{gridId}
AND cg.DEL_FLAG = '0'
</select>
</mapper>

20
epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/CustomerFootBarController.java

@ -17,34 +17,35 @@
package com.epmet.controller;
import com.epmet.commons.tools.constant.StrConstant;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.redis.RedisKeys;
import com.epmet.commons.tools.redis.RedisUtils;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.utils.ExcelUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.commons.tools.validator.AssertUtils;
import com.epmet.commons.tools.validator.ValidatorUtils;
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.commons.tools.validator.group.UpdateGroup;
import com.epmet.dto.CustomerFootBarDTO;
import com.epmet.dto.form.CustomerFootBarFormDTO;
import com.epmet.dto.result.CustomerFootBarResultDTO;
import com.epmet.entity.CustomerFootBarEntity;
import com.epmet.excel.CustomerFootBarExcel;
import com.epmet.service.CustomerFootBarService;
import com.epmet.service.impl.CustomerFunctionDetailServiceImpl;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.CollectionUtils;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
/**
@ -127,12 +128,13 @@ public class CustomerFootBarController {
// 查询db
List<CustomerFootBarEntity> footbars = customerFootBarService.listCustomerFootBars(customerId, appType);
List<CustomerFootBarDTO> barDTOS = new LinkedList<>();
footbars.forEach(barEntity -> {
CustomerFootBarEntity defaultFootBarEntity = customerFootBarService.getByAppTypeAndBarKeyOfCustomer("default", barEntity.getAppType(), barEntity.getBarKey());
CustomerFootBarDTO barDTO = new CustomerFootBarDTO();
BeanUtils.copyProperties(barEntity, barDTO);
barDTO.setDefaultBarName(defaultFootBarEntity.getBarName());
List<CustomerFootBarEntity> defaultFootBarList = customerFootBarService.listCustomerFootBars("default", appType);
Map<String, String> defaultBarNameMaps = defaultFootBarList.stream().collect(Collectors.toMap(CustomerFootBarEntity::getBarKey, CustomerFootBarEntity::getBarName));
footbars.forEach(barEntity -> {
String defaultName = defaultBarNameMaps.getOrDefault(barEntity.getBarKey(), StrConstant.EPMETY_STR);
CustomerFootBarDTO barDTO = ConvertUtils.sourceToTarget(barEntity, CustomerFootBarDTO.class);
barDTO.setDefaultBarName(defaultName);
barDTOS.add(barDTO);
});
@ -253,4 +255,4 @@ public class CustomerFootBarController {
return new Result();
}
}
}

11
epmet-user/epmet-user-server/src/main/java/com/epmet/feign/GovOrgFeignClient.java

@ -39,4 +39,15 @@ public interface GovOrgFeignClient {
@PostMapping("/gov/org/customerstaffgrid/getgridstaffs")
Result<List<String>> getGridStaffs(@RequestBody CommonGridIdFormDTO gridIdFormDTO);
/**
* desc: 获取网格基础数据
*
* @param customerGridFormDTO
* @return com.epmet.commons.tools.utils.Result<com.epmet.dto.CustomerGridDTO>
* @author LiuJanJun
* @date 2021/4/19 11:19 上午
*/
@PostMapping("/gov/org/grid/getbaseinfo")
Result<CustomerGridDTO> getGridBaseInfoByGridId(CustomerGridFormDTO customerGridFormDTO);
}

5
epmet-user/epmet-user-server/src/main/java/com/epmet/feign/fallback/GovOrgFeignClientFallBack.java

@ -28,4 +28,9 @@ public class GovOrgFeignClientFallBack implements GovOrgFeignClient {
public Result<List<String>> getGridStaffs(CommonGridIdFormDTO gridIdFormDTO) {
return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "getGridStaffs", gridIdFormDTO);
}
@Override
public Result<CustomerGridDTO> getGridBaseInfoByGridId(CustomerGridFormDTO customerGridFormDTO) {
return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "getGridBaseInfoByGridId", customerGridFormDTO);
}
}

116
epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/RegisterRelationServiceImpl.java

@ -26,6 +26,7 @@ import com.epmet.commons.tools.constant.StrConstant;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.constant.UserConstant;
import com.epmet.constant.UserCustomerConstant;
import com.epmet.dao.*;
import com.epmet.dto.CustomerGridDTO;
@ -38,12 +39,10 @@ import com.epmet.dto.result.UserResiInfoResultDTO;
import com.epmet.dto.result.UserRoleResultDTO;
import com.epmet.entity.RegisterRelationEntity;
import com.epmet.entity.UserCustomerEntity;
import com.epmet.entity.UserWechatEntity;
import com.epmet.feign.GovOrgFeignClient;
import com.epmet.service.GridVisitedService;
import com.epmet.service.RegisterRelationService;
import com.epmet.util.ModuleConstant;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@ -61,13 +60,9 @@ import java.util.*;
*/
@Service
public class RegisterRelationServiceImpl extends BaseServiceImpl<RegisterRelationDao, RegisterRelationEntity> implements RegisterRelationService {
private static final Logger log = LoggerFactory.getLogger(RegisterRelationServiceImpl.class);
@Autowired
private UserWechatDao userWechatDao;
@Autowired
private UserResiInfoDao userResiInfoDao;
@ -159,7 +154,6 @@ public class RegisterRelationServiceImpl extends BaseServiceImpl<RegisterRelatio
final String gridId = enterGridFormDTO.getGridId();
//查询用户微信关系表
// List<UserWechatEntity> strangerWechatInfo = userWechatDao.selectByUserId(enterGridFormDTO.getUserId());
UserBaseInfoResultDTO strangerInfo = userBaseInfoDao.selectListByUserIdList(enterGridFormDTO.getUserId());
if(null != strangerInfo){
resultObj.setNickname(strangerInfo.getNickname());
@ -176,7 +170,6 @@ public class RegisterRelationServiceImpl extends BaseServiceImpl<RegisterRelatio
wrapper.eq(UserCustomerConstant.USER_ID,enterGridFormDTO.getUserId());
wrapper.eq(FieldConstant.DEL_FLAG,NumConstant.ZERO_STR);
//1.查找用户注册关系表,如果没有表示当前用户为陌生人(拉取用户微信表信息),如果有表示当前用户已经进行居民认证
if(null == registerRecords || registerRecords.size() <= 0){
//当前用户尚未注册过居民信息
@ -231,11 +224,6 @@ public class RegisterRelationServiceImpl extends BaseServiceImpl<RegisterRelatio
}else{
log.warn("不存在不同客户不同网格下用户注册记录数据,可能因为居民注册时没有成功记录register_relation信息");
//如果不存在不同客户不同网格数据,说明在居民注册时没有成功记录register_relation信息
//UserResiRegisterVisitDTO userResiRegisterVisitDTO = new UserResiRegisterVisitDTO();
//userResiRegisterVisitDTO.setDelFlag(NumConstant.ZERO);
//userResiRegisterVisitDTO.setUserId(enterGridFormDTO.getUserId());
//List<UserResiRegisterVisitDTO> UserResiRegisterVisitRecord =
// userResiRegisterVisitDao.selectUserResiRegisterVisit(userResiRegisterVisitDTO);
}
}
}
@ -251,7 +239,6 @@ public class RegisterRelationServiceImpl extends BaseServiceImpl<RegisterRelatio
resultObj.setNickname(userResiInfo.getShowName());
resultObj.setUserHeadPhoto(userResiInfo.getHeadPhoto());
}
// List<UserWechatEntity> userWechatEntityList=userWechatDao.selectByUserId(enterGridFormDTO.getUserId());
UserBaseInfoResultDTO userBaseInfo = userBaseInfoDao.selectListByUserIdList(enterGridFormDTO.getUserId());
if(null != userBaseInfo){
resultObj.setNickname(StringUtils.isNotBlank(userBaseInfo.getNickname())?userBaseInfo.getNickname(): StrConstant.EPMETY_STR);
@ -259,61 +246,78 @@ public class RegisterRelationServiceImpl extends BaseServiceImpl<RegisterRelatio
}
}
result.setData(resultObj);
VisitedFormDTO visitedFormDTO = setShowNameAndBuildVistedRecord(enterGridFormDTO, resultObj, strangerInfo);
//3.获取权限
UserRoleFormDTO userRoleFormDTO = new UserRoleFormDTO();
userRoleFormDTO.setUserId(enterGridFormDTO.getUserId());
userRoleFormDTO.setCustomerId(enterGridFormDTO.getCustomerId());
userRoleFormDTO.setGridId(enterGridFormDTO.getGridId());
List<UserRoleResultDTO> roleList = userRoleDao.getUserRoleInfo(userRoleFormDTO);
List<String> roleListString = new ArrayList<>();
for(UserRoleResultDTO role : roleList){
roleListString.add(role.getRoleKey());
setUserRoleList(enterGridFormDTO, resultObj);
//4.去网格表中查询网格对应的名称
setGridName(resultObj, gridId);
if(!gridVisitedService.saveVisitedRecord(visitedFormDTO).success()){
log.warn(ModuleConstant.SAVE_VISITED_RECORD_FAILURE);
}
resultObj.setUserRoleList(roleListString);
//4.去网格表中查询网格对应的名称
return result;
}
/**
* 设置showName 并返回构建的 访问记录DTO
*/
private VisitedFormDTO setShowNameAndBuildVistedRecord(EnterGridFormDTO enterGridFormDTO, UserInfoOnEnterGridResultDTO resultObj, UserBaseInfoResultDTO strangerInfo) {
VisitedFormDTO visitedFormDTO = new VisitedFormDTO();
visitedFormDTO.setGridId(enterGridFormDTO.getGridId());
visitedFormDTO.setCustomerId(enterGridFormDTO.getCustomerId());
visitedFormDTO.setUserId(enterGridFormDTO.getUserId());
visitedFormDTO.setIsReg(NumConstant.ZERO_STR);
resultObj.setUserStreetName(StrConstant.EPMETY_STR);
if (strangerInfo != null){
if (StringUtils.isNotBlank(strangerInfo.getStreet()) && StringUtils.isNotBlank(strangerInfo.getSurname())){
String gender = null;
if (NumConstant.ONE_STR.equals(strangerInfo.getGender())) {
gender = UserConstant.MAN;
} else if (NumConstant.TWO_STR.equals(strangerInfo.getGender())) {
gender = UserConstant.WOMAN;
} else {
gender = UserConstant.MAN_WOMAN;
}
String leaderName = strangerInfo.getStreet().concat(StrConstant.HYPHEN).concat(strangerInfo.getSurname()).concat(gender);
resultObj.setUserStreetName(leaderName);
visitedFormDTO.setIsReg(NumConstant.ONE_STR);
}
}
return visitedFormDTO;
}
private boolean setGridName(UserInfoOnEnterGridResultDTO resultObj, String gridId) {
CustomerGridFormDTO customerGridFormDTO = new CustomerGridFormDTO();
customerGridFormDTO.setGridId(gridId);
Result<CustomerGridDTO> gridDTOResult =
govOrgFeignClient.getCustomerGridByGridId(customerGridFormDTO);
Result<CustomerGridDTO> gridDTOResult = govOrgFeignClient.getGridBaseInfoByGridId(customerGridFormDTO);
if(gridDTOResult.success() && null != gridDTOResult.getData()){
resultObj.setCurrentGridName(gridDTOResult.getData().getGridName());
}else{
//查询网格名称失败
log.warn(String.format("查找网格信息失败,网格Id:【%s】",gridId));
return false;
}
return true;
}
/*Result<CustomerDTO> customerResult =
operCrmFeignClient.get(enterGridFormDTO.getCustomerId());
if(customerResult.success() && null != customerResult.getData() && StringUtils.isNotBlank(customerResult.getData().getCustomerName())){
resultObj.setCurrentCustomerName(customerResult.getData().getCustomerName());
}else{
log.warn(ModuleConstant.CUSTOMER_INFO_NOT_FOUND);
}*/
result.setData(resultObj);
VisitedFormDTO visitedFormDTO = new VisitedFormDTO();
visitedFormDTO.setGridId(enterGridFormDTO.getGridId());
visitedFormDTO.setCustomerId(enterGridFormDTO.getCustomerId());
visitedFormDTO.setUserId(enterGridFormDTO.getUserId());
UserResiInfoFormDTO userResiParam = new UserResiInfoFormDTO();
userResiParam.setUserId(enterGridFormDTO.getUserId());
userResiParam.setCustomerId(enterGridFormDTO.getCustomerId());
UserResiInfoResultDTO resiResult =
userResiInfoDao.selectUserResiInfoDTO(userResiParam);
if(null == resiResult){
visitedFormDTO.setIsReg(NumConstant.ZERO_STR);
resultObj.setUserStreetName(ModuleConstant.EMPTY_STR);
}else{
visitedFormDTO.setIsReg(NumConstant.ONE_STR);
resultObj.setUserStreetName(resiResult.getShowName());
}
if(!gridVisitedService.saveVisitedRecord(visitedFormDTO).success()){
log.warn(ModuleConstant.SAVE_VISITED_RECORD_FAILURE);
private boolean setUserRoleList(EnterGridFormDTO enterGridFormDTO, UserInfoOnEnterGridResultDTO resultObj) {
UserRoleFormDTO userRoleFormDTO = new UserRoleFormDTO();
userRoleFormDTO.setUserId(enterGridFormDTO.getUserId());
userRoleFormDTO.setCustomerId(enterGridFormDTO.getCustomerId());
userRoleFormDTO.setGridId(enterGridFormDTO.getGridId());
List<UserRoleResultDTO> roleList = userRoleDao.getUserRoleInfo(userRoleFormDTO);
List<String> roleListString = new ArrayList<>();
for(UserRoleResultDTO role : roleList){
roleListString.add(role.getRoleKey());
}
return result;
resultObj.setUserRoleList(roleListString);
return true;
}
/**

11
epmet-user/epmet-user-server/src/main/resources/mapper/RegisterRelationDao.xml

@ -20,8 +20,13 @@
</resultMap>
<select id="getListByUserId" parameterType="string" resultType="com.epmet.entity.RegisterRelationEntity">
SELECT *
SELECT
CUSTOMER_ID,
GRID_ID,
USER_ID,
FIRST_REGISTER,
REGISTER,
PARTICIPATION
FROM
register_relation
WHERE
@ -78,4 +83,4 @@
</select>
</mapper>
</mapper>

4
epmet-user/epmet-user-server/src/main/resources/mapper/UserBaseInfoDao.xml

@ -44,8 +44,8 @@
FROM
user_base_info ubi
WHERE
ubi.DEL_FLAG = '0'
AND ubi.USER_ID = #{userId}
ubi.USER_ID = #{userId}
AND ubi.DEL_FLAG = '0'
</select>
<!-- 根据用户id获取user_wechat表微信用户基本信息 -->

Loading…
Cancel
Save