-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
IVYPORTAL-14577: Make express an independent marketplace item
- Fixed bug: Data provider not loaded - Fixed bug: Date pattern in UserTaskWithMailForm.xhtml not correct - Fixed bug: Adapt callable processes to new approach
- Loading branch information
1 parent
f4dd9a2
commit 19083aa
Showing
13 changed files
with
287 additions
and
220 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,4 @@ | ||
{ | ||
/PROCESS { | ||
/Functional-Processes.DeleteDocumentItem "Functional Processes/DeleteDocumentItemOverride" | ||
/Functional-Processes.UploadDocumentItem "Functional Processes/UploadDocumentItemOverride" | ||
/Functional-Processes.GetDocumentItems "Functional Processes/GetDocumentItemsOverride" | ||
} | ||
/HTML_DIALOG * | ||
{ | ||
/PROCESS * | ||
/HTML_DIALOG * | ||
} |
11 changes: 6 additions & 5 deletions
11
...s/DeleteDocumentItemOverrideData.ivyClass → ...wfs/CustomDeleteDocumentItemData.ivyClass
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
DeleteDocumentItemOverrideData #class | ||
gawfs #namespace | ||
document com.axonivy.portal.components.ivydata.bo.IvyDocument #field | ||
businessCase ch.ivyteam.ivy.workflow.ICase #field | ||
message String #field | ||
CustomDeleteDocumentItemData #class | ||
gawfs #namespace | ||
document com.axonivy.portal.components.ivydata.bo.IvyDocument #field | ||
businessCase ch.ivyteam.ivy.workflow.ICase #field | ||
message String #field | ||
status com.axonivy.portal.components.enums.CustomProcessStatus #field |
11 changes: 6 additions & 5 deletions
11
...wfs/GetDocumentItemsOverrideData.ivyClass → ...gawfs/CustomGetDocumentItemsData.ivyClass
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
GetDocumentItemsOverrideData #class | ||
gawfs #namespace | ||
businessCase ch.ivyteam.ivy.workflow.ICase #field | ||
message String #field | ||
documents java.util.List<com.axonivy.portal.components.ivydata.bo.IvyDocument> #field | ||
CustomGetDocumentItemsData #class | ||
gawfs #namespace | ||
businessCase ch.ivyteam.ivy.workflow.ICase #field | ||
message String #field | ||
documents java.util.List<com.axonivy.portal.components.ivydata.bo.IvyDocument> #field | ||
status com.axonivy.portal.components.enums.CustomProcessStatus #field |
5 changes: 3 additions & 2 deletions
5
...s/UploadDocumentItemOverrideData.ivyClass → ...wfs/CustomUploadDocumentItemData.ivyClass
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,11 @@ | ||
UploadDocumentItemOverrideData #class | ||
CustomUploadDocumentItemData #class | ||
gawfs #namespace | ||
businessCase ch.ivyteam.ivy.workflow.ICase #field | ||
message String #field | ||
status com.axonivy.portal.components.enums.UploadDocumentCheckStatus #field | ||
status String #field | ||
uploadedDocument ch.ivyteam.ivy.workflow.document.IDocument #field | ||
uploadedFile org.primefaces.model.file.UploadedFile #field | ||
enableVirusScannerForUploadedDocument Boolean #field | ||
enableScriptCheckingForUploadedDocument Boolean #field | ||
allowedUploadFileTypes String #field | ||
skip Boolean #field |
83 changes: 83 additions & 0 deletions
83
axonivy-express/processes/Functional Processes/CustomDeleteDocumentItem.p.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
{ | ||
"$schema" : "https://json-schema.axonivy.com/process/11.2.2/process.json", | ||
"id" : "18BD123C409BCF3D", | ||
"kind" : "CALLABLE_SUB", | ||
"config" : { | ||
"data" : "gawfs.CustomDeleteDocumentItemData" | ||
}, | ||
"elements" : [ { | ||
"id" : "f1", | ||
"type" : "CallSubEnd", | ||
"visual" : { | ||
"at" : { "x" : 504, "y" : 64 } | ||
} | ||
}, { | ||
"id" : "f3", | ||
"type" : "Script", | ||
"name" : "Delete document item", | ||
"config" : { | ||
"output" : { | ||
"code" : [ | ||
"import ch.ivy.addon.portalkit.util.ExecutingExpressProcessUtils;", | ||
"import com.axonivy.portal.components.enums.CustomProcessStatus;", | ||
"", | ||
"in.status = CustomProcessStatus.SKIP;", | ||
"", | ||
"if (ExecutingExpressProcessUtils.isExpressCase(in.businessCase)) {", | ||
" in.status = CustomProcessStatus.OK;", | ||
" in.businessCase.documents().delete(Long.valueOf(in.document.id));", | ||
" in.message = ivy.cms.co(\"/Dialogs/components/CaseDocument/deleteSucceed\");", | ||
"}" | ||
] | ||
} | ||
}, | ||
"visual" : { | ||
"at" : { "x" : 376, "y" : 64 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f4", "to" : "f1" } | ||
] | ||
}, { | ||
"id" : "f5", | ||
"type" : "ProcessAnnotation", | ||
"name" : "Override this sub process to delete file in DMS", | ||
"visual" : { | ||
"at" : { "x" : 184, "y" : 144 }, | ||
"size" : { "width" : 284, "height" : 44 } | ||
} | ||
}, { | ||
"id" : "f0", | ||
"type" : "CallSubStart", | ||
"name" : "portalDeleteDocumentItem(ICase,IvyDocument)", | ||
"config" : { | ||
"signature" : "portalDeleteDocumentItem", | ||
"input" : { | ||
"params" : [ | ||
{ "name" : "businessCase", "type" : "ch.ivyteam.ivy.workflow.ICase", "desc" : "" }, | ||
{ "name" : "document", "type" : "com.axonivy.portal.components.ivydata.bo.IvyDocument", "desc" : "" } | ||
], | ||
"map" : { | ||
"out.businessCase" : "param.businessCase", | ||
"out.document" : "param.document" | ||
} | ||
}, | ||
"result" : { | ||
"params" : [ | ||
{ "name" : "message", "type" : "String", "desc" : "" }, | ||
{ "name" : "status", "type" : "String", "desc" : "" } | ||
], | ||
"map" : { | ||
"result.message" : "in.message", | ||
"result.status" : "in.status.name()" | ||
} | ||
} | ||
}, | ||
"visual" : { | ||
"at" : { "x" : 120, "y" : 64 }, | ||
"labelOffset" : { "x" : 1, "y" : 41 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f2", "to" : "f3" } | ||
] | ||
} ] | ||
} |
177 changes: 93 additions & 84 deletions
177
...Processes/GetDocumentItemsOverride.p.json → ...l Processes/CustomGetDocumentItems.p.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,85 +1,94 @@ | ||
{ | ||
"$schema" : "https://json-schema.axonivy.com/process/11.2.1/process.json", | ||
"id" : "16B25F2844868AE2", | ||
"kind" : "CALLABLE_SUB", | ||
"config" : { | ||
"data" : "gawfs.GetDocumentItemsOverrideData" | ||
}, | ||
"elements" : [ { | ||
"id" : "f0", | ||
"type" : "CallSubStart", | ||
"name" : "call(ICase)", | ||
"config" : { | ||
"signature" : "call", | ||
"input" : { | ||
"params" : [ | ||
{ "name" : "businessCase", "type" : "ch.ivyteam.ivy.workflow.ICase", "desc" : "" } | ||
], | ||
"map" : { | ||
"out.businessCase" : "param.businessCase" | ||
} | ||
}, | ||
"result" : { | ||
"params" : [ | ||
{ "name" : "documents", "type" : "java.util.List<com.axonivy.portal.components.ivydata.bo.IvyDocument>", "desc" : "" }, | ||
{ "name" : "message", "type" : "String", "desc" : "" } | ||
], | ||
"map" : { | ||
"result.documents" : "in.documents", | ||
"result.message" : "in.message" | ||
} | ||
} | ||
}, | ||
"visual" : { | ||
"at" : { "x" : 96, "y" : 64 }, | ||
"labelOffset" : { "x" : 6, "y" : 44 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f4", "to" : "f3" } | ||
] | ||
}, { | ||
"id" : "f1", | ||
"type" : "CallSubEnd", | ||
"visual" : { | ||
"at" : { "x" : 352, "y" : 64 } | ||
} | ||
}, { | ||
"id" : "f3", | ||
"type" : "Script", | ||
"name" : "get document items", | ||
"config" : { | ||
"output" : { | ||
"code" : [ | ||
"import ch.ivy.addon.portalkit.util.DocumentFileUtils;", | ||
"", | ||
"in.documents = DocumentFileUtils.expressDocuments(in.businessCase);" | ||
] | ||
}, | ||
"sudo" : true | ||
}, | ||
"visual" : { | ||
"at" : { "x" : 224, "y" : 64 }, | ||
"size" : { "width" : 128, "height" : 60 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f2", "to" : "f1" } | ||
] | ||
}, { | ||
"id" : "f5", | ||
"type" : "ProcessAnnotation", | ||
"name" : [ | ||
"After get document list from DMS, convert them into List<ch.ivy.addon.portal.components.ivydata.bo.IvyDocument>", | ||
"Some mandatory fields when mapping:", | ||
"- id", | ||
"- name", | ||
"- contentType" | ||
], | ||
"visual" : { | ||
"at" : { "x" : 344, "y" : 240 }, | ||
"size" : { "width" : 624, "height" : 108 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f6", "to" : "f0" } | ||
] | ||
} ] | ||
{ | ||
"$schema" : "https://json-schema.axonivy.com/process/11.2.2/process.json", | ||
"id" : "18BD12E37B7541E4", | ||
"kind" : "CALLABLE_SUB", | ||
"config" : { | ||
"data" : "gawfs.CustomGetDocumentItemsData" | ||
}, | ||
"elements" : [ { | ||
"id" : "f1", | ||
"type" : "CallSubEnd", | ||
"visual" : { | ||
"at" : { "x" : 352, "y" : 64 } | ||
} | ||
}, { | ||
"id" : "f3", | ||
"type" : "Script", | ||
"name" : "get document items", | ||
"config" : { | ||
"output" : { | ||
"code" : [ | ||
"import com.axonivy.portal.components.enums.CustomProcessStatus;", | ||
"import ch.ivy.addon.portalkit.util.ExecutingExpressProcessUtils;", | ||
"import ch.ivy.addon.portalkit.util.DocumentFileUtils;", | ||
"", | ||
"in.status = CustomProcessStatus.SKIP;", | ||
"", | ||
"if (ExecutingExpressProcessUtils.isExpressCase(in.businessCase)) {", | ||
" in.status = CustomProcessStatus.OK;", | ||
" in.documents = DocumentFileUtils.expressDocuments(in.businessCase);", | ||
"}" | ||
] | ||
}, | ||
"sudo" : true | ||
}, | ||
"visual" : { | ||
"at" : { "x" : 224, "y" : 64 }, | ||
"size" : { "width" : 128, "height" : 60 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f4", "to" : "f1" } | ||
] | ||
}, { | ||
"id" : "f0", | ||
"type" : "CallSubStart", | ||
"name" : "portalGetDocumentItems(ICase)", | ||
"config" : { | ||
"signature" : "portalGetDocumentItems", | ||
"input" : { | ||
"params" : [ | ||
{ "name" : "businessCase", "type" : "ch.ivyteam.ivy.workflow.ICase", "desc" : "" } | ||
], | ||
"map" : { | ||
"out.businessCase" : "param.businessCase" | ||
} | ||
}, | ||
"result" : { | ||
"params" : [ | ||
{ "name" : "documents", "type" : "java.util.List<com.axonivy.portal.components.ivydata.bo.IvyDocument>", "desc" : "" }, | ||
{ "name" : "message", "type" : "String", "desc" : "" }, | ||
{ "name" : "status", "type" : "String", "desc" : "" } | ||
], | ||
"map" : { | ||
"result.documents" : "in.documents", | ||
"result.message" : "in.message", | ||
"result.status" : "in.status.name()" | ||
} | ||
} | ||
}, | ||
"visual" : { | ||
"at" : { "x" : 72, "y" : 64 }, | ||
"labelOffset" : { "x" : 9, "y" : -23 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f2", "to" : "f3" } | ||
] | ||
}, { | ||
"id" : "f5", | ||
"type" : "ProcessAnnotation", | ||
"name" : [ | ||
"After get document list from DMS, convert them into List<ch.ivy.addon.portal.components.ivydata.bo.IvyDocument>", | ||
"Some mandatory fields when mapping:", | ||
"- id", | ||
"- name", | ||
"- contentType" | ||
], | ||
"visual" : { | ||
"at" : { "x" : 408, "y" : 216 }, | ||
"size" : { "width" : 624, "height" : 108 } | ||
}, | ||
"connect" : [ | ||
{ "id" : "f6", "to" : "f0" } | ||
] | ||
} ] | ||
} |
Oops, something went wrong.