Hi everyone,
I have a doubt regarding the iteration.
I created a definition json tiddler, it has this content:
{
"name": "def",
"items": {
"case1": "option1",
"case2": "option2",
"case3": "option3"
}
}
And an another tiddler, with this hardcode values, and i can see the result as a dropdown.
<$set name="jsondata" value={{definitionjson}}>
<$select field='mystatus' class='dropdown'>
<option>{{{[<jsondata>jsonget[items],[case1]]}}}</option>
<option>{{{[<jsondata>jsonget[items],[case2]]}}}</option>
<option>{{{[<jsondata>jsonget[items],[case3]]}}}</option>
</$select>
<$set>
But, i want to do it via list iteration,
I tried to use this, but it didnt work.
<select>
<$list filter="[<jsondata>jsonget[items]keys[]]">
<option><$view field="(key)" template="[<jsondata>jsonget[items][$index]keys[]]"/></option>
</$list>
</select>
How can i solve this? Can anyone guide me?
Thanks