流程手册>符号处理

This commit is contained in:
zhaol 2025-02-11 08:40:41 +08:00
parent 2733e2ae0e
commit cd0b51ef72
2 changed files with 4 additions and 9 deletions

View File

@ -379,14 +379,9 @@ public class Report1Gener {
}else { }else {
isNumberAscArray.add("false"); isNumberAscArray.add("false");
} }
String file_name;
if(upfileModel.getFileName().contains("--")){ object.put("file_name", upfileModel.getFileName());
file_name=upfileModel.getFileName().replaceAll("--+|---", "-"); String link = fileName + File.separator + upfileModel.getFileName();
}else{
file_name=upfileModel.getFileName();
}
object.put("file_name", file_name);
String link = fileName + File.separator + file_name;
object.put("link", link); object.put("link", link);
fileTable.add(object); fileTable.add(object);
fileIndex++; fileIndex++;
@ -505,7 +500,7 @@ public class Report1Gener {
String attrValue = obj.getString("value"); String attrValue = obj.getString("value");
if(attrValue.contains("<")||attrValue.contains(">")||attrValue.contains("&")||attrValue.contains("'")||attrValue.contains("\"")) { if(attrValue.contains("<")||attrValue.contains(">")||attrValue.contains("&")||attrValue.contains("'")||attrValue.contains("\"")) {
//attrValue= attrValue.replaceAll("<", "&lt;").replaceAll(">", "&gt;").replaceAll("&", "&amp;").replaceAll("'", "&apos;").replaceAll("\"", "&quot;"); //attrValue= attrValue.replaceAll("<", "&lt;").replaceAll(">", "&gt;").replaceAll("&", "&amp;").replaceAll("'", "&apos;").replaceAll("\"", "&quot;");
attrValue= attrValue.replaceAll("<", "小于").replaceAll(">", "").replaceAll("&", "&amp;").replaceAll("'", "&apos;").replaceAll("\"", "&quot;"); attrValue= attrValue.replaceAll("<", "小于").replaceAll("&", "&amp;").replaceAll("'", "&apos;").replaceAll("\"", "&quot;");
} }