You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
851 B
Java
26 lines
851 B
Java
3 years ago
|
package com.engine.organization.transmethod;
|
||
|
|
||
|
import com.engine.organization.entity.QueryParam;
|
||
|
import com.engine.organization.mapper.department.DepartmentMapper;
|
||
|
import com.engine.organization.util.db.MapperProxyFactory;
|
||
|
|
||
|
import java.util.List;
|
||
|
import java.util.Map;
|
||
|
import java.util.stream.Collectors;
|
||
|
|
||
|
/**
|
||
|
* @description: TODO
|
||
|
* @author:dxfeng
|
||
|
* @createTime: 2022/05/25
|
||
|
* @version: 1.0
|
||
|
*/
|
||
|
public class DepartmentTransMethod {
|
||
|
|
||
|
public static String getSpanById(String planId) {
|
||
|
DepartmentMapper departmentMapper = MapperProxyFactory.getProxy(DepartmentMapper.class);
|
||
|
List<Map<String, Object>> maps = departmentMapper.listDeptsByIds(QueryParam.builder().ids(planId).build().getIds());
|
||
|
String names = maps.stream().map(item -> (String) item.get("name")).collect(Collectors.joining(","));
|
||
|
return names;
|
||
|
}
|
||
|
}
|