Commit e4591ddf authored by zhuxiang's avatar zhuxiang
Browse files

优化

parent f834a8b5
package com.platform.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.platform.model.entity.VerifyAccountEntity;
import com.platform.model.resp.Result;
import com.platform.service.VerifyAccountService;
import org.springframework.dao.DuplicateKeyException;
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 javax.annotation.Resource;
@RestController
@RequestMapping("/verify/account")
public class VerifyAccountController extends BaseController {
@Resource
private VerifyAccountService verifyAccountService;
@PostMapping("/set")
public Result set(@RequestBody VerifyAccountEntity verifyAccount) {
try {
return toAjax(verifyAccountService.save(verifyAccount));
} catch (DuplicateKeyException e) {
return toAjax(verifyAccountService.remove(new LambdaQueryWrapper<VerifyAccountEntity>()
.eq(VerifyAccountEntity::getCaseId, verifyAccount.getCaseId())
.eq(VerifyAccountEntity::getAccountName, verifyAccount.getAccountName())));
}
}
}
...@@ -27,7 +27,7 @@ public interface ExcelDataMapper extends BaseMapper<ExcelDataEntity> { ...@@ -27,7 +27,7 @@ public interface ExcelDataMapper extends BaseMapper<ExcelDataEntity> {
List<AssociationVO> selectFinancialTransactions(UserDTO userDTO); List<AssociationVO> selectFinancialTransactions(UserDTO userDTO);
List<ExcelDataVO> queryListByPayUserList(@Param("userList") List<String> userList, List<ExcelDataVO> queryListByPayUserList(@Param("userList") List<String> userList,
@Param("caseId") int caseId); @Param("caseDTO") CaseDTO caseDTO);
List<ExcelDataEntity> cashFlow(UserDTO userDTO); List<ExcelDataEntity> cashFlow(UserDTO userDTO);
......
package com.platform.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.platform.model.entity.VerifyAccountEntity;
import org.apache.ibatis.annotations.Mapper;
@Mapper
public interface VerifyAccountMapper extends BaseMapper<VerifyAccountEntity> {
}
package com.platform.model.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@Data
@TableName("verify_account")
public class VerifyAccountEntity {
@TableId(value = "id", type = IdType.AUTO)
private Integer id;
private Integer caseId;
private String accountName;
}
...@@ -19,12 +19,15 @@ public class NodeVO { ...@@ -19,12 +19,15 @@ public class NodeVO {
private Boolean publicAccountFlag; private Boolean publicAccountFlag;
private Boolean verifyAccountFlag;
private int degree; private int degree;
public NodeVO(String node, String label, boolean publicAccountFlag) { public NodeVO(String node, String label, boolean publicAccountFlag, boolean verifyAccountFlag) {
this.node = node; this.node = node;
this.label = label; this.label = label;
this.publicAccountFlag = publicAccountFlag; this.publicAccountFlag = publicAccountFlag;
this.verifyAccountFlag = verifyAccountFlag;
if (node.contains("公司")) { if (node.contains("公司")) {
this.nodeType = "对公"; this.nodeType = "对公";
} else { } else {
......
...@@ -47,7 +47,7 @@ public interface ExcelDataService extends IService<ExcelDataEntity> { ...@@ -47,7 +47,7 @@ public interface ExcelDataService extends IService<ExcelDataEntity> {
List<ExcelDataEntity> queryList(CaseDTO caseDTO); List<ExcelDataEntity> queryList(CaseDTO caseDTO);
List<ExcelDataVO> queryListByPayUserList(List<String> userList, int caseId); List<ExcelDataVO> queryListByPayUserList(List<String> userList, CaseDTO caseDTO);
List<AssociationVO> selectFinancialTransactions(UserDTO userDTO); List<AssociationVO> selectFinancialTransactions(UserDTO userDTO);
......
package com.platform.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.platform.model.entity.VerifyAccountEntity;
import java.util.List;
public interface VerifyAccountService extends IService<VerifyAccountEntity> {
List<VerifyAccountEntity> queryByCaseId(int caseId);
}
...@@ -41,6 +41,8 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -41,6 +41,8 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
private UserRelationService userRelationService; private UserRelationService userRelationService;
@Resource @Resource
private PublicAccountService publicAccountService; private PublicAccountService publicAccountService;
@Resource
private VerifyAccountService verifyAccountService;
@Override @Override
public List<CaseVO> queryDataList(CaseDTO caseDTO) { public List<CaseVO> queryDataList(CaseDTO caseDTO) {
...@@ -156,6 +158,10 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -156,6 +158,10 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
Set<String> uniqueUserName = new HashSet<>(); Set<String> uniqueUserName = new HashSet<>();
Map<String, EdgeVO> edgeMap = new HashMap<>(); Map<String, EdgeVO> edgeMap = new HashMap<>();
Map<String, Boolean> publicAccountMap = new HashMap<>(); Map<String, Boolean> publicAccountMap = new HashMap<>();
Map<String, Boolean> verifyAccountMap = new HashMap<>();
List<VerifyAccountEntity> verifyAccountEntityList = verifyAccountService.queryByCaseId(caseDTO.getId());
verifyAccountEntityList.forEach(verifyAccountEntity -> verifyAccountMap.put(verifyAccountEntity.getAccountName(), true));
// 配置规则 // 配置规则
applyCaseRules(caseDTO); applyCaseRules(caseDTO);
...@@ -173,7 +179,7 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -173,7 +179,7 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
Map<String, String> userAndLabel = getUserLabels(uniqueUserName, caseDTO.getId()); Map<String, String> userAndLabel = getUserLabels(uniqueUserName, caseDTO.getId());
// 添加节点 // 添加节点
addNodesToGraph(graph, uniqueUserName, userAndLabel, publicAccountMap); addNodesToGraph(graph, uniqueUserName, userAndLabel, publicAccountMap, verifyAccountMap);
// 过滤有效边 // 过滤有效边
List<EdgeVO> validEdges = filterValidEdges(edgeMap, uf); List<EdgeVO> validEdges = filterValidEdges(edgeMap, uf);
...@@ -280,6 +286,10 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -280,6 +286,10 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
String payer = excelDataEntity.getPayUserName(); String payer = excelDataEntity.getPayUserName();
String payee = excelDataEntity.getPayeeName(); String payee = excelDataEntity.getPayeeName();
if (StringUtils.isEmpty(payee) || StringUtils.isEmpty(payer) || payer.equals("-") || payee.equals("-")) {
continue;
}
double amount = formatAmount(excelDataEntity.getAmount()); double amount = formatAmount(excelDataEntity.getAmount());
uniqueUserName.add(payer); uniqueUserName.add(payer);
uniqueUserName.add(payee); uniqueUserName.add(payee);
...@@ -288,6 +298,7 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -288,6 +298,7 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
if (isPublicAccount(payer, publicAccountEntityList, publicAccountMap) || isPublicAccount(payee, publicAccountEntityList, publicAccountMap)) { if (isPublicAccount(payer, publicAccountEntityList, publicAccountMap) || isPublicAccount(payee, publicAccountEntityList, publicAccountMap)) {
continue; continue;
} }
// 使用UnionFindVO的接口正确添加节点 // 使用UnionFindVO的接口正确添加节点
if (!uf.getParent().containsKey(payer)) { if (!uf.getParent().containsKey(payer)) {
uf.makeSet(payer); uf.makeSet(payer);
...@@ -359,11 +370,13 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -359,11 +370,13 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
private void addNodesToGraph(GraphVO graph, private void addNodesToGraph(GraphVO graph,
Set<String> uniqueUserName, Set<String> uniqueUserName,
Map<String, String> userAndLabel, Map<String, String> userAndLabel,
Map<String, Boolean> publicAccountMap) { Map<String, Boolean> publicAccountMap,
Map<String, Boolean> verifyAccountMap) {
for (String userName : uniqueUserName) { for (String userName : uniqueUserName) {
String label = userAndLabel.getOrDefault(userName, ""); String label = userAndLabel.getOrDefault(userName, "");
boolean publicAccount = publicAccountMap.getOrDefault(userName, false); boolean publicAccount = publicAccountMap.getOrDefault(userName, false);
graph.addNode(new NodeVO(userName, label, publicAccount)); boolean verifyAccount = verifyAccountMap.getOrDefault(userName, false);
graph.addNode(new NodeVO(userName, label, publicAccount, verifyAccount));
} }
} }
...@@ -578,7 +591,7 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem ...@@ -578,7 +591,7 @@ public class CaseServiceImpl extends ServiceImpl<CaseMapper, CasesEntity> implem
for (ExcelDataEntity excelDataEntity : excelDataEntityList) { for (ExcelDataEntity excelDataEntity : excelDataEntityList) {
String payer = excelDataEntity.getPayUserName(); String payer = excelDataEntity.getPayUserName();
String payee = excelDataEntity.getPayeeName(); String payee = excelDataEntity.getPayeeName();
if (StringUtils.isEmpty(payee) || StringUtils.isEmpty(payer)) { if (StringUtils.isEmpty(payee) || StringUtils.isEmpty(payer) || payer.equals("-") || payee.equals("-")) {
continue; continue;
} }
// 更新每个人关联的节点数量 // 更新每个人关联的节点数量
......
...@@ -66,11 +66,11 @@ public class ExcelDataServiceImpl extends ServiceImpl<ExcelDataMapper, ExcelData ...@@ -66,11 +66,11 @@ public class ExcelDataServiceImpl extends ServiceImpl<ExcelDataMapper, ExcelData
} }
@Override @Override
public List<ExcelDataVO> queryListByPayUserList(List<String> userList, int caseId) { public List<ExcelDataVO> queryListByPayUserList(List<String> userList, CaseDTO caseDTO) {
if (CollUtil.isEmpty(userList)) { if (CollUtil.isEmpty(userList)) {
return Lists.newArrayList(); return Lists.newArrayList();
} }
return baseMapper.queryListByPayUserList(userList, caseId); return baseMapper.queryListByPayUserList(userList, caseDTO);
} }
@Override @Override
......
...@@ -2,17 +2,18 @@ package com.platform.service.impl; ...@@ -2,17 +2,18 @@ package com.platform.service.impl;
import cn.hutool.core.collection.CollUtil; import cn.hutool.core.collection.CollUtil;
import com.alibaba.excel.EasyExcel; import com.alibaba.excel.EasyExcel;
import com.alibaba.excel.EasyExcelFactory;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.platform.mapper.GroupDetailMapper; import com.platform.mapper.GroupDetailMapper;
import com.platform.model.dto.CaseDTO;
import com.platform.model.dto.GroupDetailDTO; import com.platform.model.dto.GroupDetailDTO;
import com.platform.model.entity.CaseRuleConfigEntity;
import com.platform.model.entity.ExcelDataEntity;
import com.platform.model.entity.GroupDetailEntity; import com.platform.model.entity.GroupDetailEntity;
import com.platform.model.entity.GroupEntity; import com.platform.model.entity.GroupEntity;
import com.platform.model.vo.*; import com.platform.model.vo.*;
import com.platform.service.ExcelDataService; import com.platform.service.*;
import com.platform.service.GroupDetailService;
import com.platform.service.GroupService;
import com.platform.service.UserService;
import com.platform.utils.StringUtils; import com.platform.utils.StringUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -29,9 +30,13 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group ...@@ -29,9 +30,13 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group
@Resource @Resource
private UserService userService; private UserService userService;
@Resource @Resource
private WhiteService whiteService;
@Resource
private GroupService groupService; private GroupService groupService;
@Resource @Resource
private ExcelDataService excelDataService; private ExcelDataService excelDataService;
@Resource
private CaseRuleConfigService caseRuleConfigService;
@Override @Override
public List<GroupDetailEntity> queryList(GroupDetailDTO groupDetailDTO) { public List<GroupDetailEntity> queryList(GroupDetailDTO groupDetailDTO) {
...@@ -83,7 +88,22 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group ...@@ -83,7 +88,22 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group
//根据团体id查看团体明细 //根据团体id查看团体明细
List<String> userList = baseMapper.queryUserList(groupId); List<String> userList = baseMapper.queryUserList(groupId);
if (CollUtil.isNotEmpty(userList)) { if (CollUtil.isNotEmpty(userList)) {
List<ExcelDataVO> excelDataEntityList = excelDataService.queryListByPayUserList(userList, groupEntity.getCaseId()); CaseDTO caseDTO = new CaseDTO();
CaseRuleConfigEntity caseRuleConfigEntity = caseRuleConfigService.getByCaseId(groupEntity.getCaseId());
if (caseRuleConfigEntity != null) {
caseDTO.setMinTransaction(caseRuleConfigEntity.getMinTransaction());
caseDTO.setMaxTransaction(caseRuleConfigEntity.getMaxTransaction());
caseDTO.setMinAmount(caseRuleConfigEntity.getMinAmount());
caseDTO.setMaxAmount(caseRuleConfigEntity.getMaxAmount());
caseDTO.setStartTime(caseRuleConfigEntity.getStartTime());
caseDTO.setEndTime(caseRuleConfigEntity.getEndTime());
caseDTO.setPrincipal(caseRuleConfigEntity.getPrincipal());
caseDTO.setWhiteFlag(caseRuleConfigEntity.isWhiteFlag());
caseDTO.setId(groupEntity.getCaseId());
}
List<ExcelDataVO> excelDataEntityList = filterExcelData(userList, caseDTO);
// 遍历结果集 // 遍历结果集
for (ExcelDataVO excelDataVO : excelDataEntityList) { for (ExcelDataVO excelDataVO : excelDataEntityList) {
String payer = excelDataVO.getPayUserName(); String payer = excelDataVO.getPayUserName();
...@@ -120,7 +140,7 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group ...@@ -120,7 +140,7 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group
excelDataEntityListNew.forEach(excelDataVO -> userAndLabel.put(excelDataVO.getPayUserName(), excelDataVO.getLabel())); excelDataEntityListNew.forEach(excelDataVO -> userAndLabel.put(excelDataVO.getPayUserName(), excelDataVO.getLabel()));
// 添加去重后的节点 // 添加去重后的节点
for (String node : uniqueNodes) { for (String node : uniqueNodes) {
graph.addNode(new NodeVO(node, userAndLabel.get(node), false)); graph.addNode(new NodeVO(node, userAndLabel.get(node), false, false));
} }
// 添加边 // 添加边
...@@ -132,6 +152,71 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group ...@@ -132,6 +152,71 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group
return null; return null;
} }
private List<ExcelDataVO> filterExcelData(List<String> userList, CaseDTO caseDTO) {
List<ExcelDataVO> excelDataEntityList = excelDataService.queryListByPayUserList(userList, caseDTO);
if (CollUtil.isEmpty(excelDataEntityList)) {
return excelDataEntityList;
}
// 使用迭代器安全删除
Iterator<ExcelDataVO> iterator = excelDataEntityList.iterator();
while (iterator.hasNext()) {
ExcelDataEntity excelDataEntity = iterator.next();
// 过滤付款人类型
if (caseDTO.getPrincipal() != null) {
if (caseDTO.getPrincipal() == 1 && excelDataEntity.getPayeeName().contains("公司")) {
iterator.remove();
continue;
}
if (caseDTO.getPrincipal() == 2 && !excelDataEntity.getPayeeName().contains("公司")) {
iterator.remove();
continue;
}
}
// 过滤金额范围
if (!isWithinAmountRange(excelDataEntity, caseDTO.getMinAmount(), caseDTO.getMaxAmount())) {
iterator.remove();
continue;
}
// 过滤交易次数
if (!isWithinTransactionRange(excelDataEntity, caseDTO.getMinTransaction(), caseDTO.getMaxTransaction())) {
iterator.remove();
}
}
// 白名单过滤
if (caseDTO.getWhiteFlag() != null && caseDTO.getWhiteFlag()) {
filterWhite(excelDataEntityList);
}
return excelDataEntityList;
}
private boolean isWithinAmountRange(ExcelDataEntity entity, Double min, Double max) {
double amount = entity.getAmount();
if (min != null && amount < min) return false;
if (max != null && amount > max) return false;
return true;
}
private boolean isWithinTransactionRange(ExcelDataEntity entity, Integer min, Integer max) {
int count = entity.getTransactionCount();
if (min != null && count < min) return false;
if (max != null && count > max) return false;
return true;
}
private void filterWhite(List<ExcelDataVO> excelDataEntityList) {
//查看白名单
List<String> whiteUser = whiteService.queryList();
// 如果 name 属性值存在于白名单中,则移除该元素
excelDataEntityList.removeIf(entity -> whiteUser.contains(entity.getPayUserName()) || whiteUser.contains(entity.getPayeeName()));
}
@Override @Override
public void personExport(GroupDetailDTO groupDetailDTO, HttpServletResponse response) { public void personExport(GroupDetailDTO groupDetailDTO, HttpServletResponse response) {
// 设置响应头 // 设置响应头
...@@ -172,7 +257,7 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group ...@@ -172,7 +257,7 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group
// 写入Excel // 写入Excel
try { try {
EasyExcel.write(response.getOutputStream(), WhiteVO.class) EasyExcelFactory.write(response.getOutputStream(), WhiteVO.class)
.sheet("团体-IP列表") .sheet("团体-IP列表")
.doWrite(groupDetailIpVOList); .doWrite(groupDetailIpVOList);
} catch (IOException e) { } catch (IOException e) {
...@@ -196,7 +281,7 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group ...@@ -196,7 +281,7 @@ public class GroupDetailServiceImpl extends ServiceImpl<GroupDetailMapper, Group
// 写入Excel // 写入Excel
try { try {
EasyExcel.write(response.getOutputStream(), WhiteVO.class) EasyExcelFactory.write(response.getOutputStream(), WhiteVO.class)
.sheet("团体-IP列表") .sheet("团体-IP列表")
.doWrite(groupDetailMacVOList); .doWrite(groupDetailMacVOList);
} catch (IOException e) { } catch (IOException e) {
......
package com.platform.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.platform.mapper.VerifyAccountMapper;
import com.platform.model.entity.VerifyAccountEntity;
import com.platform.service.VerifyAccountService;
import org.springframework.stereotype.Service;
import java.util.List;
@Service
public class VerifyAccountServiceImpl extends ServiceImpl<VerifyAccountMapper, VerifyAccountEntity> implements VerifyAccountService {
@Override
public List<VerifyAccountEntity> queryByCaseId(int caseId) {
return baseMapper.selectList(new LambdaQueryWrapper<VerifyAccountEntity>()
.eq(VerifyAccountEntity::getCaseId, caseId));
}
}
...@@ -54,12 +54,6 @@ ...@@ -54,12 +54,6 @@
<if test="endTime != null"> <if test="endTime != null">
and time &lt;= #{endTime} and time &lt;= #{endTime}
</if> </if>
<if test="startTime != null and endTime == null">
and time >= #{startTime}
</if>
<if test="startTime == null and endTime != null">
and time <![CDATA[ <= ]]> #{startTime}
</if>
group by pay_user_name,payee_name group by pay_user_name,payee_name
</select> </select>
<select id="selectFinancialTransactions" resultType="com.platform.model.vo.AssociationVO"> <select id="selectFinancialTransactions" resultType="com.platform.model.vo.AssociationVO">
...@@ -99,13 +93,11 @@ ...@@ -99,13 +93,11 @@
<select id="queryListByPayUserList" resultType="com.platform.model.vo.ExcelDataVO"> <select id="queryListByPayUserList" resultType="com.platform.model.vo.ExcelDataVO">
select select
ed.pay_user_name, ed.pay_user_name payUserName,
ed.payee_name payeeName, ed.payee_name payeeName,
ed.remark, SUM(ed.amount) amount,
ed.payee_bank_card, COUNT(*) AS transactionCount,
ed.external_channel, Max(u.label) label
ed.amount,
u.label
from from
excel_data ed excel_data ed
left join left join
...@@ -115,12 +107,21 @@ ...@@ -115,12 +107,21 @@
where where
ed.use_flag = 1 ed.use_flag = 1
and and
ed.case_id = #{caseId} ed.user_flag = 1
and
ed.case_id = #{caseDTO.id}
<if test="caseDTO.startTime != null">
and ed.time >= #{caseDTO.startTime}
</if>
<if test="caseDTO.endTime != null">
and ed.time &lt;= #{caseDTO.endTime}
</if>
and and
ed.pay_user_name in ed.pay_user_name in
<foreach collection="userList" item="userName" open="(" separator="," close=")"> <foreach collection="userList" item="userName" open="(" separator="," close=")">
#{userName} #{userName}
</foreach> </foreach>
group by ed.pay_user_name,ed.payee_name
</select> </select>
<select id="cashFlow" resultType="com.platform.model.entity.ExcelDataEntity"> <select id="cashFlow" resultType="com.platform.model.entity.ExcelDataEntity">
select id, select id,
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<select id="queryIp" resultType="com.platform.model.vo.GroupDetailIpVO"> <select id="queryIp" resultType="com.platform.model.vo.GroupDetailIpVO">
SELECT SELECT
id, MAX(id),
ip, ip,
COUNT(*) AS frequency, COUNT(*) AS frequency,
GROUP_CONCAT(DISTINCT user_name ORDER BY user_name SEPARATOR ', ') AS associatedUsers, GROUP_CONCAT(DISTINCT user_name ORDER BY user_name SEPARATOR ', ') AS associatedUsers,
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
<select id="queryMac" resultType="com.platform.model.vo.GroupDetailMacVO"> <select id="queryMac" resultType="com.platform.model.vo.GroupDetailMacVO">
SELECT SELECT
id, MAX(id),
mac, mac,
COUNT(*) AS frequency, COUNT(*) AS frequency,
GROUP_CONCAT(DISTINCT user_name ORDER BY user_name SEPARATOR ', ') AS associatedUsers, GROUP_CONCAT(DISTINCT user_name ORDER BY user_name SEPARATOR ', ') AS associatedUsers,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment