更新工单问题树对非空子集的判断

This commit is contained in:
panshuling321 2022-03-03 09:17:20 +08:00
parent 3ee4b263ee
commit 5f7d65ae61

View File

@ -39,11 +39,15 @@ public class WorkTypeServiceImpl implements WorkTypeService {
for (Map<String, Object> childMap: childList){ for (Map<String, Object> childMap: childList){
params.put("parentTypeId", childMap.get("id")); params.put("parentTypeId", childMap.get("id"));
List<Map<String, Object>> dataList = typeDictMapper.selectMapListByParentParams(params); List<Map<String, Object>> dataList = typeDictMapper.selectMapListByParentParams(params);
if(dataList.size() > 0){
childMap.put("children", dataList); childMap.put("children", dataList);
} }
}
if (childList.size() > 0){
map.put("children", childList); map.put("children", childList);
} }
}
return typeList; return typeList;
} }