I'm having a little problem with this solution in that the only the first placeholders are being output. For example, if I'm looking to output
Category 1
question 1
answer 1
question 2
answer 2
Category 2
question 3
answer 3
What I'm getting is
Category 1
question 1
answer 1
question 1
answer 1
Category 2
question 1
answer 1
Additionally, it looks like if I have above a certain amount of categories and questions and answers the resource wont save.
TV: FAQsCategory
[{"caption":"FAQ Categories", "fields": [
{"field":"category","caption":"Category"},
{"field":"faqs","caption":"FAQs","inputTV":"FAQs"}
]
}]
[{
"header": "Category", "sortable": "true", "dataIndex": "category"
}]
TV: FAQs
[{"caption":"FAQ", "fields": [
{"field":"question","caption":"Question"},
{"field":"answer","caption":"Answer","inputTV":"richtextTV"}
]
}]
[
{"header": "Question", "width": "160", "sortable": "true", "dataIndex": "question"},
{"header": "Answer", "width": "160", "sortable": "true", "dataIndex": "answer"}
]
Template: FAQTemplate
[[getImageList? &tvname=`FAQsCategory` &tpl=`outerFAQsTpl`]]
Chunk: outerFAQsTpl
<h3>[[+category]]</h3>
[[getImageList? &value=`[[+faqs]]` &tpl=`innerFAQsTpl`]]
Chunk: innerFAQsTpl
<p>[[+question]]</p>
[[+answer]]
If I substitute [[getImageList? &value=`[[+faqs]]` &tpl=`innerFAQsTpl`]] with [[+faqs]] I get
[{"MIGX_id":"1","question":"q1","answer":"
q1 answer
"}]
It must be something very obvious.
[ed. note: bob-rooney last edited this post 10 years ago.]