Commit c0592374 authored by 邢磊's avatar 邢磊

*)修改附件逻辑

parent c70c4e04
...@@ -393,9 +393,9 @@ public class DPSubServiceImpl { ...@@ -393,9 +393,9 @@ public class DPSubServiceImpl {
if (!ValidationUtil.isEmpty(value)) { if (!ValidationUtil.isEmpty(value)) {
JSONObject attachmentUploadDatasObj = new JSONObject(); JSONObject attachmentUploadDatasObj = new JSONObject();
attachmentUploadDatasObj.put("value", value); attachmentUploadDatasObj.put("value", value);
String accept = xObj.getString("accept"); String accept = visualParams.getString("accept");
attachmentUploadDatasObj.put("label", JsonValueUtils.getValueByKey(xObj, "visualParams", "visualParams.label")); attachmentUploadDatasObj.put("label", visualParams.getString("visualParams.label"));
if (accept.contains("doc") || accept.contains("docx") || accept.contains("pdf") || accept.contains("xls") || accept.contains("xlsx")){ if (accept.equals(".*") || accept.contains("doc") || accept.contains("docx") || accept.contains("pdf") || accept.contains("xls") || accept.contains("xlsx")){
attachmentUploadDatasObj.put("type", "file"); attachmentUploadDatasObj.put("type", "file");
} else if(accept.contains("png") || accept.contains("img")){ } else if(accept.contains("png") || accept.contains("img")){
attachmentUploadDatasObj.put("type", "img"); attachmentUploadDatasObj.put("type", "img");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment