Djangoテンプレートの多次元辞書にアクセスしようとしています。第1レベルのキーは表示できますが、第2レベルのキー以降は何も表示されません。たとえば、辞書は次のように構成されています。
dictionary = {}
dictionary[first_level] = {}
dictionary[first_level][second_level] = {}
...
and so on
私が使用するDjangoテンプレートから:
{% for flk in dict %}
<!-- Using nested for from the following, no output is shown -->
{% for slk in dict.flk %}
<th>First level key : {{ flk }} Second level key : {{ slk }}</th>
{% endfor %}
<!-- -->
{% endfor %}
モデルを使用する必要がありますか、それともこの辞書を使用して使用できますか?
ありがとう