Create Department poplist VO
Master VO: select dname,deptno from dept
Create Emplyee Poplist VO
Child VO:
select ename,empno from emp where deptno=:1
Write below code under controller for dependent poplist in table level.
In Process Request
-----------------------
OATableBean tableBean=(OATableBean)webBean.findchildRecursive("TableBean");
OAMessageChoiceBean omcb1=(OAMessageChoiceBean)tableBean.findIndexedChildRecursive("Department");
OAMessageChoiceBean omcb2=(OAMessageChoiceBean)tableBean.findIndexedChildRecursive("Employee");
omcb1.setPickListCacheEnabled(false);
omcb2.setPickListCacheEnabled(false);
omcb2.setListVOBoundContainerColumn(0,tableBean,"Department");
In ProcessFormRequest
---------------
if("event".equalse(pageContext.getParameter(EVENT_PARAM))
{
Initilize ChildVO
childvo.executeQuery();
}
Master VO: select dname,deptno from dept
Create Emplyee Poplist VO
Child VO:
select ename,empno from emp where deptno=:1
Write below code under controller for dependent poplist in table level.
In Process Request
-----------------------
OATableBean tableBean=(OATableBean)webBean.findchildRecursive("TableBean");
OAMessageChoiceBean omcb1=(OAMessageChoiceBean)tableBean.findIndexedChildRecursive("Department");
OAMessageChoiceBean omcb2=(OAMessageChoiceBean)tableBean.findIndexedChildRecursive("Employee");
omcb1.setPickListCacheEnabled(false);
omcb2.setPickListCacheEnabled(false);
omcb2.setListVOBoundContainerColumn(0,tableBean,"Department");
In ProcessFormRequest
---------------
if("event".equalse(pageContext.getParameter(EVENT_PARAM))
{
Initilize ChildVO
childvo.executeQuery();
}
No comments:
Post a Comment