OFBiz
Search
everywhere
only in this topic
Advanced Search
Pass data from Java Events to FTL web context
‹
Previous Topic
Next Topic
›
Classic
List
Threaded
♦
♦
Locked
4 messages
UnclePetros
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Pass data from Java Events to FTL web context
Hi,
I need to find out how to pass data from Java Events to the FTL context.
I've tried to use getSession().getServletContext() in the java event, and the pass data with setAttribute() method.
But it seems do not work.
May be data in context is stored in a framework specific way?
Thank you in advance.
UnclePetros
Vinita Dhaka
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Re: Pass data from Java Events to FTL web context
Hi,
To pass data from java to FTL, you have to use groovy..
Regards
Vinita
UnclePetros
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Re: Pass data from Java Events to FTL web context
Thank you for the answer.
I know I can use Groovy.
But I don't understood why it is a must.
Why is it not possible to put the data in the Servlet in such a way it is directly accessible form FTL with a simple ${myData} ?
Is it just an ofbiz framework feature?
Thank you again.
UnclePetros
Vinita Dhaka
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Re: Pass data from Java Events to FTL web context
Hi,
When you will fetch ${myData} directy then how your FTL will understand which myData you want to fetch. But in case of groovy, you add that groovy in Screens.xml. In ofbiz groovy is used to fill dynamic data in FTL.
Regards,
Vinita
Free forum by Nabble
Edit this page