In the sessionScoped managed bean(registered managed bean in the bounded task flow and also in the adfc-config.xml file) in ADF fusion web application I had set the attribute in the session as
FacesContext fctx = FacesContext.getCurrentInstance();
ExternalContext ectx = fctx.getExternalContext();
HttpSession userSession = (HttpSession) ectx.getSession(false);
userSession.setAttribute("compID", defaultCompany);
the session attribute is working fine in the bean and the value is being displayed in the jsff page of the bounded task flow and also on the jsf page which contains the bounded task flow as region
im getting the session attribute value on the page using the expression
"#{sessionScope.compID}"
inside the output text value property, but not able to get the value in the model project which contains the business components. I want to use the compID session attribute value in the query
Select.........where COMP_ID ='compID';
by setting the value in the bind variable value property and passing the newly creted bid variable in the where clause but its not working
so i how to use this dynamic session attribute value in the where clause of the query of the business component view object?
You could try doing what's mentioned in the below blog
http://andrejusb.blogspot.com/2012/01/how-to-access-session-scope-in-adf-bc.html
You need a service method on your VO or AM that accepts a parameter - you call this method in your JSF page and pass the session scope as the parameter. An example: https://blogs.oracle.com/shay/entry/passing_parameters_to_an_adf_p or https://blogs.oracle.com/shay/entry/am_service_method_-_simple_dem
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With