CMMN Human task, bypass/skip tasklist

Hi everyone,

I’m currently working on a CMMN model which includes a Human Task. I have a use case where the user can choose which tasks he/she want to perform. Currently they firstly have to “activate” the human task, then navigate to the tasklist, fill-out the form and finally submit it. I would prefer to do this all in 1 action (manual starting and task completion).

Currently, I send the form data to the engine when I perform the “manual start”. The problem is that still a task is created on the task list of the user.

I tried to “complete” it in the manual start case execution listener and in the task listener of the human task, but both error on database flush (I guess due to foreign key issues).

My question is how I can best implement this. Is there a way to “bypass” or “skip” the creation of a task, or is there any other way I can manually start and complete the task in 1 go? Or am I obliged to first do the manual-start, search for the newly created task in the task list (can be done opaque to the user using JS) and then completing the task?

Thank you in advance.

Kind regards

Pieter

Could you please elaborate on this? So you have a custom UI that would offer a form and that form should be used to do all the steps you mention in one go with a single click and without switching applications. Is my understanding correct?

Cheers,
Thorben

Hi @thorben,

We indeed have a custom UI that uses the Camunda REST API as an entrypoint. My question is not related to making the custom UI, but if there is a possibility to handle this behaviour in the engine. I would prefer the task being closed immediately (hence my guess to use the listeners) or not being created at all.

I hope this clarifies my use case.

Kind regards

Pieter

Hi @Pieter_Vincken,

Is it possible for you to set the manual activation rule 1 to false? In that case the tasks would get auto activated. This means the user does not have to activate the task manually. As a consequence, the task is active and the user can fill out the form and just complete the task. When the task gets completed you could send the form data to engine. So, you have to send just one request.
If the other task is not necessary to execute anymore, it can be terminated manually by the user or you could use an exit criterion 2. But

Does it help you?

Cheers,
Roman

Hi @roman.smirnov,

Thank you for you response.

This would not really fix the issue we have, since it would still generate a task on the tasklist. It would actually prevent the user from choosing when the task would be available, which is the feature I would like to enable.

Kind regards

Pieter

Hi,

Currently I don’t see any other option than to just use the manual start to submit the data to the engine and then (through the REST API) complete the task with no data. This will make it as transparent to the user as possible and provide us with the flexibility we need.

If any other solutions pop-up, I will post them here.

Kind regards

Pieter

Hi all,

We’ve finally found the (really easy -.-) solution to the question I posted. You could just use a unspecified case task in your model. This way you can trigger it through a manual start and it won’t generate a task on the tasklist. It will just complete.

Sometimes it is just that simple…

Kind regards

Pieter