花名册-Excel导出列展示顺序
This commit is contained in:
parent
2d240460f1
commit
e5a30525f0
|
|
@ -15,7 +15,6 @@ import com.engine.organization.entity.department.bo.DepartmentBO;
|
|||
import com.engine.organization.entity.department.dto.DepartmentListDTO;
|
||||
import com.engine.organization.entity.department.po.DepartmentPO;
|
||||
import com.engine.organization.entity.hrmresource.po.JclOrgCustomTemplatePO;
|
||||
import com.engine.organization.entity.hrmresource.po.SearchTemplatePO;
|
||||
import com.engine.organization.entity.hrmresource.vo.HrmResourceVO;
|
||||
import com.engine.organization.entity.staff.po.StaffPO;
|
||||
import com.engine.organization.entity.staff.vo.StaffTableVO;
|
||||
|
|
@ -45,7 +44,6 @@ import weaver.systeminfo.SystemEnv;
|
|||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.math.BigDecimal;
|
||||
import java.math.RoundingMode;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
|
|
@ -169,6 +167,7 @@ public class ExportCommonServiceImpl extends Service implements ExportCommonServ
|
|||
|
||||
List<String> columnList = Arrays.asList(columns.split(","));
|
||||
String propValue = new BaseBean().getPropValue("hrmOrganization", "orgId");
|
||||
Map<String, WeaTableColumn> columnMap = new HashMap<>();
|
||||
|
||||
|
||||
BigDecimal decimal = new BigDecimal(100 / columnList.size());
|
||||
|
|
@ -196,16 +195,18 @@ public class ExportCommonServiceImpl extends Service implements ExportCommonServ
|
|||
|
||||
weaTableColumn.setOtherpara(columnName);
|
||||
//weaTableColumn.setWidth(decimal.setScale(2, RoundingMode.HALF_UP).doubleValue() + "%");
|
||||
if (weaTableColumn.getDisplay().getBoolVal()) {
|
||||
weaTableColumnList.add(weaTableColumn);
|
||||
headerList.add(weaTableColumn.getColumn());
|
||||
headerNameList.add(weaTableColumn.getText());
|
||||
}
|
||||
columnMap.put(columnName, weaTableColumn);
|
||||
}
|
||||
}
|
||||
|
||||
//todo 修复导出excel与列定制顺序
|
||||
|
||||
for (String columnName : columnList) {
|
||||
WeaTableColumn weaTableColumn = columnMap.get(columnName);
|
||||
if (weaTableColumn != null && weaTableColumn.getDisplay().getBoolVal()) {
|
||||
weaTableColumnList.add(weaTableColumn);
|
||||
headerList.add(weaTableColumn.getColumn());
|
||||
headerNameList.add(weaTableColumn.getText());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 增加id字段,跳转人员卡片
|
||||
|
|
|
|||
Loading…
Reference in New Issue