Tree with check box with hierarchical check/uncheck feature
Hi,
I am building a tree with checkbox feature in APEX 3.2
My tree query looks like
select "SERVICE_ID" id
,"PARENT_ID" pid
,"SERVICE_NAME" name
,null link
,APEX_ITEM.CHECKBOX(1,SERVICE_ID) a1
,null a2
from "#OWNER#"."SERVICES_TEST"
start with "SERVICE_ID" =:P9_TREE_ROOT
connect by prior "SERVICE_ID" = "PARENT_ID"
So far so good. The tree displays properly
Now, my requirement is to check_all_child/uncheck_all_child when the parent is checked/unchecked.
Consider an example as
ROOT
-------SERVICE1
--------------SERVICE1_CHILD1
--------------SERVICE1_CHILD2
-------SERVICE2
--------------SERVICE2_CHILD1
-------SERVICE3
If SERVICE1 is checked, then SERVICE1_CHILD1 and SERVICE1_CHILD2 should be checked.
Could someone please help me on how to achieve it?
I can write a onchange function against checkbox, but I need to hierarchically check/uncheck and the hierarchy is dynamic.
Please do let me know if any other info is required.