Pull id's from a list of dcc objects

I have 15 dcc.Modal’s and I would like to iterate through them to get id’s for the modals, buttons (every modal has a submit button), and the datepickers within them for my lengthy callback. What’s a good way to iterate through a dcc object?

Hello! I would say the longest one is the one I am about to write which will be close to 30. I am contemplating restructuring my approach to having only the children of a modal change depending on what the user clicks. The new approach would limit the Inputs to just 3 or 4. It’s just going to be more work on the backend to generate the modal’s children but probably much less of a headache with thinking through all the possible variations and coding them. My longest callback ever was probably close to 15 inputs.