]> littlesong.place Git - littlesongplace.git/commitdiff
Hide event title, description, entries until event starts
authorChris Fulljames <christianfulljames@gmail.com>
Sat, 19 Apr 2025 09:56:02 +0000 (05:56 -0400)
committerChris Fulljames <christianfulljames@gmail.com>
Sat, 19 Apr 2025 09:56:02 +0000 (05:56 -0400)
src/littlesongplace/templates/jam-event.html

index b1b19fceb0dc85330807f39864d5357154cae461..cd3da92a29cce5a899117ee68a72cf8fe79668ec 100644 (file)
@@ -4,7 +4,7 @@
 
 {% block body %}
 
-<h1>{{ event.title }} - {{ jam.title }}</h1>
+<h1>{% if event.hidden -%}[Upcoming Event]{%- else -%}{{ event.title }}{%- endif %} - {{ jam.title }}</h1>
 
 <div id="jam-event-view">
     <div>
     {%- endif %}
 
     <div class="jam-description">
-    {{ event.description }}
+        {% if event.hidden -%}
+        <em>Event description is hidden until the event starts.</em>
+        {%- else -%}
+        {{ event.description }}
+        {%- endif %}
     </div>
 
     <h2>About the Jam</h2>
     {{ jam.description }}
     </div>
 
+    {% if not event.hidden -%}
     <h2>Entries</h2>
     <a class="button" href="/edit-song?eventid={{ event.eventid }}">Submit a Song</a>
     <br/>
     <br/>
     {% if songs %}<p><small>This event has received {{ songs|length }} {% if songs|length > 1 %}entries{% else %}entry{% endif %}</small></p>{% endif %}
     {% include "song-list.html" %}
+    {%- endif %}
 
     <h2>Comments</h2>
     {% from "comment-thread.html" import comment_thread %}