Repeating text fields in dynamic pages

Hello,

I have been using a dynamic page on Wix with the idea to display books that are available to be borrowed.

There is a dataset that contains the books and has a boolean field of ‘available’, which depending on whether it is ticked, will display a ‘yes’ or ‘no’.


The code functions as it should, as was tested with a singular record in the dataset; however, as more records were added, the code no longer ran and displayed every record as ‘no’, regardless of the tick in the boolean field.


As seen above, I suspect this is due to the repeating text fields in the dynamic page, as #text6 is repeated through each of the containers.

I tried individually changing the name of each text field, but they are all linked.

Is there a way to make it so each container is separate from the others, or has a text field that is at least separate from the others?

Many thanks