Script

Groovy scripts disappear in Bonita Studio 2022.1 or later versions.

Hello,

I have a serious issue when importing any project that previously ran Groovy scripts (version 1.0.1) into the Community Studio 2022-1 version.

Once imported and verified, it indicates that all Groovy scripts have disappeared, and indeed, they are not there. Has anyone else experienced the same issue? I've been searching and searching, but I can't find a solution.

Groovy scripts disappear in Bonita Studio 2022.1 or later versions.

Hello,

I have a serious issue when importing any project that previously ran Groovy scripts (version 1.0.1) into the Community Studio 2022-1 version.

Once imported and verified, it indicates that all Groovy scripts have disappeared, and indeed, they are not there. Has anyone else experienced the same issue? I've been searching and searching, but I can't find a solution.

Automatically set data to contract

I have a process which has a gateway, in one way I want to set data to a list property automatically (the data will always be the same).

For example, let's say I have a business object with an array of strings called "names", when I reach one specific task I want to automtically set names to something like ['George','Michael'] and then finish the task, the user does not even realize this task was completed.

How can I achieve this?

How using bonita user-defined function

I have create a test function but is not present in Groovy Script user-defined List :

package com.company.script

public class MesScripts {

public static String test() {
return "test"
}

}

Can you help me ?

Thanks

Decision table

Hello,
I asking about the possibility of making script lines in the decision table for making a transition or it is only a comparison test?
if yes, can I, in the groovy script, make controls on information of organisation actors (country, job,..) and also access to data in MySQL database?

Access DAO object in Constraint script

Hello All,

It seems it's not possible to access DAO objects in a Constraint validation script. For instance, when I try to validate using objectDAO.findByCode(input.myCode, 0, 1), I get the following error:

objectDAO is neither defined in the script nor in dependencies.

Is it so or am I doing something wrong? And if so, what alternative is feasible to validate input data against BDM (database) values?

Thank you in advance.

Remove item from BDM

How to remove a certain item from BDM through a script in Groovy?
I can access my BDM Logs but I can not delete them, how can I do this?

I'm getting the data from my PostgreSQL database and saving in my BDM to be able to display this data in a table in my UI Designer, that's fine, but I do not want the same information to be added twice in BDM, for that reason I created this script that checks if the information that is being fetched from my external database is no longer added in BDM

contentMimeType becomes null when Document is updated

I've created a document under Data and I am able to add and delete the files (I followed the example in http://community.bonitasoft.com/project/file-upload-and-download-process...)
When the following script is run in Operations to update an attached Document, the contentMimeType gets updated from application/pdf to null.

Using a groovy script in a groovy custom page?

I have a grrovy script "MyUtil.groovy" written using the "Development->Manage Groovy Scripts" menu option in the studio and use it extensively in various connectors, operations etc in my process.

However I'd now like to use it in groovy custom page as well, but cant get it to work.

"import MyUtil;" says it cant resolve.

And any attempt to use MyUtil.myFunction(...) in the page code also reports that there is no variable called "MyUtil".

I presume this is a class path issue, but cant work out how to tell the page code to use the script.

Any clues?

using PDFBox.jar in a groovy script

Hi, I need to take data of a PDF file, for that i want to use PDFbox. I imported the .jar via developement-> manage jars -> import. But when I want to code the sript, i cant import the libraries. So I want to know if there is anithing else i should do to be able to use this library.

Reagards
Mauro

Notifications