I have four checkboxes on the page and based on selection, data needs to be populated. I am able to send the checked items to server, like type1:true, type2:false, etc. But how to efficiently write if-else blocks to retrieve the data. The return type is same but I need to pick up from seperate tables and based on selection, I need to merge them. I am using dapper for db operations.
Share
Thanks for reply DarthVader, I am sorry for not providing enough information. Yes, I know how to write ifelse statements but was wondering if there can be any caching done by serving only one type at a time. It eliminates if-else statements. I got an idea now, by creating an js array for individual type and if it is empty, hit the server otherwise take from array.