自定义表头修改

This commit is contained in:
高嵩
2023-02-14 14:09:17 +08:00
parent beaf0c8d1b
commit 3504521f66
@@ -264,7 +264,7 @@ public class HeadCustomEOServiceImpl extends ServiceImpl<HeadCustomEOMapper, Hea
//编号,标题,操作
boolean hasBH = false;
boolean hasBT = false;
boolean hasCZ = false;
// boolean hasCZ = false;
for (HeadCustomVO hcVO : headCustomVOOneList) {
if ("编号".equals(hcVO.getTitle()) || "Number".equals(hcVO.getTitle())) {
hasBH = true;
@@ -273,7 +273,7 @@ public class HeadCustomEOServiceImpl extends ServiceImpl<HeadCustomEOMapper, Hea
hasBT = true;
}
if ("操作".equals(hcVO.getTitle())) {
hasCZ = true;
headCustomVOOneList.remove(hcVO);
}
}
if (!hasBH) {
@@ -299,17 +299,17 @@ public class HeadCustomEOServiceImpl extends ServiceImpl<HeadCustomEOMapper, Hea
res.add(bt);
}
res.addAll(headCustomVOOneList);
if (!hasCZ) {
HeadCustomVO cz = new HeadCustomVO();
cz.setDataIndex("operation");
if (CutEnum.CN.getValue().equals(cut)) {
cz.setTitle("操作");
} else {
cz.setTitle("Operation");
}
cz.setFixed("right");
res.add(cz);
}
// if (!hasCZ) {
// HeadCustomVO cz = new HeadCustomVO();
// cz.setDataIndex("operation");
// if (CutEnum.CN.getValue().equals(cut)) {
// cz.setTitle("操作");
// } else {
// cz.setTitle("Operation");
// }
// cz.setFixed("right");
// res.add(cz);
// }
return res;
}
@@ -329,9 +329,9 @@ public class HeadCustomEOServiceImpl extends ServiceImpl<HeadCustomEOMapper, Hea
if ("标题".equals(headCustomEO.getHeadFieldCn())) {
headCustomVO.setFixed("left");
}
if ("操作".equals(headCustomEO.getHeadFieldCn())) {
headCustomVO.setFixed("right");
}
// if ("操作".equals(headCustomEO.getHeadFieldCn())) {
// headCustomVO.setFixed("right");
// }
}
return headCustomVO;
}