]> git.parisson.com Git - mezzo.git/commitdiff
Add tournees banner and menu link
authorJérémy Fabre <Jeremy@iMac-de-Jeremy.local>
Mon, 17 Oct 2016 15:15:07 +0000 (17:15 +0200)
committerJérémy Fabre <Jeremy@iMac-de-Jeremy.local>
Mon, 17 Oct 2016 15:15:07 +0000 (17:15 +0200)
app/static/src/sass/modules/_banner.scss
app/static/src/sass/modules/navs/_nav-tree.scss
app/templates/agenda/event_list.html
app/templates/agenda/includes/event_linecard.html
app/templates/home/inc/services.html

index e3114c95398e8c7e8452683367611e9991c81f28..39cc834a3579eecc923ea30a6d8a0d5e48ac0679 100644 (file)
@@ -99,6 +99,25 @@ $module: ".banner";
 
     }
 
+    &--small {
+
+        height: 150px;
+        margin-top: 0;
+
+        @include mq($until: lg) {
+
+            height: 150px;
+
+        }
+
+        #{$module}__content {
+
+            padding-top: 40px;
+
+        }
+
+    }
+
     &__content {
 
         position: absolute;
index adcbec9616d866ec44dcd09ab8575d455af8df96..876790bc1b225d055017003394e4deaa2813d6cd 100644 (file)
@@ -10,6 +10,12 @@ $module: ".nav-tree";
     position: absolute;
     width: 100%;
 
+    @include mq($until: sm) {
+
+        position: static;
+
+    }
+
     .nav-tree & {
         position: relative;
     }
index 663d61a8b09e3f5309864d896181bbe32c2331c0..a8162bca924d628c92de0365be1e93eb4f31f7f1 100644 (file)
@@ -1,5 +1,5 @@
 {% extends "pages/page.html" %}
-{% load i18n future mezzanine_tags event_tags keyword_tags disqus_tags organization_tags %}
+{% load i18n future mezzanine_tags event_tags keyword_tags disqus_tags organization_tags staticfiles %}
 
 {% block meta_title %}
     {% if page %}
 
 {% block breadcrumb_menu %}
     {{ block.super }}
-    {% if tag or location or month or week or author %}
+    {% if tag and tag|tag_is_excluded %}
+    <li class="breadcrumb__item">
+        <a href="{% url 'event_list' %}" class="breadcrumb__link">{% trans "Tournées" %}</a>
+    </li>
+    {% elif tag or location or month or week or author %}
         <li class="breadcrumb__item">
-            <a href="{% url 'event_list' %}" class="breadcrumb__link">{% trans "Agenda" %}</a>
+            <a href="{% url 'event_list' %}" class="breadcrumb__link">{% trans "Rendez-vous" %}</a>
         </li>
         <li class="breadcrumb__item active">
             {% if tag %}
@@ -49,7 +53,7 @@
         </li>
     {% else %}
         <li class="breadcrumb__item active">
-            {% trans "Agenda" %}
+            {% trans "Rendez-vous" %}
         </li>
     {% endif %}
 {% endblock %}
                         {% if page %}
                             {{ page.richtextpage.meta_title }}
                         {% else %}
-                            {% trans "Agenda" %}
+                            {% if tag and tag|tag_is_excluded %}
+                                {% trans "Tournées" %}
+                            {% else %}
+                                {% trans "Rendez-vous" %}
+                            {% endif %}
                         {% endif %}
                     </h1>
 
 
                     <ul class="nav-tree nav-tree--level-{{ branch_level }}" data-sticky data-sticky-parent="row" data-sticky-offset="100" data-sticky-detach-at="971">
                         <li class="nav-tree__item">
-                            <a class="nav-tree__link active" href="{{ page.get_absolute_url }}">{% trans 'Agenda' %}</a>
+                            <a class="nav-tree__link active" href="{{ page.get_absolute_url }}">
+                                {% if tag and tag|tag_is_excluded %}
+                                    {% trans "Tournées" %}
+                                {% else %}
+                                    {% trans "Rendez-vous" %}
+                                {% endif %}
+                            </a>
 
                             <ul class="nav-tree" data-summary>
                                 <li class="nav-tree__item nav-tree__item--sub hide">
                             </ul>
                         </li>
 
+                        {% if tag and tag|tag_is_excluded %}
+                            <li class="nav-tree__item">
+                                <a class="nav-tree__link" href="{% url 'event_list' %}">
+                                    {% trans "Rendez-vous" %}
+                                </a>
+                            </li>
+                        {% else %}
+                            <li class="nav-tree__item">
+                                <a class="nav-tree__link" href="{% url 'event_list_tag' 'tournees' %}">
+                                    {% trans "Tournées" %}
+                                </a>
+                            </li>
+                        {% endif %}
+
                         <li class="nav-tree__separator">
 
                         </li>
 
-                        {% keywords_for mezzanine_agenda.event as tags %}
-                        {# {% all_events as all_events %}#}
-                        {% if tags %}
-                            {% comment %}
-                                <a href="{% url 'event_list' %}" class="button{% if not tag %} button--black{% else %} button--white{% endif %}">{% trans "All events" %}</a>
-                            {% endcomment %}
-                            {% for t in tags %}
-                                {% if not t|tag_is_excluded %}
-                                    <li class="nav-tree__item">
-                                        <a class="nav-tree__link--filter nav-tree__link{% if tag == t %} active{% endif %}" href="{% if tag == t %}{% url 'event_list' %}{% else %}{% url "event_list_tag" t.slug %}{% endif %}">
-                                            {{ t }} {% if tag == t %}<i class="fa fa-times"></i>{% endif %}
-                                        </a>
-                                    </li>
-                                {% endif %}
-                            {% endfor %}
+                        {% if tag and not tag|tag_is_excluded or not tag %}
+
+                            {% keywords_for mezzanine_agenda.event as tags %}
+                            {# {% all_events as all_events %}#}
+                            {% if tags %}
+                                {% comment %}
+                                    <a href="{% url 'event_list' %}" class="button{% if not tag %} button--black{% else %} button--white{% endif %}">{% trans "All events" %}</a>
+                                {% endcomment %}
+                                {% for t in tags %}
+                                    {% if not t|tag_is_excluded %}
+                                        <li class="nav-tree__item">
+                                            <a class="nav-tree__link--filter nav-tree__link{% if tag == t %} active{% endif %}" href="{% if tag == t %}{% url 'event_list' %}{% else %}{% url "event_list_tag" t.slug %}{% endif %}">
+                                                {{ t }} {% if tag == t %}<i class="fa fa-times"></i>{% endif %}
+                                            </a>
+                                        </li>
+                                    {% endif %}
+                                {% endfor %}
+                            {% endif %}
+
                         {% endif %}
                     </ul>
 
                 </div>
 
-                <div class="mb2 col-sm-9 col-lg-8 white-bg page__content" data-summary-content>
+                <div class="mb2 col-sm-9 col-lg-10 white-bg page__content" data-summary-content>
 
                     <div class="white-bg page__content">
                         <div class="container">
+
+                            {% if tag and not tag|tag_is_excluded or not tag %}
+                                <div class="row">
+                                    <div class="col-lg-12">
+                                        <a class="banner banner--light banner--small" href="{% url 'event_list_tag' 'tournees' %}" style="background-image:url({% static 'img/services/tours.jpg' %});">
+
+                                            <div class="banner__content">
+
+                                                <div class="banner__title fsxxxl">
+                                                    Tournées 16.17
+                                                </div>
+                                                <div class="banner__desc fss">
+                                                    Campo Santo, Songes et Métamorphoses, Providences, UM souverain moteur de toutes choses...
+                                                </div>
+
+                                            </div>
+
+                                        </a>
+                                    </div>
+                                </div>
+                            {% endif %}
+
+
                             {% for event in events.object_list %}
                                 {% include 'agenda/includes/event_linecard.html' %}
                             {% endfor %}
index 7884195a1409a3d39c1cd3f2e8f187f31ee5909e..23796806ac1caee8d5345fd3d8abdaf5dd72a5c5 100644 (file)
                 {% with event.images.all|get_type:'card' as images %}
                     {% if images %}
                         <a href="{{ event.get_absolute_url }}">
-                            <img class="event-line-box__image" src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==" data-original="{{ MEDIA_URL }}{% thumbnail images.0.file 203 140 %}" width="203" height="140" class="lazyload">
+                            <img class="event-line-box__image lazyload" src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==" data-original="{{ MEDIA_URL }}{% thumbnail images.0.file 203 140 %}" width="203" height="140">
                         </a>
                     {% else %}
                         {% with event.parent.images.all|get_type:'card' as images %}
                             {% if images %}
                                 <a href="{{ event.get_absolute_url }}">
-                                    <img class="event-line-box__image" src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==" data-original="{{ MEDIA_URL }}{% thumbnail images.0.file 203 140 %}" width="203" height="140" class="lazyload">
+                                    <img class="event-line-box__image lazyload" src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==" data-original="{{ MEDIA_URL }}{% thumbnail images.0.file 203 140 %}" width="203" height="140">
                                 </a>
                             {% endif %}
                         {% endwith %}
index 377c9bd69c03e5486656eff46a26dd0d006ac335..558e57e4ce4ad07a21eac0bafcb4174ce5b68770 100644 (file)
@@ -6,7 +6,7 @@
 
         <div class="col-sm-6">
 
-            <a class="banner banner--light" href="#" style="background-image:url({% static 'img/services/tours.jpg' %});">
+            <a class="banner banner--light" href="{% url 'event_list_tag' 'tournees' %}" style="background-image:url({% static 'img/services/tours.jpg' %});">
 
                 <div class="banner__content">