|
@@ -2834,6 +2834,9 @@ public class ExcelTabServiceImpl extends BaseServiceImpl<ExcelTabMapper, ExcelTa
|
|
//实体数据
|
|
//实体数据
|
|
String querySql = "select * from " + wbsTreePrivate.getInitTableName() + " where p_key_id=" + pkeyId + " and group_id = " + groupId;
|
|
String querySql = "select * from " + wbsTreePrivate.getInitTableName() + " where p_key_id=" + pkeyId + " and group_id = " + groupId;
|
|
List<Map<String, Object>> dataIn = jdbcTemplate.queryForList(querySql);
|
|
List<Map<String, Object>> dataIn = jdbcTemplate.queryForList(querySql);
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
String keyNames="";
|
|
String keyNames="";
|
|
//匹配关联
|
|
//匹配关联
|
|
try {
|
|
try {
|
|
@@ -2850,6 +2853,20 @@ public class ExcelTabServiceImpl extends BaseServiceImpl<ExcelTabMapper, ExcelTa
|
|
htmlString = htmlString.replaceAll("placeholder", "placeholderxx");
|
|
htmlString = htmlString.replaceAll("placeholder", "placeholderxx");
|
|
htmlString = htmlString.replaceAll("title", "titlexx");
|
|
htmlString = htmlString.replaceAll("title", "titlexx");
|
|
Document doc = Jsoup.parse(htmlString);
|
|
Document doc = Jsoup.parse(htmlString);
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ // 获取默认值
|
|
|
|
+ Elements elements = doc.getElementsByAttribute("defText");
|
|
|
|
+ if(Func.isNotEmpty(elements) && elements.size()>=1){
|
|
|
|
+ for(Element eleme: elements){
|
|
|
|
+ String id = Func.isNull(eleme.attr("id"))?eleme.attr("keyname"):eleme.attr("id");
|
|
|
|
+ if(Func.isNotEmpty(id)){
|
|
|
|
+
|
|
|
|
+ reData.put(id, eleme.attr("defText"));
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
keyNames= getKeyNameList(doc);
|
|
keyNames= getKeyNameList(doc);
|
|
TrialSelfInspectionRecord record = jdbcTemplate.query("select * from u_trial_self_inspection_record where id = " + groupId, new BeanPropertyRowMapper<>(TrialSelfInspectionRecord.class)).stream().findAny().orElse(null);
|
|
TrialSelfInspectionRecord record = jdbcTemplate.query("select * from u_trial_self_inspection_record where id = " + groupId, new BeanPropertyRowMapper<>(TrialSelfInspectionRecord.class)).stream().findAny().orElse(null);
|
|
// 优先使用试验记录中的委托单和样品
|
|
// 优先使用试验记录中的委托单和样品
|
|
@@ -3146,25 +3163,14 @@ public class ExcelTabServiceImpl extends BaseServiceImpl<ExcelTabMapper, ExcelTa
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
}
|
|
}
|
|
|
|
|
|
- // 获取默认值
|
|
|
|
- QueryWrapper<TextdictInfo> queryWrapper = new QueryWrapper<>();
|
|
|
|
- queryWrapper.select("col_key", "sig_role_name");
|
|
|
|
- queryWrapper.eq("type", 4);
|
|
|
|
- queryWrapper.eq("tab_id", wbsTreePrivate.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("id");
|
|
reData.remove("id");
|