commit
6bfd758391
6 changed files with 173 additions and 22 deletions
@ -1,30 +1,57 @@ |
||||
# -*- coding: utf-8 -*- |
||||
from django.conf.urls import include, patterns, url |
||||
from django.conf.urls import patterns, url |
||||
|
||||
from .views import ( |
||||
PlaceCityCatalog, |
||||
PlaceCountryCatalog, |
||||
PlaceDetail, |
||||
PlaceList, |
||||
PlacePhoto, |
||||
PlaceByCountry, |
||||
PlaceByCity, |
||||
PlaceCityCatalog, PlaceCountryCatalog, PlaceDetail, PlaceList, PlacePhoto, |
||||
PlaceByCountry, PlaceByCity, PlaceExpositionListView |
||||
) |
||||
|
||||
urlpatterns = patterns('', |
||||
|
||||
urlpatterns = patterns( |
||||
'', |
||||
url(r'^country/$', PlaceByCountry.as_view(), {'meta_id': 49}), |
||||
url(r'^country/(?P<slug>.*)/page/(?P<page>\d+)/$', PlaceCountryCatalog.as_view(), {'meta_id': 49}), |
||||
url(r'^country/(?P<slug>.*)/$', PlaceCountryCatalog.as_view(), {'meta_id': 49}, name='place_country'), |
||||
url( |
||||
r'^country/(?P<slug>.*)/page/(?P<page>\d+)/$', |
||||
PlaceCountryCatalog.as_view(), |
||||
{'meta_id': 49} |
||||
), |
||||
url( |
||||
r'^country/(?P<slug>.*)/$', |
||||
PlaceCountryCatalog.as_view(), |
||||
{'meta_id': 49}, |
||||
name='place_country' |
||||
), |
||||
|
||||
url(r'^city/$', PlaceByCity.as_view(), {'meta_id': 48}), |
||||
url(r'^city/(?P<slug>.*)/page/(?P<page>\d+)/$', PlaceCityCatalog.as_view(), {'meta_id': 48}), |
||||
url(r'^city/(?P<slug>.*)/$', PlaceCityCatalog.as_view(), {'meta_id': 48}, name='place_city'), |
||||
url( |
||||
r'^city/(?P<slug>.*)/page/(?P<page>\d+)/$', |
||||
PlaceCityCatalog.as_view(), |
||||
{'meta_id': 48} |
||||
), |
||||
url( |
||||
r'^city/(?P<slug>.*)/$', |
||||
PlaceCityCatalog.as_view(), |
||||
{'meta_id': 48}, |
||||
name='place_city' |
||||
), |
||||
|
||||
url(r'^(?P<slug>.*)/photo/page/(?P<page>\d+)/$', PlacePhoto.as_view(), {'meta_id': 91}), |
||||
url( |
||||
r'^(?P<slug>.*)/photo/page/(?P<page>\d+)/$', |
||||
PlacePhoto.as_view(), |
||||
{'meta_id': 91} |
||||
), |
||||
url(r'^(?P<slug>.*)/photo/$', PlacePhoto.as_view(), {'meta_id': 91}), |
||||
|
||||
url(r'^page/(?P<page>\d+)/$', PlaceList.as_view(), {'meta_id': 46}), |
||||
url(r'^(?P<slug>.*)/$', PlaceDetail.as_view(), {'meta_id': 47}), |
||||
url(r'^$', PlaceList.as_view(), {'meta_id':46}), |
||||
) |
||||
url( |
||||
r'^(?P<slug>.*)/expositions/$', |
||||
PlaceExpositionListView.as_view(), |
||||
name='place_exposition_list' |
||||
), |
||||
url( |
||||
r'^(?P<slug>.*)/$', |
||||
PlaceDetail.as_view(), |
||||
{'meta_id': 47}, |
||||
name='place_detail' |
||||
), |
||||
url(r'^$', PlaceList.as_view(), {'meta_id': 46}), |
||||
) |
||||
|
||||
@ -0,0 +1,100 @@ |
||||
{% extends 'client/base_catalog.html' %} |
||||
{% load i18n %} |
||||
|
||||
{% block bread_scrumbs %} |
||||
<div class="bread-crumbs"> |
||||
<a href="{% url 'index' %}">{% trans 'Главная страница' %}</a> |
||||
<a href="{{ object.catalog }}">{% trans 'Места' %}</a> |
||||
<a href="{{ object.catalog }}country/{{ object.country.url }}/">{{ object.country }}</a> |
||||
<a href="{{ object.catalog }}city/{{ object.city.url }}/">{{ object.city }}</a> |
||||
<a href="{{ object.get_absolute_url }}">{{ object.name }}</a> |
||||
<strong>{% trans 'Все события' %}</strong> |
||||
</div> |
||||
{% endblock %} |
||||
|
||||
{% block content_list %} |
||||
<div class="page-title"> |
||||
<h1>{% trans 'Все события' %} {{ object.name }}</h1> |
||||
</div> |
||||
|
||||
<div class="i-events-list expo-place-events"> |
||||
<ul class="cat-list cl-exhibitions"> |
||||
{% for event in object_list %} |
||||
<li class="cl-item" data-link="#"> |
||||
<div class="cl-item-wrap clearfix"> |
||||
<a href="{{ event.get_permanent_url }}"> |
||||
{% if event.expohit %} |
||||
<span class="hit"></span> |
||||
{% endif %} |
||||
|
||||
<div class="cli-pict"> |
||||
{% with obj=event %} |
||||
{% include 'client/includes/show_logo.html' %} |
||||
{% endwith %} |
||||
</div> |
||||
</a> |
||||
|
||||
<div class="cli-info"> |
||||
<div class="cli-top clearfix"> |
||||
<header> |
||||
<div class="cli-title"><a href="{{ event.get_permanent_url }}">{{ event.name|safe }}</a></div> |
||||
</header> |
||||
|
||||
<div class="cli-descr"> |
||||
{{ event.main_title|safe }} |
||||
</div> |
||||
</div> |
||||
|
||||
<div class="cli-bot clearfix"> |
||||
<div class="cli-date"> |
||||
{% with obj=event %} |
||||
{% include 'client/includes/show_date_block.html' %} |
||||
{% endwith %} |
||||
</div> |
||||
|
||||
<div class="cli-place"> |
||||
<a href="{{ event.catalog }}country/{{ event.country.url }}/">{{ event.country }}</a>, <a href="{{ event.catalog }}city/{{ event.city.url }}/">{{ event.city }}</a> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
||||
<div class="cli-buttons clearfix"> |
||||
<div class="cli-m-buttons"> |
||||
<div class="cli-services"> |
||||
<a class="button icon-sm" href="#">{% trans 'услуги' %}</a> |
||||
|
||||
<div class="cli-services-sm"> |
||||
<ul> |
||||
{% for service in event.get_services %} |
||||
<li><a href="{{ service.get_permanent_url }}">{{ service.name }}</a></li> |
||||
{% endfor %} |
||||
</ul> |
||||
</div> |
||||
</div> |
||||
|
||||
<a class="button blue icon-calendar" href="{{ event.get_calendar_url }}">{% trans 'в расписание' %}</a> |
||||
<a class="button green icon-note" href="#">{% trans 'заметка' %}</a> |
||||
</div> |
||||
|
||||
<div class="cli-s-buttons"> |
||||
<a class="button blue2 lc" target="_blank" href="http://www.booking.com/searchresults.html?aid={{ book_aid }}&city={{ event.city.id }}">{% trans 'Лучшие цены на отели на' %} <i>Booking</i>.com</a> |
||||
</div> |
||||
|
||||
</div> |
||||
</div> |
||||
|
||||
<footer class="clearfix"> |
||||
<div class="cli-stats"> |
||||
{% if event.visitors %}<span class="visitors"> {{ event.visitors }}</span>{% endif %} |
||||
{% if event.members %}<span class="participants">{{ event.members }}</span>{% endif %} |
||||
</div> |
||||
|
||||
<div class="cli-tags"> |
||||
{% include 'client/includes/exposition/tags.html' with obj=event %} |
||||
</div> |
||||
</footer> |
||||
</li> |
||||
{% endfor %} |
||||
</ul> |
||||
</div> |
||||
{% endblock %} |
||||
Loading…
Reference in new issue