This content has been marked as final.
Show 5 replies
-
1. Re: Task form cancel button not working
naseem.k May 28, 2007 2:59 AM (in response to naseem.k)Class TaskForm.java.
If condition defined in the try block checks formButton an instance of CancelButton? If condition is true, then outcome is set to "cancel".public void processAction(ActionEvent actionEvent) throws AbortProcessingException { ..... try { if (formButton instanceof CancelButton) { //formButton.setDisabled(true); log.debug("Cancel button was pressed"); outcome = "cancel"; if (creationLogsVar != null) { requestMap.put(creationLogsVar, Collections.EMPTY_LIST); } commit = true; return; } } ... }
In the view.xhtml by <jbpm:outcome custom tag, there is a redirect. Task instance id query parameter is not submitted due to this redirect after a user click the cancel button. Therefore the custom tag which is responsible for rendering the process image tag throws NullPointerException.<jbpm:outcome outcome="cancel" type="redirect"/>
Url of Task Instance View page before cancel button is clicked: http://localhost/main/task/view.html?tiid=11863
Url of Task Instance View page after cancel button is clicked: http://localhost/main/task/view.html
I managed to solve the NullpointerException problem by changing the type to "stay".
Still I don't know what is the purpose of cancel task form button?
Is this cancel button for stopping a process which you started? -
2. Re: Task form cancel button not working
kukeltje May 28, 2007 6:43 AM (in response to naseem.k)
Is this cancel button for stopping a process which you started?
No, it is for saying: "I'm not going to work on this task now, put it back in my tasklist" -
3. Re: Task form cancel button not working
naseem.k May 28, 2007 7:25 AM (in response to naseem.k)"kukeltje" wrote:
No, it is for saying: "I'm not going to work on this task now, put it back in my tasklist"
So it means if I write following code in the view.xhtml, this will work.<jbpm:outcome outcome="cancel" type="view" target="/search/tasks.xhtml"/>
One more thing I want to know, if a user fills a task form and then she decides to click the cancel button, will jbpm store user entered values in database or not?
Thanks -
4. Re: Task form cancel button not working
kukeltje May 28, 2007 7:31 AM (in response to naseem.k)1: no idea, not used that before
2: No, NOT going to work on it.... working on it but not finishing it is 'save' -
5. Re: Task form cancel button not working
naseem.k May 28, 2007 10:49 AM (in response to naseem.k)Thanks Ronald for making things clear.
It seems like its a bug in the current jbpm-console web application which I am having. I don't know how many others get NullPointerException after clicking the cancel task form button.