Hi, I want to suspend a Task when an user clicks on the cancel button on a jsf dialog. I found an hint with the ivy.task.reset(). But when use this function, i cannot finishing the process step due to an error (IllegalStateException: State of Task must be one of the following values...) What would be the best way to suspend a task and resume it later on? Thanks for help in advance. Regards, Daniel asked 26.07.2016 at 11:07 dharlach |
The easiest way to do it is to have a data object 'Status' which is set to "cancel" when entering the Dialog, if there is no change one then routes the process back to a 'dummy' action/step before the Task Switch, which can be taken up again by the User. For all other Button actions one sets a different status which then determines the path taken. answered 26.07.2016 at 15:52 RMS71 Thank you for your answer. But would that lead to a new task? Or did I understand you wrong?
(27.07.2016 at 10:43)
dharlach
1
You get a new Task (new Task ID) but the Data will remain the same. It is difficult to describe in words a picture would be easier. You are essentially making a loop if the status is 'cancel' Skript Step (Dummy)-> Task Step -> Dialog -> Alternative (Path 1 == cancel || Path 2...n == 'something else') Path 1 -> back to Skript Step (Dummy)
(27.07.2016 at 11:46)
RMS71
The 'old Task' is "DONE" or "COMPLETED" (I'm not sure what the actual status nomenclature is.
(27.07.2016 at 11:48)
RMS71
|
Once you sign in you will be able to subscribe for any updates here
By RSS:Markdown Basics
Tags:
Asked: 26.07.2016 at 11:07
Seen: 1,553 times
Last updated: 27.07.2016 at 11:48