Just want to ask how to get a specific value of data after submitting on first task. After I click submit button and then the approver will click approve a sequential number depending on the company of the creator will be generated. I want to get the max number with the company if company is the same and have an existing number then +1 but if newly created processes without number then start with 1. But I cannot get the max number and the company of the processes as well. The task failed after I submit after approval. I do the generation on operations and set the number using groovy. See below code and custom query:
Unfortunely, the DAO obejct related to your object is not accessible from Groovy scripts, there is a knowm limitation that blocks us to use it. So you will never get your custom query executed and will always get a error !
I suggest you to do a connector before the task to get the desire information and in your groovy code for operation use it to increment and set to your object attribute.
Bonitasoft empowers development teams with Bonita, the open-source and extensible platform to solve the most demanding process automation use cases. The Bonita platform accelerates delivery of complex applications with clear separation between capabilities for visual programming and for coding. Bonita integrates with existing solutions, orchestrates heterogeneous systems, and provides deep visibility into processes across the organization.