<h2>Nonstop - Artist: {{ object.name }}</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<h3>{% trans "Most recently played" %}</h3>
<h2>Nonstop - Artists</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<ul class="artists-list">
<h2>Nonstop{% if zone %} — {{zone.title}} — {{count}} tracks{% endif %}</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<form id="track-search">
{{ form.as_p }}
<h2>Nonstop</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<ul>
<li><a href="{% url 'nonstop-today' %}">Aujourd'hui</a> (avec des liens pour naviguer vers les autres jours)</li>
<li><a href="{% url 'artist-list' %}">Artistes</a> présents (un jour ou l'autre) dans le nonstop</li>
<li><a href="{% url 'nonstop-search' %}">Recherche</a> dans les pistes et artistes</li>
+{% if perms.nonstop.add_track %}
<li><a href="{% url 'nonstop-upload-tracks' %}">Ajout de nouveaux morceaux</a></li>
<li><a href="{% url 'nonstop-recent-tracks' %}">Édition rapide de métadonnées de nouveaux morceaux</a> (langue, Instru, SABAM, CFWB)</li>
<li><a href="{% url 'nonstop-cleanup' %}">Nettoyage de vieux morceaux</a></li>
+{% endif %}
</ul>
{% endblock %}
<h2>Nonstop - {% trans "Recent Tracks" %}</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<form method="post">
{% csrf_token %}
<h2>Nonstop</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<form id="track-search">
{{ form.as_p }}
{% endblock %}
{% block more-user-links %}
-<a href="{% url 'nonstop-today' %}">Aujourd'hui</a>
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
{% endblock %}
{% block content %}
<a href="?from=-30d">during last month</a>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<div class="nonstop-stats">
<h2>Nonstop - Track: {{ object.artist.name }} / {{ object.title }}</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
{% if not object.file_exists %}
<p>In nonstop since {{ object.added_to_nonstop_timestamp|date:"SHORT_DATE_FORMAT" }}.</p>
+{% if perms.nonstop.add_track %}
<form method="POST">
{% csrf_token %}
{{ metadata_form.as_p }}
</div>
{% endif %}
+{% endif %}
+
<style>
ul.soma-list {
float: left;
<h2>Nonstop - {% trans "Upload" %}</h2>
{% endblock %}
+{% block more-user-links %}
+{{ block.super }}
+<a href="{% url 'nonstop-quick-links' %}">Gestion nonstop</a>
+{% endblock %}
+
{% block content %}
<form method="post" enctype="multipart/form-data">
{{ form.as_p }}
<div class="buttons">
<button class="submit-button">{% trans "Upload" %}</button>
- <a class="cancel" href="...">{% trans "Cancel" %}</a>
+ <a class="cancel" href="{% url 'nonstop-quick-links' %}">{% trans "Cancel" %}</a>
</div>
</form>
return ctx
def post(self, request, *args, **kwargs):
+ assert self.request.user.has_perm('nonstop.add_tracks')
instance = self.get_object()
old_nonstop_zones = copy.copy(instance.nonstop_zones.all())
form = TrackMetaForm(request.POST, instance=instance)
success_url = '.'
def post(self, request, *args, **kwargs):
+ assert self.request.user.has_perm('nonstop.add_tracks')
form_class = self.get_form_class()
form = self.get_form(form_class)
tracks = request.FILES.getlist('tracks')
return Track.objects.exclude(creation_timestamp__isnull=True).order_by('-creation_timestamp')[:50]
def post(self, request, *args, **kwargs):
+ assert self.request.user.has_perm('nonstop.add_tracks')
for track_id in request.POST.getlist('track'):
track = Track.objects.get(id=track_id)
track.language = request.POST.get('lang-%s' % track_id, '')
return ctx
def post(self, request, *args, **kwargs):
+ assert self.request.user.has_perm('nonstop.add_tracks')
count = 0
for track_id in request.POST.getlist('track'):
if request.POST.get('remove-%s' % track_id):