Problem understaning nesting for loops in ODS tempalte
Hi,
I am trying to create a small reporting engine and want to use pod as my rendering layer. I am having problems understanding how to nest loops, and what is the scope of each loop..
To clarify, my data is a tree-like structure. I have an object that has a details attribute. This attribute is a list to other objects that has details attribute .. and so on.
I would like to be able to render this data in a ODS template as follows:
Group X haeder
--------------
Group Y header
--------------
.
.
.
Details
.
.
.
--------------
Group Y footer
--------------
Group X footer
In django templates I was able to achieve this since I have full control over my loops and its scope. Can you please tell me how to achieve the same result using pod ods templates ? Currently, pod gives me a NameError when I try to use the iterator from a previous for loop.
P.S: I am using appy version 0.8.5 installed from pip in a python2.7 virtualenv.
Thanks.
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- Appy Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Ahmed Toulan for more information if necessary.