Here goes something
This commit is contained in:
commit
a7d944bbd4
16 changed files with 2700 additions and 0 deletions
44
templates/node.html
Normal file
44
templates/node.html
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
{% extends "base.html" %}
|
||||
|
||||
{% block title %}{{ title }}{% endblock title %}
|
||||
|
||||
{%- block body %}
|
||||
<section>
|
||||
<h1>{{ title }}</h1>
|
||||
<code style="display: inline;">ID: {{ id }}</code>
|
||||
<p>{{ body }}</p>
|
||||
</section>
|
||||
{% if connections or incoming %}
|
||||
<aside>
|
||||
<hr>
|
||||
<h2>Connections</h2>
|
||||
{% if connections %}
|
||||
<ul>
|
||||
{% for connection in connections %}
|
||||
<li>
|
||||
<strong>{{id}}</strong>
|
||||
🡪
|
||||
<a href="/node/{{connection.to}}">{{connection.to}}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% else %}
|
||||
<em>No outgoing connections.</em>
|
||||
{% endif %}
|
||||
{% if incoming %}
|
||||
<h3>Incoming connections</h3>
|
||||
<ul>
|
||||
{% for connection in incoming %}
|
||||
<li>
|
||||
<strong>{{connection.to}}</strong>
|
||||
🡨
|
||||
<a href="/node/{{connection.from}}">{{connection.from}}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</aside>
|
||||
{% else %}
|
||||
<em>Node has no connections.</em>
|
||||
{% endif %}
|
||||
{%- endblock body %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue