diff options
author | Étienne Loks <etienne.loks@proxience.com> | 2015-04-16 19:51:15 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@proxience.com> | 2015-04-16 19:51:15 +0200 |
commit | d6eeb788899c3009f99554866b8c2f5a8bf776c2 (patch) | |
tree | e75526b5e43b78238bbe138d2962118a7f0c8542 | |
parent | d50b7a01af069c8996573f437610e041921a9462 (diff) | |
parent | 5b218a7a4a742b2e2489bacbf653f1b7fd3a60c9 (diff) | |
download | Chimère - projet de référence-d6eeb788899c3009f99554866b8c2f5a8bf776c2.tar.bz2 Chimère - projet de référence-d6eeb788899c3009f99554866b8c2f5a8bf776c2.zip |
Merge branch 'v2.2' into carteouverte
Conflicts:
chimere_example_static/chimere/css/extra-styles.css
-rw-r--r-- | chimere_example_static/chimere/css/extra-styles.css | 18 | ||||
-rw-r--r-- | locale/fr/LC_MESSAGES/django.po | 2 | ||||
-rw-r--r-- | settings.py | 2 | ||||
-rw-r--r-- | templates/chimere/blocks/actions.html | 2 | ||||
-rw-r--r-- | templates/chimere/blocks/news.html | 62 | ||||
-rw-r--r-- | templates/chimere/main_map.html | 2 |
6 files changed, 83 insertions, 5 deletions
diff --git a/chimere_example_static/chimere/css/extra-styles.css b/chimere_example_static/chimere/css/extra-styles.css index cdf34d0..9d67c9c 100644 --- a/chimere_example_static/chimere/css/extra-styles.css +++ b/chimere_example_static/chimere/css/extra-styles.css @@ -52,7 +52,11 @@ a:hover, a:focus { opacity: 0.1; } -#welcome{ +#footer a, #footer a:link, #footer a:visited{ + color:#327E04; +} + +#welcome, #news{ background-color:transparent; } @@ -245,6 +249,16 @@ li.main_category > span.category_name:hover{ width:30px; } +#search-nav{ + position:absolute; + bottom:0; + width:100%; + background-color:#F8F8F8; + border-top:1px solid #E6E6E6; + padding: 0 10px; + left: 0; +} + #main-map { height: auto; bottom: 0px; @@ -275,7 +289,7 @@ li.main_category > span.category_name:hover{ top: 125px; } -a#welcome_button{ +a#news_button{ padding:0 10px; margin:0; } diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po index 110a0fa..22a5ad5 100644 --- a/locale/fr/LC_MESSAGES/django.po +++ b/locale/fr/LC_MESSAGES/django.po @@ -104,7 +104,7 @@ msgstr "En savoir plus..." #: templates/chimere/blocks/categories.html:28 msgid "Display markers and routes waiting for validation" -msgstr "Afficher les pointeurs et les tarjets en cours de validation" +msgstr "Afficher les pointeurs et les trajets en cours de validation" #: templates/chimere/blocks/map.html:15 msgid "Loading of the map in progress" diff --git a/settings.py b/settings.py index 47fab7b..072a322 100644 --- a/settings.py +++ b/settings.py @@ -136,6 +136,8 @@ HAYSTACK_CONNECTIONS = { 'INCLUDE_SPELLING': True, }, } +HAYSTACK_SEARCH_RESULTS_PER_PAGE = 12 +HAYSTACK_AUTOCOMPLETE = True CHIMERE_CSV_ENCODING = 'ISO-8859-1' diff --git a/templates/chimere/blocks/actions.html b/templates/chimere/blocks/actions.html index 44ae223..580b3ac 100644 --- a/templates/chimere/blocks/actions.html +++ b/templates/chimere/blocks/actions.html @@ -30,7 +30,7 @@ <li id='permalink-lnk'><span class='fa fa-chimere-action fa-bookmark'></span><span id='permalink'></span></li> <li>{% routing %}</li> <li id='news-lnk'> - <a data-toggle='modal' data-target="#welcome" href='#' id='welcome_button'><span class='fa fa-chimere-action fa-newspaper-o'></span><span class='lbl'>{% trans "News"%}</span></a> + <a data-toggle='modal' data-target="#news" href='#' id='news_button'><span class='fa fa-chimere-action fa-newspaper-o'></span><span class='lbl'>{% trans "News"%}</span></a> </li> {% endif %} <li class='selection-sep'> </li> diff --git a/templates/chimere/blocks/news.html b/templates/chimere/blocks/news.html new file mode 100644 index 0000000..68b0836 --- /dev/null +++ b/templates/chimere/blocks/news.html @@ -0,0 +1,62 @@ +{% load i18n sanitize chimere_tags %} +{% if news_lst %} +<script type='text/javascript'> +$(function(){ + $('#news div.media-player').jmeEmbedControls(); + $('#news video').each(function(index){$(this).pause()}); + $('#news audio').each(function(index){$(this).pause()}); + {% if display %}$('#news').modal('show');{%endif%} +}); +</script> + +<div class="modal fade" id="news" tabindex="-1" role="dialog" aria-labelledby="news-label" aria-hidden="true"> + <div class="modal-dialog modal-lg"> + <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" id="news-label">{% trans "Upcoming events" %}</h4> + </div> + <div class="modal-body"> + <div id='news_content'> + {% if welcome_message %} + <div id='welcome_message'> + {{welcome_message|safe}} + </div> + {% endif %} + <div class='news'> + {% if news_lst %} + {% for news in news_lst %} + <div class='info'> + {% if news.title %} + <h3>{{news.title}} – {{ news.date }}</h3> + <p>{{news.content|safe}}</p> + {% else %} + <h3>{{news.name}} – {{ news.start_date }}{% if news.end_date %} - {{ news.end_date }}{% endif %}</h3> + {% if news.default_pictures or news.default_pictures or news.default_multimedia_items%} + <div class='small-gallery'> + {% for picture in news.default_pictures %} + {% multimedia_render picture %} + {%endfor%} + {% for multimedia_item in news.default_multimedia_items %} + {% multimedia_render multimedia_item %} + {%endfor%} + </div> + {%endif%} + {% if news.description %} + <p class='description'>{{news.description|sanitize:"p b i br hr strong em span:style a:href:target ul li ol h1 h2 h3 h4 table td th tr"|safe}}</p> + {% endif %} + {% for property in news.getProperties %} + <p class='{{news.propertymodel.getNamedId}}'>{{ property.value|sanitize:"p b i br hr strong em span:style a:href:target ul li ol h1 h2 h3 h4 table td th tr"|safe }}</p> + {% endfor %} + <p class='marker_link'><a href='{% get_tinyfied_url news area_name %}'>{% trans "See it on the map"%}</a></p> + {% endif %} + </div> + {%endfor%} + {% endif %} + </div> + </div> + </div> + </div> + </div> +</div> +{% endif %} diff --git a/templates/chimere/main_map.html b/templates/chimere/main_map.html index f2e00b3..70d5cb4 100644 --- a/templates/chimere/main_map.html +++ b/templates/chimere/main_map.html @@ -12,7 +12,7 @@ {% endblock %} {% block message_edit %}{% endblock %} {% block sidebar %} -{% display_welcome %} +{% display_news %} <div class='show-hide-panel' id='hide-panel'><span class='fa fa-arrow-circle-left'></span></div> <div class='show-hide-panel' id='show-panel'><span class='fa fa-arrow-circle-right'></span></div> <div id='panel' class='navbar-default'> |