CONT: continue the previous change.
This commit is contained in:
@@ -1,14 +1,10 @@
|
||||
{% load i18n %}
|
||||
{% load dav_events %}
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<div class="pull-right">
|
||||
{% for flag in event.get_status_flags %}
|
||||
{{ flag.status.get_bootstrap_label|safe }}
|
||||
{% if planned_publication_date and flag.status.code|slice:":10" == 'publishing' %}
|
||||
<span class="label label-{{ flag.status.bootstrap_context|default:'default' }}">{{ planned_publication_date|date:'d.m.Y' }}</span>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% render_event_status event show_void='False' %}
|
||||
</div>
|
||||
<span class="panel-title">{{ number }} - {{ title }}</span>
|
||||
</div>
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">{% trans 'Wird/Wurde diese Veranstaltung veröffentlicht?' %}</h4>
|
||||
<h4 class="modal-title">{% trans 'Wo wird/wurde diese Veranstaltung veröffentlicht?' %}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p class="text-center">
|
||||
@@ -84,13 +84,21 @@
|
||||
</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-info" href="{% if event.planned_publication_date %}{% url 'dav_events:confirmstatus' event.pk 'publishing_facebook' %}{% else %}{% url 'dav_events:confirmstatus' event.pk 'published' %}{% endif %}">
|
||||
{% bootstrap_icon 'ok' %} 
|
||||
{% trans 'Facebook' %}
|
||||
</a>
|
||||
<a class="btn btn-primary" href="{% if event.planned_publication_date %}{% url 'dav_events:confirmstatus' event.pk 'publishing_web' %}{% else %}{% url 'dav_events:confirmstatus' event.pk 'published' %}{% endif %}">
|
||||
{% bootstrap_icon 'ok' %} 
|
||||
{% trans 'Webseite' %}
|
||||
</a>
|
||||
<a class="btn btn-success" href="{% if event.planned_publication_date %}{% url 'dav_events:confirmstatus' event.pk 'publishing' %}{% else %}{% url 'dav_events:confirmstatus' event.pk 'published' %}{% endif %}">
|
||||
{% bootstrap_icon 'ok' %} 
|
||||
{% trans 'Ja' %}
|
||||
{% trans 'Überall' %}
|
||||
</a>
|
||||
<button type="button" class="btn btn-danger" data-dismiss="modal">
|
||||
{% bootstrap_icon 'remove' %} 
|
||||
{% trans 'Nein' %}
|
||||
{% trans 'Nirgends' %}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -102,9 +110,9 @@
|
||||
<div class="action-tabs">
|
||||
<div class="pull-right">
|
||||
{% if has_permission_submit %}
|
||||
<a class="btn {% if 'submitted' in event.get_status_codes %}btn-default disabled{% else %}btn-success{% endif %}"
|
||||
<a class="btn {% if not is_submitted %}btn-success{% else %}btn-default disabled{% endif %}"
|
||||
data-toggle="modal" data-target="#modal-submit-dialog">
|
||||
{% if 'submitted' in event.get_status_codes %}
|
||||
{% if is_submitted %}
|
||||
{% bootstrap_icon 'check' %} 
|
||||
{% else %}
|
||||
{% bootstrap_icon 'unchecked' %} 
|
||||
@@ -113,9 +121,9 @@
|
||||
</a>
|
||||
{% endif %}
|
||||
{% if has_permission_accept %}
|
||||
<a class="btn {% if 'accepted' in event.get_status_codes %}btn-default disabled{% else %}btn-success{% endif %}"
|
||||
<a class="btn {% if is_submitted and not is_accepted %}btn-success{% else %}btn-default disabled{% endif %}"
|
||||
data-toggle="modal" data-target="#modal-accept-dialog">
|
||||
{% if 'accepted' in event.get_status_codes %}
|
||||
{% if is_accepted %}
|
||||
{% bootstrap_icon 'check' %} 
|
||||
{% else %}
|
||||
{% bootstrap_icon 'unchecked' %} 
|
||||
@@ -124,9 +132,9 @@
|
||||
</a>
|
||||
{% endif %}
|
||||
{% if has_permission_publish %}
|
||||
<a class="btn {% if event.get_status.code == 'accepted' %}btn-success{% else %}btn-default disabled{% endif %}"
|
||||
<a class="btn {% if is_accepted and not is_publishing %}btn-success{% else %}btn-default disabled{% endif %}"
|
||||
data-toggle="modal" data-target="#modal-confirmpublication-dialog">
|
||||
{% if 'publishing' in event.get_status_codes or 'published' in event.get_status_codes %}
|
||||
{% if is_publishing %}
|
||||
{% bootstrap_icon 'check' %} 
|
||||
{% else %}
|
||||
{% bootstrap_icon 'unchecked' %} 
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
{% extends 'dav_events/base.html' %}
|
||||
{% load bootstrap3 %}
|
||||
{% load i18n %}
|
||||
{% load dav_events %}
|
||||
|
||||
{% block page-container-fluid %}
|
||||
<div class="action-tabs">
|
||||
@@ -43,11 +44,13 @@
|
||||
<tbody>
|
||||
{% for event in event_list %}
|
||||
<tr>
|
||||
<td data-order="{{ event.get_number|slice:':1' }}{{ event.get_number|slice:'-2:' }}{{ event.get_number|slice:'1:-2'|cut:'/' }}"
|
||||
data-search="{{ event.get_number }} ({{ event.get_sport_display }})">
|
||||
<a href="{% url 'dav_events:detail' event.pk %}">{{ event.get_number }}</a><br />
|
||||
{% with number=event.get_number %}
|
||||
<td data-order="{{ number|slice:':1' }}{{ number|slice:'-2:' }}{{ number|slice:'1:-2'|cut:'/' }}"
|
||||
data-search="{{ number }} ({{ event.get_sport_display }})">
|
||||
<a href="{% url 'dav_events:detail' event.pk %}">{{ number }}</a><br />
|
||||
<small>({{ event.get_sport_display }})</small>
|
||||
</td>
|
||||
{% endwith %}
|
||||
<td>
|
||||
<a href="{% url 'dav_events:detail' event.pk %}">{{ event.title }}</a>
|
||||
</td>
|
||||
@@ -65,14 +68,7 @@
|
||||
{{ event.get_numeric_date }}
|
||||
</td>
|
||||
<td>
|
||||
{% for flag in event.get_status_flags %}
|
||||
{{ flag.status.get_bootstrap_label|safe }}
|
||||
{% if event.planned_publication_date and flag.status.code|slice:':10' == 'publishing' %}
|
||||
<span class="label label-{{ flag.status.bootstrap_context|default:'default' }}">{{ event.planned_publication_date|date:'d.m.Y' }}</span>
|
||||
{% endif %}
|
||||
{% empty %}
|
||||
{{ event.get_status.get_bootstrap_label|safe }}
|
||||
{% endfor %}
|
||||
{% render_event_status event %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
|
||||
@@ -21,18 +21,18 @@
|
||||
<form action="" method="post">
|
||||
{% csrf_token %}
|
||||
|
||||
{% if 'expired' in event.get_status_codes %}
|
||||
{% if is_expired %}
|
||||
<div class="alert alert-info alert-dismissible" role="alert">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
{% trans 'Diese Veranstaltung ist bereits ausgelaufen.' %}
|
||||
</div>
|
||||
{% elif 'publishing' in event.get_status_codes or 'published' in event.get_status_codes %}
|
||||
{% elif is_publishing %}
|
||||
<div class="alert alert-danger alert-dismissible" role="alert">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<strong>{% trans 'Achtung!' %}</strong> {% trans 'Diese Veranstaltung wird/wurde bereits veröffentlicht.' %}
|
||||
{% trans 'Änderungen müssen mit allen Beteiligten abgesprochen werden.' %}
|
||||
</div>
|
||||
{% elif 'accepted' in event.get_status_codes %}
|
||||
{% elif is_accepted %}
|
||||
<div class="alert alert-danger alert-dismissible" role="alert">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<strong>{% trans 'Achtung!' %}</strong> {% trans 'Diese Veranstaltung wurde bereits freigegeben.' %}
|
||||
|
||||
Reference in New Issue
Block a user