|
|
@@ -66,6 +66,7 @@ public class WbsTreePrivateController extends BladeController {
|
|
|
private final IExcelTabService iExcelTabService;
|
|
|
private final JdbcTemplate jdbcTemplate;
|
|
|
private final IWbsParamService iWbsParamService;
|
|
|
+ private final ExcelTabController excelTabController;
|
|
|
|
|
|
/**
|
|
|
* 保存项目日志划分
|
|
|
@@ -418,15 +419,18 @@ public class WbsTreePrivateController extends BladeController {
|
|
|
|
|
|
List<String> keys = wbsFormElements.stream().map(WbsFormElement::getEKey).collect(Collectors.toList());
|
|
|
|
|
|
- //解析html
|
|
|
+
|
|
|
// 读取html页面信息
|
|
|
- InputStream inputStream = null;
|
|
|
+ String htmlString = "";
|
|
|
+ //解析html
|
|
|
try {
|
|
|
- inputStream = FileUtils.getInputStreamByUrl(htmlUrl);
|
|
|
+ R excelHtml = excelTabController.getExcelHtml(f.getPKeyId());
|
|
|
+ htmlString = excelHtml.getData().toString();
|
|
|
} catch (Exception e) {
|
|
|
- throw new RuntimeException("解析html失败");
|
|
|
}
|
|
|
- String htmlString = IoUtil.readToString(inputStream);
|
|
|
+ if(StringUtil.isEmpty(htmlString)){
|
|
|
+ throw new RuntimeException("html解析失败");
|
|
|
+ }
|
|
|
// 样式集合
|
|
|
Document doc = Jsoup.parse(htmlString);
|
|
|
//获取所有input标签
|