Assuming you need something to work - more or less - like this, why don't you just set the entire Object from the repeat in a Variable?
Let me rephrase that, why do you want to break up the object and put it into a var? If you add the entire object into a var you can then use the data from the object in the modal.