It consists of a web page that has a series of radio button lists. When one of the lists is chosen and the value is switched to send email there needs to be an email sent from that particular radiobutton list. After all of the radio button lists have had their value changed to email sent then the activity completes. (The completion part I have figured out) I am not sure how to exactly approach this to get it to work. The emails can be sent in any order and I would like for the user to be able to go back to the same link each time for the web page. I do not really want to create an activity for each email requirement (there are 7 emails). Any ideas?
How to approach - Many actions from one worklist item
If I understand your requirements correctly, the users need to configure multiple emails as part of the same task. Only once the list of emails has been sent, can the Activity complete.
If that's the case, I would stick to either sending the mails directly from the web page (after each email has been configured) or:
Collect all the information up front and then send email from the K2 Server by modifying the standard email template to iterate through the data collected on the web page. This can be done using SmartObjects or XML.
I think sending the mails from the web pages might be slightly easier, especially if you create wrapper classes.
Well, you could track it. By using an XML field containing the list of emails to be sent along with the statuses (Send or Not Send) you have full visibility and can also decide when the activity is complete (all mails == Send). You current approach will still work but it seems a bit complicated unless of course you need to visually keep track of the current status (you can also track meta data in your XML field).
You must also remember that from the Workflow side, the logical steps are the important ones, individual tasks like filling up different fields, etc. are more related to your business tasks. My POV anyways.
Reply
Enter your username or e-mail address. We'll send you an e-mail with instructions to reset your password.