logs.unturf.com/templates/home.html.j2
Russell Ballestrini 5a5bd57bc3 * owners can remove and change roles of other namespace members.
* editors can invite log emitting agents without mailboxes using JWT tokens.
* guests can read logs from public namespaces.

	modified:   app.py
	modified:   openapi.yaml
	modified:   templates/base.html.j2
	modified:   templates/home.html.j2
	modified:   templates/manage_namespace.html.j2
2025-01-12 14:06:44 -05:00

48 lines
1.5 KiB
Django/Jinja

{% extends 'base.html.j2' %}
{% block title %}Home{% endblock %}
{% block content %}
<h1>Welcome to PyraLogs</h1>
<p>
{% if request.user and request.user.is_verified %}
Hello, {{ request.user.username }}!
{% else %}
Welcome, Guest!
{% endif %}
</p>
<p>This application allows environments and agents to centrally log events to this hub. You can create namespaces to organize logs and control access.</p>
{% if request.user and request.user.is_verified %}
<h2>Your Namespaces</h2>
{% if user_namespaces %}
<ul>
{% for ns in user_namespaces %}
<li>
<a href="{{ request.route_url('view_namespace_logs', namespace_short_id=ns.short_id) }}">{{ ns.name }} logs</a>
{% if ns.role == 'editor' or ns.role == 'owner' %}
| <a href="{{ request.route_url('manage_namespace', namespace_short_id=ns.short_id) }}">Manage</a>
{% endif %}
<br>
</li>
{% endfor %}
</ul>
{% else %}
<p>You are not a member of any namespaces.</p>
{% endif %}
{% endif %}
<h2>Public Namespaces</h2>
{% if public_namespaces %}
<ul>
{% for ns in public_namespaces %}
<li>
<a href="{{ request.route_url('view_namespace_logs', namespace_short_id=ns.short_id) }}">{{ ns.name }} logs</a>
</li>
{% endfor %}
</ul>
{% else %}
<p>No public namespaces available.</p>
{% endif %}
{% endblock %}