I can do this in regular python, but can't seem to do this in the template.
So here are my variables:
PropertyID = ['A1','A2','A3']
filePaths = {A1:'['file1.jpg','file2.jpg','file3.jpg',]', A2:'['file1.jpg','file2.jpg','file3.jpg']'}
My template:
{% for properties in PropertyID %}
{% for filePaths in imageFiles %}
{% for singleFiles in filePaths %}
{% endfor %}
{% endfor %}
{% endfor %}
I want to be able to iterate through filePaths dynamically, but when I try:
{% for singleFiles in filePaths.{{properties}} %}
I get an error:
Could not parse the remainder: '{{properties}}' from 'filePaths.{{properties}}'
I have tried filePaths['properties'] and filePaths[properties] and pretty much every combination. I just can't figure out why this isn't working.
If I do filePaths.A1 it works fine, but I can't iterate over the rest of the paths this way.
Any help would be much appreciated, probably something really dumb I missed.