-
Notifications
You must be signed in to change notification settings - Fork 4
user task forms
mandeep6ill edited this page Nov 23, 2017
·
1 revision
UserTask allows designer to configure Form related in basically two ways.
- Form Key
- Form Key can be used when Workflow designer(User) has his own Form defined for the application, and just need a Form Key (essentially, Form Name/Identifier) to correlate a task, so as to render the form properly on the Front-End.
- User Task Instance will have these three properties -
- FormType - FormKey , property to distinguish the task Type
- FormKey - {YourFormKey}
- FormVariables - {All Process Variables will be accessible}
- Form Data
- Form Data type can be used when the User intends to have the form for the current User Task to be autogenerated and instead defines all essential meta data inside the Workflow Designer that is required to auto-generate Form.
- User Task Instance will have these properties -
- FormType - FormData , property to distinguish the task Type
- FormVariables - {Process Variables & properties will be accessible that were defined at design time}
A User can add form key in OE Workflow Designer as shown below.
Sample Task Instance generated :
{
"_id" : ObjectId("59e48379883631802be7f997"),
"name" : "UserTask[USERS]",
"status" : "pending",
"processTokenId" : "a3495e6b-1a26-4ca7-9c66-6a9986e75935",
"candidateUsers" : [
"tony"
],
"formKey" : "SimpleApprovalForm",
"formType" : "FormKey",
"formVariables" : {
"fromDate" : "11/07/2014",
"toDate" : "14/07/2014",
"comments" : "Going home for Diwali"
},
"processInstanceId" : ObjectId("59e48379883631802be7f995"),
"_modifiedBy" : "user1",
"_modifiedOn" : ISODate("2017-10-16T15:31:33.714+05:30"),
"_isDeleted" : false,
"_version" : "f0568bec-714c-41f3-a0f9-d7541dbf2f89",
"workflowInstanceId" : ObjectId("59e48379883631802be7f994")
}
formKey, formType, formVariables will generated in form shown above.
A User can add form data in OE Workflow Designer as shown below.
Sample Task Instance generated :
{
"_id" : ObjectId("59e48371883631802be7f990"),
"name" : "UserTask[USERS]",
"status" : "pending",
"processTokenId" : "85c64ae9-e7ab-4f33-bd76-cfb827fda44c",
"candidateUsers" : [
"tony"
],
"formType" : "FormData",
"formVariables" : {
"fromDate" : {
"id" : "fromDate",
"label" : "From Date",
"type" : "date",
"defaultValue" : "11/07/2014",
"validations" : [
{
"name" : "readonly",
"config" : true
}
],
"properties" : []
},
"toDate" : {
"id" : "toDate",
"label" : "To Date",
"type" : "date",
"defaultValue" : "14/07/2014",
"validations" : [
{
"name" : "readonly",
"config" : true
}
],
"properties" : []
},
"comments" : {
"id" : "comments",
"label" : "Comments",
"type" : "string",
"defaultValue" : "Going home for Diwali",
"validations" : [
{
"name" : "readonly",
"config" : true
}
],
"properties" : []
},
"status" : {
"id" : "status",
"label" : "Status",
"type" : "string",
"defaultValue" : "approved",
"validations" : [],
"properties" : []
}
},
"processInstanceId" : ObjectId("59e48371883631802be7f98e"),
"_modifiedBy" : "user1",
"_modifiedOn" : ISODate("2017-10-16T15:31:25.390+05:30"),
"_isDeleted" : false,
"_version" : "fae1c84c-0de6-48b1-a479-e92e775de4a2",
"workflowInstanceId" : ObjectId("59e48371883631802be7f98d")
}
formKey, formType, formVariables will generated in form shown above.