How to disable adf default row selection in <af:table>?
Problem Definition
In day to day development we faced common issue with using af:table row selection, because adf provide 1 row default selected. Some custom event we defined on row selection are not getting triggered on row if there is single row in table. It cause very big problem in application if those event must be triggered to populate some other data on row selection.
Solution Proposed
Solution I am proposing can solve that issue. I didn't tested every aspect but tested the scenario of making selected row as current row. After making these changes current row is getting set to viewobject properly and returning right values.
Remove the selectedRowKeys from <af:table>
After making these changes you screen looks like:
Here no row is selected in first table but first row is the current row in viewobject hence child table is showing default data for first row. you can make some changes to first view object so that there won't be any current row in viewobject. In that case child table won't display any row.
Anyway lets focus on the selection event triggering on first table. Now I have selected second row form first table and corresponding child record are showing in second table.
Above testcase proved that there is no problem with selection event while removing the selectedRowKeys property of <af:table>
Find the working sample application on Sample Application
Hi Amit!
ReplyDeleteYou wrote: "Here no row is selected in first table but first row is the current row in viewobject hence child table is showing default data for first row. you can make some changes to first view object so that there won't be any current row in viewobject."
Could you please explain what kind of changes in the first viewobject I have to do to reset currency. I need the second table to not show any data until the user selects row in first table explicitly.
Thanks in advance.
Mike
Hi Amit,
ReplyDeleteExcellent it works for me. Thanks you so much for post.
Srikanth
You wrote: "Here no row is selected in first table but first row is the current row in viewobject hence child table is showing default data for first row. you can make some changes to first view object so that there won't be any current row in viewobject."
ReplyDeleteCould you please explain what kind of changes in the first viewobject I have to do to reset currency. I need the second table to not show any data until the user selects row in first table explicitly.
Thanks
Raj
Wondering you know the solution or want us to work on it :P
DeleteNot able to download sample application its broken
ReplyDeleteI appreciate that you produced this wonderful article to help us get more knowledge about this topic.
ReplyDeleteI know, it is not an easy task to write such a big article in one day, I've tried that and I've failed. But, here you are, trying the big task and finishing it off and getting good comments and ratings. That is one hell of a job done!
Selenium training in bangalore
Selenium training in Chennai
Selenium training in Bangalore
Selenium training in Pune
Selenium Online training
Selenium interview questions and answers
Thanks you for sharing this unique useful information content with us. Really awesome work. keep on blogging
ReplyDeletepython training in chennai
Python Online training in usa
python course institute in chennai
Nice post. By reading your blog, i get inspired and this provides some useful information. Thank you for posting this exclusive post for our vision.
ReplyDeletepython training in chennai
Python Online training in usa
python course institute in chennai
This is the exact information I am been searching for, Thanks for sharing the required infos with the clear update and required points. To appreciate this I like to share some useful information.
ReplyDeleteaws training in bangalore
aws courses in bangalore
aws classes in bangalore
aws training institute in bangalore
aws course syllabus
best aws training
aws training centers
I have to voice my passion for your kindness giving support to those people that should have guidance on this important matter.
ReplyDeletesap s4 hana training in bangalore
sap s4 hana courses in bangalore
sap s4 hana classes in bangalore
sap s4 hana training institute in bangalore
sap s4 hana course syllabus
best sap s4 hana training
sap s4 hana training centers
whatsapp goruntulu show
ReplyDeleteshow
LERPS