|
@@ -763,7 +763,7 @@ public class ExcelTabController extends BladeController {
|
|
}
|
|
}
|
|
|
|
|
|
File file1 = ResourceUtil.getFile(wbsTreePrivate.getHtmlUrl());
|
|
File file1 = ResourceUtil.getFile(wbsTreePrivate.getHtmlUrl());
|
|
-// File file1 = ResourceUtil.getFile("D:\\develop\\1633308933835718656.html");
|
|
|
|
|
|
+// File file1 = ResourceUtil.getFile("D:\\develop\\1633344465559093248.html");
|
|
FileInputStream fileInputStream = new FileInputStream(file1);
|
|
FileInputStream fileInputStream = new FileInputStream(file1);
|
|
String htmlString = IoUtil.readToString(fileInputStream);
|
|
String htmlString = IoUtil.readToString(fileInputStream);
|
|
// 解析 style
|
|
// 解析 style
|
|
@@ -1720,10 +1720,10 @@ public class ExcelTabController extends BladeController {
|
|
if (val.indexOf("__") >= 0) {
|
|
if (val.indexOf("__") >= 0) {
|
|
String[] DataVal = val.split("__");
|
|
String[] DataVal = val.split("__");
|
|
String[] xy = DataVal[1].split("_");
|
|
String[] xy = DataVal[1].split("_");
|
|
- if (trs.size() <= (Integer.parseInt(xy[0])-1)) {
|
|
|
|
|
|
+ if (trs.size() > (Integer.parseInt(xy[0])-1)) {
|
|
Element trData = trs.get(Integer.parseInt(xy[0]));
|
|
Element trData = trs.get(Integer.parseInt(xy[0]));
|
|
Elements tdDatas = trData.select("td");
|
|
Elements tdDatas = trData.select("td");
|
|
- if (tdDatas.size() <= (Integer.parseInt(xy[0]) - 1)) {
|
|
|
|
|
|
+ if (tdDatas.size() > (Integer.parseInt(xy[0]) - 1)) {
|
|
Element data = tdDatas.get(Integer.parseInt(xy[1]));
|
|
Element data = tdDatas.get(Integer.parseInt(xy[1]));
|
|
|
|
|
|
if (data.html().indexOf("x1") >= 0 && data.html().indexOf("y1") >= 0) {
|
|
if (data.html().indexOf("x1") >= 0 && data.html().indexOf("y1") >= 0) {
|
|
@@ -1797,10 +1797,10 @@ public class ExcelTabController extends BladeController {
|
|
String key = e.getColKey();
|
|
String key = e.getColKey();
|
|
String[] keys = key.split("__");
|
|
String[] keys = key.split("__");
|
|
String[] trtd = keys[1].split("_");
|
|
String[] trtd = keys[1].split("_");
|
|
- if (trs.size() <= (Integer.parseInt(trtd[0])-1)) {
|
|
|
|
|
|
+ if ( trs.size() > (Integer.parseInt(trtd[0]))) {
|
|
Element trData = trs.get(Integer.parseInt(trtd[0]));
|
|
Element trData = trs.get(Integer.parseInt(trtd[0]));
|
|
Elements tdDatas = trData.select("td");
|
|
Elements tdDatas = trData.select("td");
|
|
- if (tdDatas.size() <= (Integer.parseInt(trtd[0]) - 1)) {
|
|
|
|
|
|
+ if (tdDatas.size() > (Integer.parseInt(trtd[0]) - 1)) {
|
|
Element data = tdDatas.get(Integer.parseInt(trtd[1]));
|
|
Element data = tdDatas.get(Integer.parseInt(trtd[1]));
|
|
// Element data = trs.get(Integer.parseInt(trtd[0])).select("td").get(Integer.parseInt(trtd[1]));
|
|
// Element data = trs.get(Integer.parseInt(trtd[0])).select("td").get(Integer.parseInt(trtd[1]));
|
|
|
|
|
|
@@ -1823,7 +1823,7 @@ public class ExcelTabController extends BladeController {
|
|
|
|
|
|
Long fileName = SnowFlakeUtil.getId();
|
|
Long fileName = SnowFlakeUtil.getId();
|
|
String onePdfPath = file_path + "/pdf//" + fileName + ".pdf";
|
|
String onePdfPath = file_path + "/pdf//" + fileName + ".pdf";
|
|
- wb.saveToFile("d://777.xls", ExcelVersion.Version2010);
|
|
|
|
|
|
+// wb.saveToFile("d://777.xls", ExcelVersion.Version2010);
|
|
sheet.saveToPdf(onePdfPath);
|
|
sheet.saveToPdf(onePdfPath);
|
|
|
|
|
|
BladeFile bladeFile = this.newIOSSClient.uploadFile(fileName + ".pdf", onePdfPath);
|
|
BladeFile bladeFile = this.newIOSSClient.uploadFile(fileName + ".pdf", onePdfPath);
|
|
@@ -1952,6 +1952,21 @@ public class ExcelTabController extends BladeController {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ // 获取默认值
|
|
|
|
+ QueryWrapper<TextdictInfo> queryWrapper = new QueryWrapper<>();
|
|
|
|
+ queryWrapper.eq("type", 4);
|
|
|
|
+ queryWrapper.eq("tab_id", tableNode.getPKeyId());
|
|
|
|
+ final List<TextdictInfo> textdictInfos = textdictInfoService.getBaseMapper().selectList(queryWrapper);
|
|
|
|
+ if (!textdictInfos.isEmpty()) {
|
|
|
|
+ for (TextdictInfo textdictInfo : textdictInfos) {
|
|
|
|
+ if (reData.containsKey(textdictInfo.getColKey())) {
|
|
|
|
+ String keyVal = reData.get(textdictInfo.getColKey()) + "";
|
|
|
|
+ } else {
|
|
|
|
+ reData.put(textdictInfo.getColKey() + "", textdictInfo.getSigRoleName());
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
// 移除Id 和 p_key_id
|
|
// 移除Id 和 p_key_id
|
|
reData.remove("p_key_id");
|
|
reData.remove("p_key_id");
|
|
reData.remove("classify");
|
|
reData.remove("classify");
|