You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
1.1 KiB
28 lines
1.1 KiB
<html>
|
|
<body>
|
|
<nav>
|
|
<a href="{% url 'home' %}">Home</a>
|
|
{% if person.name == '' %}
|
|
<a href="{% url 'login_form' %}">Login</a>
|
|
<a href="{% url 'register_form' %}">Register</a>
|
|
{% else %}
|
|
<a href="{% url 'courses' %}">Courses</a>
|
|
<a href="{% url 'profile' %}">Profile</a>
|
|
<a href="{% url 'search' %}">Search</a>
|
|
<a href="{% url 'notifications_view' %}">Notifications</a>
|
|
<a href="{% url 'logout' %}">Logout</a>
|
|
{% endif %}
|
|
</nav>
|
|
<h1>Notifications</h1>
|
|
{% for message in messages %}
|
|
<a href="{% url 'details' message.channel %}">{{ message.data }}</a><br/>
|
|
{% endfor %}
|
|
<a href="{% url 'clear_notifications' %}">Clear notifications</a>
|
|
<script>
|
|
setInterval(function() {
|
|
window.location.reload();
|
|
}, 10000); // Reloads the page after 10s to avoid timeout
|
|
window.location.href = "{% url 'notifications' %}"; // Redirecting to listen to pub/sub
|
|
</script>
|
|
</body>
|
|
</html> |