0318-海宁菜单调整+北仑客群部分开发
This commit is contained in:
@@ -117,4 +117,14 @@ public class GridCmpmController extends BaseController {
|
||||
public AjaxResult selectCustBaseInfoList(@RequestBody CustBaseInfo custBaseInfo) {
|
||||
return AjaxResult.success( gridCmpmCustService.selectCustInfoList (custBaseInfo)) ;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据网格类型获取客户经理列表
|
||||
*/
|
||||
@GetMapping("/managerList")
|
||||
@Log(title = "绩效网格-获取客户经理列表")
|
||||
@ApiOperation("获取客户经理列表")
|
||||
public AjaxResult getManagerListByGridType(@RequestParam String gridType) {
|
||||
return AjaxResult.success(gridCmpmService.getManagerListByGridType(gridType));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,11 +8,15 @@ import com.ruoyi.ibs.cmpm.domain.entity.GridCmpm;
|
||||
import com.ruoyi.ibs.cmpm.domain.vo.DwbRetailCustLevelManagerDetailVO;
|
||||
import com.ruoyi.ibs.cmpm.domain.vo.DwbRetailResultVO;
|
||||
import com.ruoyi.ibs.cmpm.domain.vo.GridCmpmClaimVO;
|
||||
import com.ruoyi.ibs.cmpm.domain.vo.GridCmpmVO;
|
||||
import com.ruoyi.ibs.customerselect.domain.CustBaseInfo;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.cursor.Cursor;
|
||||
import org.apache.ibatis.session.SqlSessionFactory;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Author 吴凯程
|
||||
@@ -60,6 +64,32 @@ public interface GridCmpmMapper {
|
||||
|
||||
List<String> selectManagerList();
|
||||
|
||||
/**
|
||||
* 根据网格类型和总行ID查询客户经理列表
|
||||
* @param gridType 网格类型(零售retail、对公corporate、对公账户corporate_account)
|
||||
* @param headId 总行ID
|
||||
* @return 客户经理列表(user_name, nick_name)
|
||||
*/
|
||||
List<Map<String, String>> getManagerListByGridType(@Param("gridType") String gridType, @Param("headId") String headId);
|
||||
|
||||
/**
|
||||
* 根据网格类型、总行ID和客户经理查询客户列表(分表查询,适用于客群导入)
|
||||
* @param gridType 网格类型
|
||||
* @param userName 客户经理柜员号
|
||||
* @param headId 总行ID
|
||||
* @return 客户列表
|
||||
*/
|
||||
List<GridCmpmVO> getCustomerListForImport(@Param("gridType") String gridType, @Param("userName") String userName, @Param("headId") String headId);
|
||||
|
||||
/**
|
||||
* 根据网格类型、总行ID和客户经理流式查询客户列表(使用Cursor,适用于大数据量场景)
|
||||
* @param gridType 网格类型
|
||||
* @param userName 客户经理柜员号
|
||||
* @param headId 总行ID
|
||||
* @return 客户列表游标
|
||||
*/
|
||||
Cursor<GridCmpmVO> getCustomerListForImportCursor(@Param("gridType") String gridType, @Param("userName") String userName, @Param("headId") String headId);
|
||||
|
||||
|
||||
// List<CustBaseInfo> selectCustInfoRetailFromGridCmpm(CustBaseInfo custBaseInfo);
|
||||
//
|
||||
|
||||
@@ -302,4 +302,26 @@ public class GridCmpmService {
|
||||
return changesMap;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据网格类型和总行ID查询客户经理列表
|
||||
* @param gridType 网格类型(零售retail、对公corporate、对公账户corporate_account)
|
||||
* @return 客户经理列表
|
||||
*/
|
||||
public List<Map<String, String>> getManagerListByGridType(String gridType) {
|
||||
String headId = SecurityUtils.getHeadId();
|
||||
return gridCmpmMapper.getManagerListByGridType(gridType, headId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据参数查询绩效网格客户列表(不依赖SecurityUtils,适用于异步线程)
|
||||
* 所有参数由调用者传入,不在方法内部获取用户上下文
|
||||
* @param gridType 网格类型
|
||||
* @param userName 客户经理柜员号
|
||||
* @param headId 总行ID
|
||||
* @return 客户列表
|
||||
*/
|
||||
public List<GridCmpmVO> selectManageListForImport(String gridType, String userName, String headId) {
|
||||
return gridCmpmMapper.getCustomerListForImport(gridType, userName, headId);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -80,6 +80,16 @@ public class DrawGridController extends BaseController {
|
||||
return getDataTable(gridList, page);
|
||||
}
|
||||
|
||||
@ApiOperation("获取网格列表(用于客群创建,简化查询)")
|
||||
@Log(title = "自定义绘制网格--获取网格列表(客群创建用)")
|
||||
@GetMapping("/simpleList")
|
||||
public R<List<DrawGridListVO>> getSimpleGridList(DrawGridListDTO drawGridListDTO) {
|
||||
drawGridListDTO.setUserName(SecurityUtils.getUsername());
|
||||
drawGridListDTO.setDeptId(SecurityUtils.getDeptId());
|
||||
List<DrawGridListVO> gridList = drawGridService.getSimpleGridList(drawGridListDTO);
|
||||
return R.ok(gridList);
|
||||
}
|
||||
|
||||
@ApiOperation("分页获取网格内客户列表")
|
||||
@Log(title = "自定义绘制网格--分页获取网格内客户列表")
|
||||
@GetMapping("/cust/list")
|
||||
|
||||
@@ -4,7 +4,9 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.ibs.draw.domain.dto.grid.DrawGridCustListDTO;
|
||||
import com.ruoyi.ibs.draw.domain.entity.DrawGridCustUserUnbind;
|
||||
import com.ruoyi.ibs.draw.domain.vo.DrawGridCustVO;
|
||||
import com.ruoyi.ibs.grid.domain.entity.RegionCustUser;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -18,5 +20,13 @@ public interface DrawGridCustUserUnbindMapper extends BaseMapper<DrawGridCustUse
|
||||
|
||||
List<DrawGridCustVO> getCustListByManager(DrawGridCustListDTO drawGridCustListDTO);
|
||||
|
||||
/**
|
||||
* 根据绘制网格ID查询所有客户(用于客群导入,拼接headId绕过拦截器)
|
||||
* @param gridId 绘制网格ID
|
||||
* @param headId 总行机构号前三位(用于拼接动态表名)
|
||||
* @return 客户列表
|
||||
*/
|
||||
List<RegionCustUser> selectCustByDrawGridId(@Param("gridId") Long gridId, @Param("headId") String headId);
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -3,6 +3,10 @@ package com.ruoyi.ibs.draw.mapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.ibs.draw.domain.entity.DrawGridShapeRelate;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Author 吴凯程
|
||||
@@ -10,4 +14,19 @@ import org.apache.ibatis.annotations.Mapper;
|
||||
**/
|
||||
@Mapper
|
||||
public interface DrawGridShapeRelateMapper extends BaseMapper<DrawGridShapeRelate> {
|
||||
|
||||
/**
|
||||
* 根据网格ID查询关联的图形(用于异步导入客群,原生SQL绕过拦截器)
|
||||
* @param gridId 网格ID
|
||||
* @return 图形关联列表
|
||||
*/
|
||||
List<DrawGridShapeRelate> selectByGridId(@Param("gridId") Long gridId);
|
||||
|
||||
/**
|
||||
* 根据网格ID查询所有客户(用于客群导入,直接拼接headId绕过拦截器)
|
||||
* @param gridId 网格ID
|
||||
* @param headId 部门代码(用于拼接动态表名)
|
||||
* @return 客户列表,包含 custId, custName, custType
|
||||
*/
|
||||
List<Map<String, Object>> selectCustListByGridId(@Param("gridId") Long gridId, @Param("headId") String headId);
|
||||
}
|
||||
|
||||
@@ -24,6 +24,13 @@ public interface DrawGridService {
|
||||
|
||||
List<DrawGridListVO> getGridList(DrawGridListDTO drawGridListDTO);
|
||||
|
||||
/**
|
||||
* 获取网格列表(用于客群创建,简化查询不统计客户数量)
|
||||
* @param drawGridListDTO 查询条件
|
||||
* @return 网格列表(不含客户数量)
|
||||
*/
|
||||
List<DrawGridListVO> getSimpleGridList(DrawGridListDTO drawGridListDTO);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -334,6 +334,15 @@ public class DrawGridServiceImpl implements DrawGridService {
|
||||
return gridList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DrawGridListVO> getSimpleGridList(DrawGridListDTO drawGridListDTO) {
|
||||
if (SecurityUtils.userRole().equals("manager")) {
|
||||
return drawGridMapper.getGridListByManager(drawGridListDTO);
|
||||
} else {
|
||||
return drawGridMapper.getGridList(drawGridListDTO);
|
||||
}
|
||||
}
|
||||
|
||||
private CustCountDTO getCustCountByGrid(Long gridId) {
|
||||
CustCountDTO custCountDTO = new CustCountDTO();
|
||||
LambdaQueryWrapper<DrawGridShapeRelate> queryWrapper = new LambdaQueryWrapper<>();
|
||||
|
||||
@@ -12,6 +12,7 @@ import com.ruoyi.ibs.grid.domain.dto.GridCustListDTO;
|
||||
import com.ruoyi.ibs.grid.domain.dto.RegionGridListDTO;
|
||||
import com.ruoyi.ibs.grid.domain.entity.RegionGrid;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionCustUserVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridGroupVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridListVO;
|
||||
import com.ruoyi.ibs.grid.mapper.RegionGridMapper;
|
||||
import com.ruoyi.ibs.grid.service.RegionGridListService;
|
||||
@@ -108,6 +109,14 @@ public class RegionGridListController extends BaseController {
|
||||
return AjaxResult.success("开始更新行社所有网格");
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询地理网格列表(专用于客群创建)
|
||||
*/
|
||||
@ApiOperation("查询地理网格列表(专用于客群创建)")
|
||||
@Log(title = "地理网格-查询地理网格列表(客群创建用)")
|
||||
@GetMapping("/groupList")
|
||||
public AjaxResult getRegionGridListForGroup(RegionGridListDTO dto) {
|
||||
return AjaxResult.success(regionGridListService.getRegionGridListForGroup(dto));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.ruoyi.ibs.grid.domain.vo;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 地理网格选择VO - 专用于客群创建时的网格选择
|
||||
* 只包含必要字段,提升查询效率
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Data
|
||||
public class RegionGridGroupVO implements Serializable {
|
||||
|
||||
/**
|
||||
* 网格主键
|
||||
*/
|
||||
@ApiModelProperty(value = "网格主键")
|
||||
private Long gridId;
|
||||
|
||||
/**
|
||||
* 网格名称
|
||||
*/
|
||||
@ApiModelProperty(value = "网格名称")
|
||||
private String gridName;
|
||||
}
|
||||
@@ -40,6 +40,13 @@ public interface RegionCustUserMapper extends BaseMapper<RegionCustUser> {
|
||||
|
||||
Long countCustInSecGrid(@Param("gridId") Long gridId, @Param("custType") String custType);
|
||||
|
||||
/**
|
||||
* 根据网格ID列表查询所有客户(用于异步导入客群,直接根据gridIds查询无需区分等级)
|
||||
* @param gridIds 网格ID列表
|
||||
* @param headId 总行机构号前三位(用于拼接动态表名)
|
||||
*/
|
||||
List<RegionCustUser> selectAllCustByGridIds(@Param("gridIds") List<Long> gridIds, @Param("headId") String headId);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ import com.ruoyi.ibs.grid.domain.dto.GridCustListDTO;
|
||||
import com.ruoyi.ibs.grid.domain.dto.RegionGridListDTO;
|
||||
import com.ruoyi.ibs.grid.domain.entity.RegionGrid;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridCustVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridGroupVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridListVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionUnbindVo;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
@@ -69,4 +70,10 @@ public interface RegionGridMapper extends BaseMapper<RegionGrid> {
|
||||
|
||||
List<Long> getSecGridIdByTopGridId(@Param("gridId") Long gridId);
|
||||
|
||||
/**
|
||||
* 查询地理网格列表(简化版)- 专用于客群创建
|
||||
* 只返回gridId和gridName,避免N+1查询问题
|
||||
*/
|
||||
List<RegionGridGroupVO> getRegionGridListForGroup(RegionGridListDTO regionGridListDTO);
|
||||
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ import com.ruoyi.ibs.grid.domain.entity.RegionCustUser;
|
||||
import com.ruoyi.ibs.grid.domain.entity.RegionGrid;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionCustUserVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridCustVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridGroupVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridListVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionUnbindVo;
|
||||
|
||||
@@ -36,11 +37,20 @@ public interface RegionGridListService {
|
||||
List<RegionGridListVO> getSecGridListByManager(RegionGridListDTO regionGridListDTO);
|
||||
|
||||
/**
|
||||
* 查询网格内所有客户(不限制客户类型,用于导入客群)
|
||||
* @param regionGrid 地理网格对象
|
||||
* @return 网格内所有客户列表
|
||||
* 根据网格ID列表批量查询所有客户(用于导入客群,优化版)
|
||||
* @param gridIds 网格ID列表
|
||||
* @param headId 总行机构号前三位(用于拼接动态表名)
|
||||
* @return 客户列表(去重)
|
||||
*/
|
||||
List<RegionCustUser> selectAllCustFromGrid(RegionGrid regionGrid);
|
||||
List<RegionCustUser> selectAllCustByGridIds(List<Long> gridIds, String headId);
|
||||
|
||||
/**
|
||||
* 查询地理网格列表(简化版)- 专用于客群创建
|
||||
* 只返回gridId和gridName,避免N+1查询问题
|
||||
* @param regionGridListDTO 查询条件
|
||||
* @return 网格列表(仅包含ID和名称)
|
||||
*/
|
||||
List<RegionGridGroupVO> getRegionGridListForGroup(RegionGridListDTO regionGridListDTO);
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ import com.ruoyi.ibs.grid.domain.dto.UnbindDTO;
|
||||
import com.ruoyi.ibs.grid.domain.entity.*;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionCustUserVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridCustVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridGroupVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionGridListVO;
|
||||
import com.ruoyi.ibs.grid.domain.vo.RegionUnbindVo;
|
||||
import com.ruoyi.ibs.grid.mapper.*;
|
||||
@@ -432,23 +433,33 @@ public class RegionGridListServiceImpl implements RegionGridListService {
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询网格内所有客户(不限制客户类型,用于导入客群)
|
||||
* @param regionGrid 地理网格对象
|
||||
* @return 网格内所有客户列表
|
||||
* 根据网格ID列表批量查询所有客户(用于导入客群,优化版)
|
||||
* @param gridIds 网格ID列表
|
||||
* @return 客户列表(去重)
|
||||
*/
|
||||
@Override
|
||||
public List<RegionCustUser> selectAllCustFromGrid(RegionGrid regionGrid) {
|
||||
LambdaQueryWrapper<RegionCustUser> queryWrapper = new LambdaQueryWrapper<>();
|
||||
// 根据网格等级判断使用一级还是二级网格ID查询
|
||||
if (regionGrid.getGridLevel().equals("1")) {
|
||||
queryWrapper.eq(RegionCustUser::getTopGridId, regionGrid.getGridId());
|
||||
} else if (regionGrid.getGridLevel().equals("2")) {
|
||||
queryWrapper.eq(RegionCustUser::getSecGridId, regionGrid.getGridId());
|
||||
} else {
|
||||
throw new ServiceException("无效的网格等级: " + regionGrid.getGridLevel());
|
||||
public List<RegionCustUser> selectAllCustByGridIds(List<Long> gridIds, String headId) {
|
||||
return regionCustUserMapper.selectAllCustByGridIds(gridIds, headId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询地理网格列表(简化版)- 专用于客群创建
|
||||
* 只返回gridId和gridName,避免N+1查询问题
|
||||
* @param regionGridListDTO 查询条件
|
||||
* @return 网格列表(仅包含ID和名称)
|
||||
*/
|
||||
@Override
|
||||
public List<RegionGridGroupVO> getRegionGridListForGroup(RegionGridListDTO regionGridListDTO) {
|
||||
// 设置当前用户部门ID用于权限过滤
|
||||
regionGridListDTO.setDeptId(SecurityUtils.getDeptId());
|
||||
|
||||
// 如果是总行用户,设置归属部室
|
||||
if (SecurityUtils.isHead()) {
|
||||
regionGridListDTO.setOpsDept(SecurityUtils.getOpsDept());
|
||||
}
|
||||
// 不限制客户类型,查询所有类型的客户
|
||||
return regionCustUserMapper.selectList(queryWrapper);
|
||||
|
||||
// 直接查询,一次SQL完成,无N+1问题
|
||||
return regionGridMapper.getRegionGridListForGroup(regionGridListDTO);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -41,6 +41,14 @@ public class CustInfoBusinessVo {
|
||||
@ApiModelProperty(value = "手动打标")
|
||||
private List<TreeNode> tagManual;
|
||||
|
||||
/** 九维画像分数 */
|
||||
@ApiModelProperty(value = "九维画像分数")
|
||||
private Ent9vPortraitOrc ent9vPortrait;
|
||||
|
||||
/** 九维画像详细信息 */
|
||||
@ApiModelProperty(value = "九维画像详细信息")
|
||||
private NineVFinalInfoOrc nineVFinalInfo;
|
||||
|
||||
public List<TreeNode> getTagManual() {
|
||||
return tagManual;
|
||||
}
|
||||
@@ -187,4 +195,20 @@ public class CustInfoBusinessVo {
|
||||
public void setTabEnmuVos(List<TreeNode> tabEnmuVos) {
|
||||
this.tabEnmuVos = tabEnmuVos;
|
||||
}
|
||||
|
||||
public Ent9vPortraitOrc getEnt9vPortrait() {
|
||||
return ent9vPortrait;
|
||||
}
|
||||
|
||||
public void setEnt9vPortrait(Ent9vPortraitOrc ent9vPortrait) {
|
||||
this.ent9vPortrait = ent9vPortrait;
|
||||
}
|
||||
|
||||
public NineVFinalInfoOrc getNineVFinalInfo() {
|
||||
return nineVFinalInfo;
|
||||
}
|
||||
|
||||
public void setNineVFinalInfo(NineVFinalInfoOrc nineVFinalInfo) {
|
||||
this.nineVFinalInfo = nineVFinalInfo;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
package com.ruoyi.ibs.list.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 企业九维画像分数对象 ent_9v_portrait_orc_825
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-03-18
|
||||
*/
|
||||
@Data
|
||||
@TableName("ent_9v_portrait_orc_825")
|
||||
public class Ent9vPortraitOrc implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 统一社会信用代码 */
|
||||
private String uniscid;
|
||||
|
||||
/** 客户内码 */
|
||||
private String cstId;
|
||||
|
||||
/** 机构号 */
|
||||
private String orgNo;
|
||||
|
||||
/** score_1合规经营 */
|
||||
private BigDecimal score1;
|
||||
|
||||
/** score_2风险准入 */
|
||||
private BigDecimal score2;
|
||||
|
||||
/** score_3高管信用评价 */
|
||||
private String score3;
|
||||
|
||||
/** score_4股东信用评价 */
|
||||
private BigDecimal score4;
|
||||
|
||||
/** score_5社会贡献度 */
|
||||
private BigDecimal score5;
|
||||
|
||||
/** score_6稳定经营 */
|
||||
private BigDecimal score6;
|
||||
|
||||
/** score_7经营能力 */
|
||||
private BigDecimal score7;
|
||||
|
||||
/** score_8偿债能力 */
|
||||
private BigDecimal score8;
|
||||
|
||||
/** score_9潜在代偿资源 */
|
||||
private BigDecimal score9;
|
||||
|
||||
/** 九维总分 */
|
||||
private BigDecimal scoreAll;
|
||||
|
||||
/** 九维总分排名 */
|
||||
private BigDecimal scoreAllRank;
|
||||
|
||||
/** 会计日期 */
|
||||
private String datDt;
|
||||
}
|
||||
@@ -0,0 +1,226 @@
|
||||
package com.ruoyi.ibs.list.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 企业九维画像详细信息对象 9v_final_info_orc_825
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-03-18
|
||||
*/
|
||||
@Data
|
||||
@TableName("9v_final_info_orc_825")
|
||||
public class NineVFinalInfoOrc implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 统一社会信用代码 */
|
||||
private String uniscid;
|
||||
|
||||
/** 机构号 */
|
||||
private String orgNo;
|
||||
|
||||
/** 是否存在经营异常名录信息 */
|
||||
private String score11;
|
||||
|
||||
/** 是否存在严重违法失信企业名单信息 */
|
||||
private String score12;
|
||||
|
||||
/** 企业环境行为信仰登记是否为"E"或D */
|
||||
private String score13;
|
||||
|
||||
/** 是否存在税务重大税收违法黑名单信息 */
|
||||
private String score14;
|
||||
|
||||
/** 是否存在拖欠工资黑名单 */
|
||||
private String score15;
|
||||
|
||||
/** 是否存在工商吊销企业信息 */
|
||||
private String score16;
|
||||
|
||||
/** 是否存在注销企业信息 */
|
||||
private String score21;
|
||||
|
||||
/** 是否存在执行案件信息 */
|
||||
private String score22;
|
||||
|
||||
/** 是否存在查封信息 */
|
||||
private String score23;
|
||||
|
||||
/** 是否存在单位未履行生效裁判信息 */
|
||||
private String score24;
|
||||
|
||||
/** 是否存在企业破产清算信息 */
|
||||
private String score25;
|
||||
|
||||
/** 是否失信被执行人 */
|
||||
private String score26;
|
||||
|
||||
/** 是否为诉讼案件被告 */
|
||||
private String score27;
|
||||
|
||||
/** 是否存在查封信息(score_3) */
|
||||
private String score31;
|
||||
|
||||
/** 是否存在执行案件信息(score_3) */
|
||||
private String score32;
|
||||
|
||||
/** 是否存在个人未履行生效裁判信息 */
|
||||
private String score33;
|
||||
|
||||
/** 是否存在拖欠工资黑名单(score_3) */
|
||||
private String score34;
|
||||
|
||||
/** 是否失信被执行人(score_3) */
|
||||
private String score35;
|
||||
|
||||
/** 是否存在刑事案件被告人生效判决信息 */
|
||||
private String score36;
|
||||
|
||||
/** 是否为诉讼案件被告(score_3) */
|
||||
private String score37;
|
||||
|
||||
/** 是否存在查封信息(score_4) */
|
||||
private String score41;
|
||||
|
||||
/** 是否存在执行案件信息(score_4) */
|
||||
private String score42;
|
||||
|
||||
/** 是否存在个人未履行生效裁判信息(score_4) */
|
||||
private String score43;
|
||||
|
||||
/** 是否存在拖欠工资黑名单(score_4) */
|
||||
private String score44;
|
||||
|
||||
/** 是否失信被执行人(score_4) */
|
||||
private String score45;
|
||||
|
||||
/** 是否存在刑事案件被告人生效判决信息(score_4) */
|
||||
private String score46;
|
||||
|
||||
/** 是否为诉讼案件被告(score_4) */
|
||||
private String score47;
|
||||
|
||||
/** 是否存在企业未履行生效裁判信息 */
|
||||
private String score48;
|
||||
|
||||
/** 前12个月纳税金额 */
|
||||
private String score51;
|
||||
|
||||
/** 纳税等级 */
|
||||
private String score52;
|
||||
|
||||
/** 缴纳社保人数 */
|
||||
private String score53;
|
||||
|
||||
/** 公积金缴纳人数 */
|
||||
private String score54;
|
||||
|
||||
/** 是否为出口退税生产清单企业 */
|
||||
private String score55;
|
||||
|
||||
/** 市场主体经营年限 */
|
||||
private String score61;
|
||||
|
||||
/** 股东(或发起人)或投资人信息认缴出资人数 */
|
||||
private String score62;
|
||||
|
||||
/** 最大股东持股占比 */
|
||||
private String score63;
|
||||
|
||||
/** 近三年法定代表人变更次数 */
|
||||
private String score64;
|
||||
|
||||
/** 近三年股东变更次数 */
|
||||
private String score65;
|
||||
|
||||
/** 近三年经营范围变更次数 */
|
||||
private String score66;
|
||||
|
||||
/** 近三年经营地址变更次数 */
|
||||
private String score67;
|
||||
|
||||
/** 近三年缴税年数 */
|
||||
private String score68;
|
||||
|
||||
/** 法人户籍 */
|
||||
private String score69;
|
||||
|
||||
/** 法人婚姻状况 */
|
||||
private String score610;
|
||||
|
||||
/** 上年增值税金额 */
|
||||
private String score71;
|
||||
|
||||
/** 今年增值税同比变动 */
|
||||
private String score72;
|
||||
|
||||
/** 上年企业所得税金额 */
|
||||
private String score73;
|
||||
|
||||
/** 今年所得税同比变动 */
|
||||
private String score74;
|
||||
|
||||
/** 缴纳社保人数同比变动 */
|
||||
private String score75;
|
||||
|
||||
/** 公积金缴纳人数同比变动 */
|
||||
private String score76;
|
||||
|
||||
/** 当年纳税金额同比变动 */
|
||||
private String score77;
|
||||
|
||||
/** 上年出口退税金额 */
|
||||
private String score78;
|
||||
|
||||
/** 房产套数 */
|
||||
private String score81;
|
||||
|
||||
/** 房产面积 */
|
||||
private String score82;
|
||||
|
||||
/** 未抵押房产套数 */
|
||||
private String score83;
|
||||
|
||||
/** 未抵押房产面积 */
|
||||
private String score84;
|
||||
|
||||
/** 已抵押房产被担保债权数额 */
|
||||
private String score85;
|
||||
|
||||
/** 企业车产金额 */
|
||||
private String score86;
|
||||
|
||||
/** 法人及股东房产面积合计 */
|
||||
private String score91;
|
||||
|
||||
/** 法人及股东房产套数合计 */
|
||||
private String score92;
|
||||
|
||||
/** 法人及股东未抵押房产套数合计 */
|
||||
private String score93;
|
||||
|
||||
/** 法人及股东未抵押房产面积 */
|
||||
private String score94;
|
||||
|
||||
/** 法人及股东已抵押房产被担保债权数额合计 */
|
||||
private String score95;
|
||||
|
||||
/** 法人代表车产金额 */
|
||||
private String score96;
|
||||
|
||||
/** 生态信用扣分 */
|
||||
private String scoreB015;
|
||||
|
||||
/** 列入环境失信黑名单时间 */
|
||||
private String scoreB016Time;
|
||||
|
||||
/** 列入环境失信黑名单原因 */
|
||||
private String scoreB016Reason;
|
||||
|
||||
/** 环境行为信用评价等级 */
|
||||
private String scoreA020;
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package com.ruoyi.ibs.list.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.ibs.list.domain.Ent9vPortraitOrc;
|
||||
|
||||
/**
|
||||
* 企业九维画像分数Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-03-18
|
||||
*/
|
||||
public interface Ent9vPortraitOrcMapper extends BaseMapper<Ent9vPortraitOrc> {
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package com.ruoyi.ibs.list.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.ibs.list.domain.NineVFinalInfoOrc;
|
||||
|
||||
/**
|
||||
* 企业九维画像详细信息Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-03-18
|
||||
*/
|
||||
public interface NineVFinalInfoOrcMapper extends BaseMapper<NineVFinalInfoOrc> {
|
||||
}
|
||||
@@ -24,7 +24,9 @@ import com.ruoyi.ibs.grid.util.CustExcelUtil;
|
||||
import com.ruoyi.ibs.list.domain.*;
|
||||
import com.ruoyi.ibs.list.mapper.CorporateShareholderMapper;
|
||||
import com.ruoyi.ibs.list.mapper.CustInfoRetailMapper;
|
||||
import com.ruoyi.ibs.list.mapper.Ent9vPortraitOrcMapper;
|
||||
import com.ruoyi.ibs.list.mapper.FamilyMembersMapper;
|
||||
import com.ruoyi.ibs.list.mapper.NineVFinalInfoOrcMapper;
|
||||
import com.ruoyi.ibs.list.mapper.SignedProductsMapper;
|
||||
import com.ruoyi.ibs.list.service.ICustInfoBusinessService;
|
||||
import com.ruoyi.system.mapper.SysIndustryMapper;
|
||||
@@ -75,6 +77,12 @@ public class CustInfoBusinessServiceImpl implements ICustInfoBusinessService
|
||||
@Autowired
|
||||
private FamilyMembersMapper familyMembersMapper;
|
||||
|
||||
@Autowired
|
||||
private Ent9vPortraitOrcMapper ent9vPortraitOrcMapper;
|
||||
|
||||
@Autowired
|
||||
private NineVFinalInfoOrcMapper nineVFinalInfoOrcMapper;
|
||||
|
||||
@Autowired
|
||||
private CustMapMapper custMapMapper;
|
||||
|
||||
@@ -138,6 +146,17 @@ public class CustInfoBusinessServiceImpl implements ICustInfoBusinessService
|
||||
//查询手动标签列表
|
||||
List<CustManualTagVO> tagCreateVos = familyMembersMapper.selectManualTag(params);
|
||||
custInfoBusinessVo.setTagManual(TreeNode.convertToTreeByParentId(tagCreateVos));
|
||||
|
||||
// 仅当登录机构为825时,查询九维画像数据
|
||||
// if ("825".equals(getHeadId())) {
|
||||
// LambdaQueryWrapper<Ent9vPortraitOrc> portraitWrapper = new LambdaQueryWrapper<>();
|
||||
// portraitWrapper.eq(Ent9vPortraitOrc::getUniscid, custInfoBusiness.getSocialCreditCode());
|
||||
// custInfoBusinessVo.setEnt9vPortrait(ent9vPortraitOrcMapper.selectOne(portraitWrapper));
|
||||
//
|
||||
// LambdaQueryWrapper<NineVFinalInfoOrc> finalInfoWrapper = new LambdaQueryWrapper<>();
|
||||
// finalInfoWrapper.eq(NineVFinalInfoOrc::getUniscid, custInfoBusiness.getSocialCreditCode());
|
||||
// custInfoBusinessVo.setNineVFinalInfo(nineVFinalInfoOrcMapper.selectOne(finalInfoWrapper));
|
||||
// }
|
||||
}
|
||||
return custInfoBusinessVo;
|
||||
}
|
||||
|
||||
@@ -131,4 +131,15 @@ public class WorkRecordController extends BaseController {
|
||||
return toAjax(workRecordService.updateReadTime(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有预警类型
|
||||
*/
|
||||
@GetMapping("/alter/types")
|
||||
@Log(title = "工作台-查询预警类型")
|
||||
@ApiOperation("查询所有预警类型")
|
||||
public AjaxResult getAlterTypes() {
|
||||
List<String> types = workRecordService.getAlterTypes();
|
||||
return AjaxResult.success(types);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -112,4 +112,12 @@ public interface WorkRecordMapper extends BaseMapper<WorkRecord> {
|
||||
List<AlterConfigVO> selectAlterConfigList(String alterType);
|
||||
|
||||
int updateAlterConfig(AlterConfig alterConfig);
|
||||
|
||||
/**
|
||||
* 查询所有预警类型
|
||||
*
|
||||
* @param headId 总部ID(部门ID前三位)
|
||||
* @return 预警类型列表
|
||||
*/
|
||||
List<String> selectAlterTypes(@Param("headId") String headId);
|
||||
}
|
||||
|
||||
@@ -85,4 +85,11 @@ public interface WorkRecordService{
|
||||
int updateReadTime(Long id);
|
||||
|
||||
AlterCountVO getAlterCount(Date reportTime);
|
||||
|
||||
/**
|
||||
* 查询所有预警类型
|
||||
*
|
||||
* @return 预警类型列表
|
||||
*/
|
||||
List<String> getAlterTypes();
|
||||
}
|
||||
|
||||
@@ -13,6 +13,7 @@ import java.util.stream.IntStream;
|
||||
|
||||
import com.github.pagehelper.Page;
|
||||
import com.ruoyi.common.core.page.TableDataPageInfo;
|
||||
import com.ruoyi.common.core.redis.RedisCache;
|
||||
import com.ruoyi.common.utils.PageUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.ibs.task.domain.dto.WorkRecordDTO;
|
||||
@@ -39,6 +40,8 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
@Service
|
||||
public class WorkRecordServiceImpl implements WorkRecordService {
|
||||
|
||||
private final static String alterTypesRedisKey = "work:record:alter:types";
|
||||
|
||||
@Autowired
|
||||
private WorkRecordMapper workRecordMapper;
|
||||
|
||||
@@ -48,6 +51,9 @@ public class WorkRecordServiceImpl implements WorkRecordService {
|
||||
@Autowired
|
||||
private ISysDeptService sysDeptService;
|
||||
|
||||
@Autowired
|
||||
private RedisCache redisCache;
|
||||
|
||||
/**
|
||||
* 查询我的工作清单
|
||||
*
|
||||
@@ -253,6 +259,19 @@ public class WorkRecordServiceImpl implements WorkRecordService {
|
||||
return alterCountVO;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getAlterTypes() {
|
||||
String headId = SecurityUtils.getHeadId();
|
||||
String cacheKey = alterTypesRedisKey + ":" + headId;
|
||||
List<String> cachedTypes = redisCache.getCacheObject(cacheKey);
|
||||
if (cachedTypes != null) {
|
||||
return cachedTypes;
|
||||
}
|
||||
List<String> types = workRecordMapper.selectAlterTypes(headId);
|
||||
redisCache.setCacheObjectToEndDay(cacheKey, types);
|
||||
return types;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取当前登录用户权限范围内所有post_ids
|
||||
* @return
|
||||
|
||||
@@ -193,7 +193,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
and status = #{status}
|
||||
</if>
|
||||
<if test="alterType != null and alterType != ''">
|
||||
and alter_type LIKE CONCAT('%', #{alterType}, '%')
|
||||
and alter_type = #{alterType}
|
||||
</if>
|
||||
</where>
|
||||
order by create_time desc, status asc
|
||||
@@ -232,7 +232,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
and wr.status = #{status}
|
||||
</if>
|
||||
<if test="alterType != null and alterType != ''">
|
||||
and wr.alter_type LIKE CONCAT('%', #{alterType}, '%')
|
||||
and wr.alter_type = #{alterType}
|
||||
</if>
|
||||
<!-- "走访异常提醒"类型直接通过用户名匹配,其他类型按角色权限处理 -->
|
||||
and ((wr.alter_type = '走访异常提醒' and wr.user_name = #{username}) or
|
||||
@@ -268,4 +268,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<select id="selectAlterTypes" resultType="string">
|
||||
select distinct alter_type
|
||||
from work_record
|
||||
where is_alter = 1
|
||||
and alter_type is not null
|
||||
and alter_type != ''
|
||||
and left(user_name, 3) = #{headId}
|
||||
order by alter_type
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
@@ -505,4 +505,26 @@
|
||||
where manager_id is not null
|
||||
</select>
|
||||
|
||||
<!-- 根据网格类型和总行ID查询客户经理列表 -->
|
||||
<select id="getManagerListByGridType" resultType="java.util.HashMap">
|
||||
select distinct user_name as userName, nick_name as nickName
|
||||
from grid_cmpm_${gridType}_${headId}
|
||||
where user_name is not null
|
||||
order by user_name
|
||||
</select>
|
||||
|
||||
<!-- 根据网格类型、总行ID和客户经理查询客户列表(分表查询,适用于客群导入)-->
|
||||
<select id="getCustomerListForImport" resultType="GridCmpmVO">
|
||||
select cust_id, cust_name, cust_type, cust_idc, usci
|
||||
from grid_cmpm_${gridType}_${headId}
|
||||
where user_name = #{userName}
|
||||
</select>
|
||||
|
||||
<!-- 根据网格类型、总行ID和客户经理流式查询客户列表(使用Cursor,适用于大数据量场景)-->
|
||||
<select id="getCustomerListForImportCursor" resultType="GridCmpmVO" fetchSize="1000">
|
||||
select cust_id, cust_name, cust_type, cust_idc, usci
|
||||
from grid_cmpm_${gridType}_${headId}
|
||||
where user_name = #{userName}
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
@@ -55,8 +55,17 @@
|
||||
<if test="custName != null and custName != ''">AND b.cust_name like concat('%', #{custName}, '%')</if>
|
||||
<if test="custType != null and custType != ''">AND b.cust_type = #{custType}</if>
|
||||
</select>
|
||||
<select id="">
|
||||
|
||||
<!-- 根据绘制网格ID查询所有客户(用于客群导入,直接拼接headId绕过拦截器) -->
|
||||
<select id="selectCustByDrawGridId" resultType="com.ruoyi.ibs.grid.domain.entity.RegionCustUser">
|
||||
SELECT DISTINCT
|
||||
sc.cust_id,
|
||||
sc.cust_name,
|
||||
sc.cust_type
|
||||
FROM grid_draw_shape_relate sr
|
||||
INNER JOIN draw_shape_cust_${headId} sc ON sc.shape_id = sr.shape_id
|
||||
WHERE sr.grid_id = #{gridId}
|
||||
AND sr.delete_flag = '0'
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
@@ -121,4 +121,30 @@
|
||||
WHERE sec_grid_id = #{gridId}
|
||||
AND cust_type = #{custType}
|
||||
</select>
|
||||
|
||||
<!-- 根据网格ID列表查询所有客户(一级或二级网格) -->
|
||||
<select id="selectAllCustByGridIds" resultType="RegionCustUser">
|
||||
SELECT DISTINCT cust_id, cust_name, cust_type
|
||||
FROM grid_region_cust_user_${headId}
|
||||
WHERE (top_grid_id IN
|
||||
<foreach collection="gridIds" item="gridId" index="index" open="(" separator="," close=")">
|
||||
#{gridId}
|
||||
</foreach>
|
||||
OR sec_grid_id IN
|
||||
<foreach collection="gridIds" item="gridId" index="index" open="(" separator="," close=")">
|
||||
#{gridId}
|
||||
</foreach>)
|
||||
</select>
|
||||
|
||||
<!-- 根据绘制网格ID查询所有客户(用于客群导入,直接拼接headId绕过拦截器) -->
|
||||
<select id="selectCustByDrawGridId" resultType="RegionCustUser">
|
||||
SELECT DISTINCT
|
||||
sc.cust_id,
|
||||
sc.cust_name,
|
||||
sc.cust_type
|
||||
FROM grid_draw_shape_relate sr
|
||||
LEFT JOIN draw_shape_cust_${headId} sc ON sc.shape_id = sr.shape_id
|
||||
WHERE sr.grid_id = #{gridId}
|
||||
AND sr.delete_flag = '0'
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -339,4 +339,26 @@
|
||||
<select id="getSecGridIdByTopGridId" resultType="Long">
|
||||
select grid_id from grid_region_grid where parent_grid_id = #{gridId} and grid_level = '2' and delete_flag = '0'
|
||||
</select>
|
||||
|
||||
<!-- 查询地理网格列表(简化版)- 专用于客群创建 -->
|
||||
<select id="getRegionGridListForGroup" parameterType="RegionGridListDTO" resultType="RegionGridGroupVO">
|
||||
select distinct a.grid_id, a.grid_name
|
||||
from grid_region_grid a
|
||||
left join grid_region_user_relate c on c.grid_id = a.grid_id
|
||||
where a.delete_flag = '0'
|
||||
and c.delete_flag = '0'
|
||||
and a.grid_level = #{gridLevel}
|
||||
and (a.dept_id in (select dept_id from sys_dept where dept_id = #{deptId} or find_in_set(#{deptId}, ancestors))
|
||||
or c.relate_dept_id in (select dept_id from sys_dept where dept_id = #{deptId} or find_in_set(#{deptId}, ancestors)))
|
||||
<if test="opsDept != null and opsDept != ''">
|
||||
and a.ops_dept = #{opsDept}
|
||||
</if>
|
||||
<if test="gridDutyType != null and gridDutyType != ''">
|
||||
and a.grid_duty_type = #{gridDutyType}
|
||||
</if>
|
||||
<if test="gridName != null and gridName != ''">
|
||||
and a.grid_name like concat('%', #{gridName}, '%')
|
||||
</if>
|
||||
ORDER BY a.grid_name
|
||||
</select>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user