]> git.parisson.com Git - mezzo.git/commitdiff
add HOME_FEATURED_ID
authorGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Fri, 22 Apr 2016 08:25:21 +0000 (10:25 +0200)
committerGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Fri, 22 Apr 2016 08:25:21 +0000 (10:25 +0200)
app/festival/static/scss/modules/event-card.scss
app/festival/templatetags/festival_tags.py
app/local_settings.py

index 3a494c738f32ae330d4707b8450a76f6b0de8316..bef8e302e4cf6564f30ee10b0f60f68cb0b59538 100644 (file)
       }
   }
 
-&--full {
-  @extend .event__card;
-
-  @media (min-width : $desktop ) {
-    width: 100%;
-    display: block;
-  }
-}
+    &--full {
+      @extend .event__card;
 
+      @media (min-width : $desktop ) {
+        width: 100%;
+        display: block;
+      }
+    }
 
-&__description {
-  display: block;
-  font-size: 0.75rem;
-}
+    &__description {
+      display: block;
+      font-size: 0.75rem;
+    }
 
 }
 
index a3aca2ddfdf19c10011c45301a4871a97d570be9..8b2d94ecdd9ceda616ec98c3d9c23dc3dd7201d3 100644 (file)
@@ -27,4 +27,4 @@ def featured_events(*args):
 
 @register.as_tag
 def featured(*args):
-    return Featured.objects.all().order_by('?').first()
+    return Featured.objects.get(id=settings.HOME_FEATURED_ID)
index 31e9a42851fcad551ed2e97a9ba8d25de60181cd..a9b40403cca51c72ce7adf666e05d67fb2fff6f2 100644 (file)
@@ -107,3 +107,5 @@ EVENT_PASS_URL = 'http://eve.ircam.fr/manifeste.php/pass/'
 TINYMCE_SETUP_JS = "/static/js/tinymce_setup.js"
 
 SLUGIFY = 'django.template.defaultfilters.slugify'
+
+HOME_FEATURED_ID = 1