summaryrefslogtreecommitdiffstats
path: root/templates/html/htmljsmenuletterdata.tpl
blob: e1c5679f42b8cc6c37474caf4e70b7d466068092 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{# inputs: page, list, section, text #}
{text:"{{ text }}",url:"{{ page.fileName }}{{ section }}{{ config.HTML_FILE_EXTENSION }}"
{% if list|length>maxItemsForFlatList %}
,children:[
  {% with index=list|alphaIndex:'name' %}
    {% for sect in index %}
      {% spaceless %}
      {text:"{{ sect.letter }}",url:"
      {% if list|length<=maxItemsForMultiPageList %}
      {{ page.fileName }}{{ section }}{{ config.HTML_FILE_EXTENSION }}#index_{{ sect.label }}"
      {% else %}
      {{ page.fileName }}{{ section }}_{{ sect.label }}{{ config.HTML_FILE_EXTENSION }}"
      {% endif %}
      }
      {% endspaceless %}
      {% if not forloop.last %},{% endif %}
    {% endfor %}
  {% endwith %}
]
{% endif %}
}