Connected repeaters

Hi,

I would like to develop a page where I show two related repeaters. The first one is compose of musical playlists (Rock, Techno…), and I would like to display some tracks of the genre the user clicks on. For example, if the user clicks on Rock, I would like to display a second repeater where I show some rock tracks.
I’ve tried different ways to achieve that, but none of them worked:

  • I used two repeaters and I apply a filter on the second one on the item selected in the first dataset, but I don’t know how to change the current item in the first dataset

  • I tried to change the current item in the dataset with wix code, but I can’t access the actual getCurrentItemIndex() inside a .onClick event handler

Do you have any ideas on how to perform such an action ?

Thanks