Skip to content

Commit ca2e94f

Browse files
committed
basic html template for queryables
1 parent d77e986 commit ca2e94f

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

tifeatures/factory.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -460,7 +460,7 @@ def queryables(
460460
return create_html_response(
461461
request,
462462
data.json(exclude_none=True),
463-
template_name="collection",
463+
template_name="queryables",
464464
)
465465

466466
return data
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{% include "header.html" %}
2+
3+
<h1>Collection: {{ response.title or response.id }}</h1>
4+
5+
<div class="row">
6+
<div class="col-sm">
7+
<h2>Queryables</h2>
8+
<ul>
9+
{% for k,v in response.properties.items() %}
10+
<li>{% if '$ref' in v %}
11+
<a href="{{ v['$ref'] }}">{{ k }}</a>
12+
{% else %}
13+
{{ k }}: {{ v['type'] }}
14+
{% endif %}
15+
{% endfor %}
16+
</ul>
17+
</div>
18+
</div>
19+
20+
{% include "footer.html" %}

0 commit comments

Comments
 (0)