You can use Groovy scripting language to prepare data for any presentation layer screen rendering tool, including the FreeMarker templating engine and OFBiz widgets.
Groovy has been integrated into the OFBiz framework, so using it is as simple as creating a text file with Groovy code and then pointing one or more Screen widget actions
declarations to the location of the Groovy file.
Note
Note: a side effect of integration is that execution context information, including the HTTP/HTTPS request message and request parameters, are always available in the Groovy runtime context.
By convention, Groovy files are located in the webapp/WEB-INF/actions
directory of a containing Component. For example, we could have a Groovy file named myGroovyFile.groovy
located in the ~myComponent/webapp/WEB-INF/actions
directory.