Skip to content

Commit

Permalink
Merge pull request #1257 from axonivy-market/bug/IVYPORTAL-17898-Apda…
Browse files Browse the repository at this point in the history
…t-case-owner-in-Portal-exception

bug/IVYPORTAL-17898-Apdat-case-owner-in-Portal-exception
  • Loading branch information
chnam-axonivy authored Nov 25, 2024
2 parents 7fcf436 + 9e70b4c commit 2f8baea
Showing 1 changed file with 37 additions and 26 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -169,48 +169,59 @@
"output" : {
"code" : [
"import ch.ivyteam.ivy.security.ISecurityContext;",
"ivy.case.owners().add(ISecurityContext.current().users().find(\"demo\"));",
"ivy.case.owners().add(ISecurityContext.current().users().find(\"admin\"));",
"ivy.case.owners().add(ISecurityContext.current().roles().find(\"CaseOwner\"));",
"ivy.case.owners().add(ISecurityContext.current().roles().find(\"HR\"));",
"ivy.case.owners().add(ISecurityContext.current().users().find(\"Developer\"));",
"ivy.case.owners().add(ISecurityContext.current().users().find(\"david\"));",
"ivy.case.owners().add(ISecurityContext.current().users().find(\"peter\"));",
"ivy.case.owners().add(ISecurityContext.current().roles().find(\"Sales\"));",
"ivy.case.owners().add(ISecurityContext.current().users().find(\"guest\"));"
"if (ISecurityContext.current().users().find(\"demo\") != null){",
" ivy.case.owners().add(ISecurityContext.current().users().find(\"demo\")); ",
"}",
"",
"if (ISecurityContext.current().users().find(\"admin\") != null){",
" ivy.case.owners().add(ISecurityContext.current().users().find(\"admin\"));",
"}",
"",
"if (ISecurityContext.current().roles().find(\"CaseOwner\") != null){",
" ivy.case.owners().add(ISecurityContext.current().roles().find(\"CaseOwner\"));",
"",
"}",
"",
"if (ISecurityContext.current().roles().find(\"HR\") != null){",
" ivy.case.owners().add(ISecurityContext.current().roles().find(\"HR\"));",
"}"
]
}
},
"sudo" : true
},
"visual" : {
"at" : { "x" : 224, "y" : 280 }
},
"connect" : [
{ "id" : "f18", "to" : "f17" }
{ "id" : "f18", "to" : "f22", "var" : "in1" }
]
}, {
"id" : "f17",
"type" : "TaskSwitchEvent",
"id" : "f19",
"type" : "TaskEnd",
"visual" : {
"at" : { "x" : 448, "y" : 280 },
"labelOffset" : { "x" : 13, "y" : 33 }
}
}, {
"id" : "f22",
"type" : "TaskSwitchGateway",
"config" : {
"task" : {
"name" : "Task with multiple case owners"
},
"tasks" : [ {
"id" : "TaskA",
"name" : "Task with multiple case owners",
"responsible" : {
"activator" : "CREATOR"
}
} ],
"case" : {
"name" : "Case with multiple owners"
}
},
"visual" : {
"at" : { "x" : 352, "y" : 280 },
"labelOffset" : { "x" : 14, "y" : 34 }
"at" : { "x" : 352, "y" : 280 }
},
"connect" : [
{ "id" : "f20", "to" : "f19" }
{ "id" : "f21", "to" : "f19", "condition" : "ivp==\"TaskA.ivp\"" }
]
}, {
"id" : "f19",
"type" : "TaskEnd",
"visual" : {
"at" : { "x" : 448, "y" : 280 },
"labelOffset" : { "x" : 13, "y" : 33 }
}
} ]
}

0 comments on commit 2f8baea

Please sign in to comment.