Skip to content
Snippets Groups Projects
Commit 24cf5e56 authored by Nadja Geisler's avatar Nadja Geisler :sunny:
Browse files

Merge branch 'feature-akdetail-featured-slot'

Clean up language files

# Conflicts:
#	AKSubmission/locale/de_DE/LC_MESSAGES/django.po
parents 5aa09956 9de0953b
Branches
No related tags found
No related merge requests found
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-09-20 21:40+0000\n" "POT-Creation-Date: 2020-11-03 17:40+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
......
...@@ -2,7 +2,7 @@ msgid "" ...@@ -2,7 +2,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-09-29 23:27+0000\n" "POT-Creation-Date: 2020-11-03 17:40+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
......
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-07-12 16:40+0000\n" "POT-Creation-Date: 2020-11-03 17:40+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
......
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-05-19 06:38+0000\n" "POT-Creation-Date: 2020-11-03 17:40+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
......
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-09-28 22:17+0000\n" "POT-Creation-Date: 2020-11-03 17:40+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
...@@ -66,7 +66,7 @@ msgstr "AK" ...@@ -66,7 +66,7 @@ msgstr "AK"
#: AKSubmission/templates/AKSubmission/ak_edit.html:13 #: AKSubmission/templates/AKSubmission/ak_edit.html:13
#: AKSubmission/templates/AKSubmission/ak_history.html:16 #: AKSubmission/templates/AKSubmission/ak_history.html:16
#: AKSubmission/templates/AKSubmission/ak_overview.html:27 #: AKSubmission/templates/AKSubmission/ak_overview.html:27
#: AKSubmission/templates/AKSubmission/akmessage_add.html:12 #: AKSubmission/templates/AKSubmission/akmessage_add.html:13
#: AKSubmission/templates/AKSubmission/akowner_create_update.html:12 #: AKSubmission/templates/AKSubmission/akowner_create_update.html:12
#: AKSubmission/templates/AKSubmission/akslot_add_update.html:12 #: AKSubmission/templates/AKSubmission/akslot_add_update.html:12
#: AKSubmission/templates/AKSubmission/akslot_delete.html:12 #: AKSubmission/templates/AKSubmission/akslot_delete.html:12
...@@ -104,11 +104,14 @@ msgid "History" ...@@ -104,11 +104,14 @@ msgid "History"
msgstr "Versionsgeschichte" msgstr "Versionsgeschichte"
#: AKSubmission/templates/AKSubmission/ak_detail.html:59 #: AKSubmission/templates/AKSubmission/ak_detail.html:59
msgid "Add confident message to organizers" #: AKSubmission/templates/AKSubmission/akmessage_add.html:8
msgstr "" #: AKSubmission/templates/AKSubmission/akmessage_add.html:16
#: AKSubmission/templates/AKSubmission/akmessage_add.html:22
msgid "Add confidential message to organizers"
msgstr "Sende eine provate Nachricht an das Organisationsteam"
#: AKSubmission/templates/AKSubmission/ak_detail.html:62 #: AKSubmission/templates/AKSubmission/ak_detail.html:62
#: AKSubmission/templates/AKSubmission/ak_detail.html:177 #: AKSubmission/templates/AKSubmission/ak_detail.html:201
#: AKSubmission/templates/AKSubmission/ak_edit.html:16 #: AKSubmission/templates/AKSubmission/ak_edit.html:16
#: AKSubmission/templates/AKSubmission/ak_table.html:53 #: AKSubmission/templates/AKSubmission/ak_table.html:53
msgid "Edit" msgid "Edit"
...@@ -120,89 +123,116 @@ msgstr "Bearbeiten" ...@@ -120,89 +123,116 @@ msgstr "Bearbeiten"
msgid "AK Wish" msgid "AK Wish"
msgstr "AK-Wunsch" msgstr "AK-Wunsch"
#: AKSubmission/templates/AKSubmission/ak_detail.html:71 #: AKSubmission/templates/AKSubmission/ak_detail.html:74
#, python-format
msgid ""
"\n"
" This AK currently takes place for another "
"%(featured_slot_remaining)s minute(s) in %(room)s.&nbsp;\n"
" "
msgstr ""
"\n"
" Dieser AK findet noch %(featured_slot_remaining)s "
"Minute(n) in %(room)s statt.&nbsp;\n"
" "
#: AKSubmission/templates/AKSubmission/ak_detail.html:79
#, python-format
msgid ""
"\n"
" This AK starts in %(featured_slot_remaining)s "
"minute(s) in %(room)s.&nbsp;\n"
" "
msgstr ""
"\n"
" This AK beginnt in %(featured_slot_remaining)s "
"Minute(n) in %(room)s.&nbsp;\n"
" "
#: AKSubmission/templates/AKSubmission/ak_detail.html:86
#: AKSubmission/templates/AKSubmission/ak_detail.html:209
msgid "Go to virtual room"
msgstr "Zum virtuellen Raum"
#: AKSubmission/templates/AKSubmission/ak_detail.html:95
#: AKSubmission/templates/AKSubmission/ak_table.html:10 #: AKSubmission/templates/AKSubmission/ak_table.html:10
msgid "Who?" msgid "Who?"
msgstr "Wer?" msgstr "Wer?"
#: AKSubmission/templates/AKSubmission/ak_detail.html:77 #: AKSubmission/templates/AKSubmission/ak_detail.html:101
#: AKSubmission/templates/AKSubmission/ak_history.html:36 #: AKSubmission/templates/AKSubmission/ak_history.html:36
#: AKSubmission/templates/AKSubmission/ak_table.html:11 #: AKSubmission/templates/AKSubmission/ak_table.html:11
msgid "Category" msgid "Category"
msgstr "Kategorie" msgstr "Kategorie"
#: AKSubmission/templates/AKSubmission/ak_detail.html:84 #: AKSubmission/templates/AKSubmission/ak_detail.html:108
#: AKSubmission/templates/AKSubmission/ak_history.html:37 #: AKSubmission/templates/AKSubmission/ak_history.html:37
msgid "Track" msgid "Track"
msgstr "Track" msgstr "Track"
#: AKSubmission/templates/AKSubmission/ak_detail.html:89 #: AKSubmission/templates/AKSubmission/ak_detail.html:113
msgid "Present this AK" msgid "Present this AK"
msgstr "Diesen AK vorstellen" msgstr "Diesen AK vorstellen"
#: AKSubmission/templates/AKSubmission/ak_detail.html:93 #: AKSubmission/templates/AKSubmission/ak_detail.html:117
#: AKSubmission/templates/AKSubmission/ak_table.html:12 #: AKSubmission/templates/AKSubmission/ak_table.html:12
msgid "Tags" msgid "Tags"
msgstr "Tags" msgstr "Tags"
#: AKSubmission/templates/AKSubmission/ak_detail.html:99 #: AKSubmission/templates/AKSubmission/ak_detail.html:123
msgid "Reso?" msgid "Reso?"
msgstr "Reso?" msgstr "Reso?"
#: AKSubmission/templates/AKSubmission/ak_detail.html:106 #: AKSubmission/templates/AKSubmission/ak_detail.html:130
msgid "Requirements" msgid "Requirements"
msgstr "Anforderungen" msgstr "Anforderungen"
#: AKSubmission/templates/AKSubmission/ak_detail.html:119 #: AKSubmission/templates/AKSubmission/ak_detail.html:143
msgid "Conflicting AKs" msgid "Conflicting AKs"
msgstr "AK Konflikte" msgstr "AK Konflikte"
#: AKSubmission/templates/AKSubmission/ak_detail.html:127 #: AKSubmission/templates/AKSubmission/ak_detail.html:151
msgid "Prerequisite AKs" msgid "Prerequisite AKs"
msgstr "AK Voraussetzungen" msgstr "AK Voraussetzungen"
#: AKSubmission/templates/AKSubmission/ak_detail.html:135 #: AKSubmission/templates/AKSubmission/ak_detail.html:159
msgid "Notes" msgid "Notes"
msgstr "Notizen" msgstr "Notizen"
#: AKSubmission/templates/AKSubmission/ak_detail.html:152 #: AKSubmission/templates/AKSubmission/ak_detail.html:176
#: AKSubmission/templates/AKSubmission/akslot_delete.html:35 #: AKSubmission/templates/AKSubmission/akslot_delete.html:35
msgid "Duration" msgid "Duration"
msgstr "Dauer" msgstr "Dauer"
#: AKSubmission/templates/AKSubmission/ak_detail.html:154 #: AKSubmission/templates/AKSubmission/ak_detail.html:178
msgid "When?" msgid "When?"
msgstr "Wann?" msgstr "Wann?"
#: AKSubmission/templates/AKSubmission/ak_detail.html:155 #: AKSubmission/templates/AKSubmission/ak_detail.html:179
msgid "Room" msgid "Room"
msgstr "Raum" msgstr "Raum"
#: AKSubmission/templates/AKSubmission/ak_detail.html:180 #: AKSubmission/templates/AKSubmission/ak_detail.html:204
msgid "Delete" msgid "Delete"
msgstr "Löschen" msgstr "Löschen"
#: AKSubmission/templates/AKSubmission/ak_detail.html:185 #: AKSubmission/templates/AKSubmission/ak_detail.html:215
msgid "Go to virtual room"
msgstr "Zum virtuellen Raum"
#: AKSubmission/templates/AKSubmission/ak_detail.html:191
msgid "Schedule" msgid "Schedule"
msgstr "Schedule" msgstr "Schedule"
#: AKSubmission/templates/AKSubmission/ak_detail.html:203 #: AKSubmission/templates/AKSubmission/ak_detail.html:227
msgid "Add another slot" msgid "Add another slot"
msgstr "Einen neuen AK-Slot hinzufügen" msgstr "Einen neuen AK-Slot hinzufügen"
#: AKSubmission/templates/AKSubmission/ak_detail.html:207 #: AKSubmission/templates/AKSubmission/ak_detail.html:231
msgid "Possible Times" msgid "Possible Times"
msgstr "Mögliche Zeiten" msgstr "Mögliche Zeiten"
#: AKSubmission/templates/AKSubmission/ak_detail.html:211 #: AKSubmission/templates/AKSubmission/ak_detail.html:235
msgid "Start" msgid "Start"
msgstr "Start" msgstr "Start"
#: AKSubmission/templates/AKSubmission/ak_detail.html:212 #: AKSubmission/templates/AKSubmission/ak_detail.html:236
msgid "End" msgid "End"
msgstr "Ende" msgstr "Ende"
...@@ -234,7 +264,7 @@ msgstr "Diesen AK vorstellen" ...@@ -234,7 +264,7 @@ msgstr "Diesen AK vorstellen"
msgid "Reso" msgid "Reso"
msgstr "Reso" msgstr "Reso"
#: AKSubmission/templates/AKSubmission/ak_list.html:6 AKSubmission/views.py:34 #: AKSubmission/templates/AKSubmission/ak_list.html:6 AKSubmission/views.py:39
msgid "All AKs" msgid "All AKs"
msgstr "Alle AKs" msgstr "Alle AKs"
...@@ -258,24 +288,18 @@ msgstr "Details" ...@@ -258,24 +288,18 @@ msgstr "Details"
msgid "There are no AKs in this category yet" msgid "There are no AKs in this category yet"
msgstr "Es gibt noch keine AKs in dieser Kategorie" msgstr "Es gibt noch keine AKs in dieser Kategorie"
#: AKSubmission/templates/AKSubmission/akmessage_add.html:7 #: AKSubmission/templates/AKSubmission/akmessage_add.html:28
#: AKSubmission/templates/AKSubmission/akmessage_add.html:15
#: AKSubmission/templates/AKSubmission/akmessage_add.html:21
msgid "Add message to organizers"
msgstr ""
#: AKSubmission/templates/AKSubmission/akmessage_add.html:27
msgid "Send" msgid "Send"
msgstr "Senden" msgstr "Senden"
#: AKSubmission/templates/AKSubmission/akmessage_add.html:31 #: AKSubmission/templates/AKSubmission/akmessage_add.html:32
#: AKSubmission/templates/AKSubmission/akowner_create_update.html:27 #: AKSubmission/templates/AKSubmission/akowner_create_update.html:27
#: AKSubmission/templates/AKSubmission/akslot_add_update.html:30 #: AKSubmission/templates/AKSubmission/akslot_add_update.html:30
#: AKSubmission/templates/AKSubmission/submit_new.html:45 #: AKSubmission/templates/AKSubmission/submit_new.html:45
msgid "Reset Form" msgid "Reset Form"
msgstr "Formular leeren" msgstr "Formular leeren"
#: AKSubmission/templates/AKSubmission/akmessage_add.html:35 #: AKSubmission/templates/AKSubmission/akmessage_add.html:36
#: AKSubmission/templates/AKSubmission/akowner_create_update.html:31 #: AKSubmission/templates/AKSubmission/akowner_create_update.html:31
#: AKSubmission/templates/AKSubmission/akslot_add_update.html:34 #: AKSubmission/templates/AKSubmission/akslot_add_update.html:34
#: AKSubmission/templates/AKSubmission/akslot_delete.html:46 #: AKSubmission/templates/AKSubmission/akslot_delete.html:46
...@@ -366,64 +390,64 @@ msgstr "" ...@@ -366,64 +390,64 @@ msgstr ""
msgid "Submit" msgid "Submit"
msgstr "Eintragen" msgstr "Eintragen"
#: AKSubmission/views.py:65 #: AKSubmission/views.py:70
msgid "Wishes" msgid "Wishes"
msgstr "Wünsche" msgstr "Wünsche"
#: AKSubmission/views.py:65 #: AKSubmission/views.py:70
msgid "AKs one would like to have" msgid "AKs one would like to have"
msgstr "" msgstr ""
"AKs die sich gewünscht wurden, aber bei denen noch nicht klar ist, wer sie " "AKs die sich gewünscht wurden, aber bei denen noch nicht klar ist, wer sie "
"macht. Falls du dir das vorstellen kannst, trag dich einfach ein" "macht. Falls du dir das vorstellen kannst, trag dich einfach ein"
#: AKSubmission/views.py:81 #: AKSubmission/views.py:86
msgid "Currently planned AKs" msgid "Currently planned AKs"
msgstr "Aktuell geplante AKs" msgstr "Aktuell geplante AKs"
#: AKSubmission/views.py:157 #: AKSubmission/views.py:184
msgid "Event inactive. Cannot create or update." msgid "Event inactive. Cannot create or update."
msgstr "Event inaktiv. Hinzufügen/Bearbeiten nicht möglich." msgstr "Event inaktiv. Hinzufügen/Bearbeiten nicht möglich."
#: AKSubmission/views.py:173 #: AKSubmission/views.py:200
msgid "AK successfully created" msgid "AK successfully created"
msgstr "AK erfolgreich angelegt" msgstr "AK erfolgreich angelegt"
#: AKSubmission/views.py:231 #: AKSubmission/views.py:258
msgid "AK successfully updated" msgid "AK successfully updated"
msgstr "AK erfolgreich aktualisiert" msgstr "AK erfolgreich aktualisiert"
#: AKSubmission/views.py:261 #: AKSubmission/views.py:288
msgid "Interest saved" msgid "Interest saved"
msgstr "Interesse gespeichert" msgstr "Interesse gespeichert"
#: AKSubmission/views.py:310 #: AKSubmission/views.py:337
msgid "Person Info successfully updated" msgid "Person Info successfully updated"
msgstr "Personen-Info erfolgreich aktualisiert" msgstr "Personen-Info erfolgreich aktualisiert"
#: AKSubmission/views.py:330 #: AKSubmission/views.py:357
msgid "No user selected" msgid "No user selected"
msgstr "Keine Person ausgewählt" msgstr "Keine Person ausgewählt"
#: AKSubmission/views.py:356 #: AKSubmission/views.py:383
msgid "AK Slot successfully added" msgid "AK Slot successfully added"
msgstr "AK-Slot erfolgreich angelegt" msgstr "AK-Slot erfolgreich angelegt"
#: AKSubmission/views.py:370 #: AKSubmission/views.py:397
msgid "You cannot edit a slot that has already been scheduled" msgid "You cannot edit a slot that has already been scheduled"
msgstr "Bereits geplante AK-Slots können nicht mehr bearbeitet werden" msgstr "Bereits geplante AK-Slots können nicht mehr bearbeitet werden"
#: AKSubmission/views.py:380 #: AKSubmission/views.py:407
msgid "AK Slot successfully updated" msgid "AK Slot successfully updated"
msgstr "AK-Slot erfolgreich aktualisiert" msgstr "AK-Slot erfolgreich aktualisiert"
#: AKSubmission/views.py:393 #: AKSubmission/views.py:420
msgid "You cannot delete a slot that has already been scheduled" msgid "You cannot delete a slot that has already been scheduled"
msgstr "Bereits geplante AK-Slots können nicht mehr gelöscht werden" msgstr "Bereits geplante AK-Slots können nicht mehr gelöscht werden"
#: AKSubmission/views.py:403 #: AKSubmission/views.py:430
msgid "AK Slot successfully deleted" msgid "AK Slot successfully deleted"
msgstr "AK-Slot erfolgreich angelegt" msgstr "AK-Slot erfolgreich angelegt"
#: AKSubmission/views.py:424 #: AKSubmission/views.py:451
msgid "Message to organizers successfully saved" msgid "Message to organizers successfully saved"
msgstr "Nachricht an die Organisator*innen erfolgreich gespeichert" msgstr "Nachricht an die Organisator*innen erfolgreich gespeichert"
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
title="{% trans 'History' %}" class="btn btn-light">{% fa5_icon 'clock' 'fas' %}</a> title="{% trans 'History' %}" class="btn btn-light">{% fa5_icon 'clock' 'fas' %}</a>
{% if ak.event.active %} {% if ak.event.active %}
<a href="{% url 'submit:akmessage_add' event_slug=ak.event.slug pk=ak.pk %}" data-toggle="tooltip" <a href="{% url 'submit:akmessage_add' event_slug=ak.event.slug pk=ak.pk %}" data-toggle="tooltip"
title="{% trans 'Add confident message to organizers' %}" title="{% trans 'Add confidential message to organizers' %}"
class="btn btn-warning">{% fa5_icon 'envelope' 'fas' %}</a> class="btn btn-warning">{% fa5_icon 'envelope' 'fas' %}</a>
<a href="{% url 'submit:ak_edit' event_slug=ak.event.slug pk=ak.pk %}" data-toggle="tooltip" <a href="{% url 'submit:ak_edit' event_slug=ak.event.slug pk=ak.pk %}" data-toggle="tooltip"
title="{% trans 'Edit' %}" title="{% trans 'Edit' %}"
...@@ -66,6 +66,31 @@ ...@@ -66,6 +66,31 @@
<h2>{% if ak.wish %}{% trans "AK Wish" %}: {% endif %}{{ ak.name }}</h2> <h2>{% if ak.wish %}{% trans "AK Wish" %}: {% endif %}{{ ak.name }}</h2>
{# Show current or upcoming slot featured in a box on top of the plage #}
{% if featured_slot_type != "NONE" %}
<div class="card border-success mt-3 mb-3">
<div class="card-body font-weight-bold">
{% if featured_slot_type == "CURRENT" %}
{% blocktrans with room=featured_slot.room %}
This AK currently takes place for another {{ featured_slot_remaining }} minute(s) in {{ room }}.
&nbsp;
{% endblocktrans %}
{% elif featured_slot_type == "UPCOMING" %}
{% blocktrans with room=featured_slot.room %}
This AK starts in {{ featured_slot_remaining }} minute(s) in {{ room }}.&nbsp;
{% endblocktrans %}
{% endif %}
{% if "AKOnline"|check_app_installed and featured_slot.room.virtualroom and featured_slot.room.virtualroom.url != '' %}
<a class="btn btn-success" href="{{ featured_slot.room.virtualroom.url }}">
{% fa5_icon 'external-link-alt' 'fas' %} {% trans "Go to virtual room" %}
</a>
{% endif %}
</div>
</div>
{% endif %}
<table class="table table-borderless"> <table class="table table-borderless">
<tr> <tr>
<td>{% trans "Who?" %}</td> <td>{% trans "Who?" %}</td>
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
{% load bootstrap4 %} {% load bootstrap4 %}
{% load fontawesome_5 %} {% load fontawesome_5 %}
{% block title %}{% trans "AKs" %}: {{ event.name }} - {% trans "Add message to organizers" %}{% endblock %} {% block title %}{% trans "AKs" %}: {{ event.name }} -
{% trans "Add confidential message to organizers" %}{% endblock %}
{% block breadcrumbs %} {% block breadcrumbs %}
{% include "AKSubmission/submission_breadcrumbs.html" %} {% include "AKSubmission/submission_breadcrumbs.html" %}
...@@ -12,13 +13,13 @@ ...@@ -12,13 +13,13 @@
href="{% url 'submit:submission_overview' event_slug=event.slug %}">{% trans "AK Submission" %}</a></li> href="{% url 'submit:submission_overview' event_slug=event.slug %}">{% trans "AK Submission" %}</a></li>
<li class="breadcrumb-item"><a <li class="breadcrumb-item"><a
href="{% url 'submit:ak_detail' event_slug=event.slug pk=ak.pk %}">{{ ak.short_name }}</a></li> href="{% url 'submit:ak_detail' event_slug=event.slug pk=ak.pk %}">{{ ak.short_name }}</a></li>
<li class="breadcrumb-item active">{% trans "Add message to organizers" %}</li> <li class="breadcrumb-item active">{% trans "Add confidential message to organizers" %}</li>
{% endblock %} {% endblock %}
{% block content %} {% block content %}
{% block headline %} {% block headline %}
<h2>{{ ak }}</h2> <h2>{{ ak }}</h2>
<h3>{% trans 'Add message to organizers' %}</h3> <h3>{% trans 'Add confidential message to organizers' %}</h3>
{% endblock %} {% endblock %}
<form method="POST" class="post-form">{% csrf_token %} <form method="POST" class="post-form">{% csrf_token %}
{% bootstrap_form form %} {% bootstrap_form form %}
......
from datetime import timedelta
from math import floor
from django.apps import apps
from django.conf import settings from django.conf import settings
from django.contrib import messages from django.contrib import messages
from django.http import HttpResponseRedirect from django.http import HttpResponseRedirect
from django.shortcuts import get_object_or_404, redirect from django.shortcuts import get_object_or_404, redirect
from django.urls import reverse_lazy from django.urls import reverse_lazy
from django.utils.datetime_safe import datetime
from django.utils.translation import gettext_lazy as _ from django.utils.translation import gettext_lazy as _
from django.views import View from django.views import View
from django.views.generic import ListView, DetailView, CreateView, UpdateView, DeleteView, RedirectView, TemplateView from django.views.generic import ListView, DetailView, CreateView, UpdateView, DeleteView, RedirectView, TemplateView
...@@ -130,6 +135,28 @@ class AKDetailView(EventSlugMixin, DetailView): ...@@ -130,6 +135,28 @@ class AKDetailView(EventSlugMixin, DetailView):
def get_context_data(self, *, object_list=None, **kwargs): def get_context_data(self, *, object_list=None, **kwargs):
context = super().get_context_data(object_list=object_list, **kwargs) context = super().get_context_data(object_list=object_list, **kwargs)
context["availabilities"] = Availability.objects.filter(ak=context["ak"]) context["availabilities"] = Availability.objects.filter(ak=context["ak"])
# Is this AK taking place now or soon (used for top page visualization)
context["featured_slot_type"] = "NONE"
if apps.is_installed("AKPlan"):
current_timestamp = datetime.now().astimezone(self.event.timezone)
in_two_hours = current_timestamp + timedelta(hours=2)
slots = context["ak"].akslot_set.filter(start__isnull=False, room__isnull=False)
for slot in slots:
if slot.end > current_timestamp:
if slot.start <= current_timestamp:
context["featured_slot_type"] = "CURRENT"
remaining = slot.end - current_timestamp
elif slot.start <= in_two_hours:
context["featured_slot_type"] = "UPCOMING"
remaining = slot.start - current_timestamp
else:
continue
context["featured_slot"] = slot
context["featured_slot_remaining"] = floor(remaining.days * 24 * 60 + remaining.seconds / 60)
break
return context return context
......
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2020-05-20 21:15+0000\n" "POT-Creation-Date: 2020-11-03 17:40+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment