Advertisement
Guest User

Untitled

a guest
Jan 16th, 2018
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 5 8.68 KB | None | 0 0
  1. {% extends "shop/base.html" %}
  2. {% load gshop_extras %}
  3. {% load gshop %}
  4. {% load i18n %}
  5. {% load i18n_extra %}
  6.  
  7. {% block title %}
  8.     {% if view_type == "category" %}
  9.         {% if seo_page_text and seo_page_text_meta_title %}
  10.             {{ seo_page_text_meta_title }}
  11.         {% elif meta_title %}
  12.             {{ meta_title }}
  13.         {% else %}
  14.             {% get_field_translate object_item "meta_title" LANGUAGE_CODE %}
  15.         {% endif %}
  16.     {% elif seo_page_text %}
  17.         {% get_field_translate seo_page_text "meta_title" LANGUAGE_CODE %}
  18.     {% else %}
  19.         {% trans section|capfirst %}
  20.     {% endif %}
  21.  
  22.     {% if page_num %}
  23.         {% if page_num != 1 %} - {% if LANGUAGE_CODE == 'ru' %}страница{% else %}сторінка{% endif %} {{ page_num }}{% endif %}
  24.     {% endif %}
  25.  
  26. {% endblock %}
  27.  
  28. {% block meta %}
  29.     {% if view_type == "category" %}
  30.         {% if seo_page_text and seo_page_text_meta_keywords %}
  31.             {% if page_num != 1 %}
  32.             <meta name="keywords" content="{{ seo_page_text_meta_keywords }} {% trans 'страница' %} {{ page_num }}" />
  33.             {% else %}
  34.             <meta name="keywords" content="{{ seo_page_text_meta_keywords }}" />
  35.             {% endif %}
  36.         {% elif meta_keywords %}
  37.             {% if page_num != 1 %}
  38.             <meta name="keywords" content="{{ meta_keywords }} {% trans 'страница' %} {{ page_num }}" />
  39.             {% else %}
  40.             <meta name="keywords" content="{{ meta_keywords }}" />
  41.             {% endif %}
  42.         {% else %}
  43.             {% if page_num != 1 %}
  44.             <meta name="keywords" content="{% get_field_translate object_item "meta_keywords" LANGUAGE_CODE %} {% trans 'страница' %} {{ page_num }}" />
  45.             {% else %}
  46.             <meta name="keywords" content="{% get_field_translate object_item "meta_keywords" LANGUAGE_CODE %}" />
  47.             {% endif %}
  48.         {% endif %}
  49.  
  50.         {% if seo_page_text and seo_page_text_meta_description %}
  51.             {% if page_num != 1 %}
  52.             <meta name="description" content="{{ seo_page_text_meta_description }} {% trans 'страница' %} {{ page_num }}" />
  53.             {% else %}
  54.             <meta name="description" content="{{ seo_page_text_meta_description }}" />
  55.             {% endif %}
  56.         {% elif meta_description %}
  57.             {% if page_num != 1 %}
  58.             <meta name="description" content="{{ meta_description }} {% trans 'страница' %} {{ page_num }}" />
  59.             {% else %}
  60.             <meta name="description" content="{{ meta_description }}" />
  61.             {% endif %}
  62.         {% else %}
  63.             {% if page_num != 1 %}
  64.             <meta name="description" content="{% get_field_translate object_item "meta_description" LANGUAGE_CODE %} {% trans 'страница' %} {{ page_num }}" />
  65.             {% else %}
  66.             <meta name="description" content="{% get_field_translate object_item "meta_description" LANGUAGE_CODE %}" />
  67.             {% endif %}
  68.         {% endif %}
  69.  
  70.     {% else %}
  71.         {% if page_num == 1 %}
  72.             <meta name="keywords" content="{% get_field_translate seo_page_text "meta_keywords" LANGUAGE_CODE %}" />
  73.             <meta name="description" content="{% get_field_translate seo_page_text "meta_description" LANGUAGE_CODE %}" />
  74.         {% else %}
  75.             {#      Fix product keywords and description          #}
  76.             {% if page_num %}
  77.                 <meta name="keywords" content="{% get_field_translate seo_page_text "meta_keywords" LANGUAGE_CODE %}, {% if LANGUAGE_CODE == 'ru' %}страница{% else %}сторінка{% endif %} {{ page_num }}" />
  78.                 <meta name="description" content="{% get_field_translate seo_page_text "meta_description" LANGUAGE_CODE %} {% if LANGUAGE_CODE == 'ru' %}Cтраница{% else %}Сторінка{% endif %} {{ page_num }}" />
  79.                 {% else %}
  80.                     <meta name="keywords" content="{% get_field_translate seo_page_text "meta_keywords" LANGUAGE_CODE %}" />
  81.                     <meta name="description" content="{% get_field_translate seo_page_text "meta_description" LANGUAGE_CODE %}" />
  82.                 {% endif %}
  83.  
  84.  
  85.         {% endif %}
  86.     {% endif %}
  87.  
  88.  
  89.     {% if PREVIOUS %}
  90.         {% if PREVIOUS == 1 %}
  91.             <link rel="prev" href="https://paniyanovska.ua{{ path_redirect }}">
  92.         {% else %}
  93.             <link rel="prev" href="https://paniyanovska.ua{{ path_redirect }}page-{{ PREVIOUS }}/">
  94.         {% endif %}
  95.     {% endif %}
  96.     {% if NEXT %}
  97.         <link rel="next" href="https://paniyanovska.ua{{ path_redirect }}page-{{ NEXT }}/">
  98.     {% endif %}
  99.     {% if show_noindex_tag %}
  100.         <meta name="robots" content="noindex, nofollow" />
  101.     {% endif %}
  102. {% endblock %}
  103.  
  104.  
  105. {% block body %}
  106.     {% block body__breadcrumbs %}
  107.         {{ block.super }}
  108.     {% endblock body__breadcrumbs %}
  109.  
  110.     {% block content__seo %}
  111.     {% endblock content__seo %}
  112.  
  113.     {% block left_sidebar %}
  114.     {% endblock left_sidebar %}
  115.  
  116.     {% block content %}
  117.         <div id="content" class="col-sm-9 wrapper-product">
  118.             <div id="content-inner" class="row">
  119.                 <div class="view-product-list view-catalog">
  120.                     <div class="view-content row clearfix mobile-change--row">
  121.                     {% block content__content %}
  122.                         {% for product in object_list %}
  123.                             {% include "shop/parts/product.html" with object=product %}
  124.                         {% endfor %}
  125.                     {% endblock content__content %}
  126.                     </div>
  127.                 </div>
  128.             </div>
  129.             {% include 'paginator.html' %}
  130.         </div>
  131.     {% endblock content %}
  132.  
  133.     {% block body__top_bottom %}
  134.     {% endblock %}
  135.  
  136.     {% block body__bottom %}
  137.         <div id="sidebar-bottom" class="inactive">
  138.             {% if view_type == "category" and object_list %}
  139.                 {% if choosen_filter %}
  140.                     {% if seo_page_text and seo_page_text_bottom and page_num == 1 %}
  141.                         <div class="sidebar-inner">
  142.                             <div class="category-description">
  143.                                 <div class='sidebar-inner__all-text'>
  144.                                     {{ seo_page_text_bottom|safe }}
  145.                                 </div>
  146.                                 <div class="btn is-more-text">{% trans "Read more" %}</div>
  147.                                 <div class="btn is-minimize-text" style="display: none;">{% trans 'Свернуть' %}</div>
  148.                             </div>
  149.                         </div>
  150.                     {% endif %}
  151.                 {% elif page_num == 1 and object_list %}
  152.                     <div class="sidebar-inner">
  153.                         <div class="category-description">
  154.                             <div class='sidebar-inner__all-text'>
  155.                                 {% get_field_translate object_item "seo_bottom_text" LANGUAGE_CODE %}
  156.                             </div>
  157.                             <div class="btn is-more-text">{% trans "Read more" %}</div>
  158.                             <div class="btn is-minimize-text" style="display: none;">{% trans 'Свернуть' %}</div>
  159.                         </div>
  160.                     </div>
  161.                 {% endif %}
  162.             {% elif view_type == "section" and object_list %}
  163.                 {% if seo_page_text and page_num == 1 %}
  164.                     <div class="sidebar-inner">
  165.                         <div class="category-description">
  166.                             <div class='sidebar-inner__all-text'>
  167.                                 {% get_field_translate seo_page_text "bottom" LANGUAGE_CODE %}
  168.                             </div>
  169.                             <div class="btn is-more-text">{% trans "Read more" %}</div>
  170.                             <div class="btn is-minimize-text" style="display: none;">{% trans 'Свернуть' %}</div>
  171.                         </div>
  172.                     </div>
  173.                 {% endif %}
  174.             {% elif seo_page_text and page_num == 1 and object_list %}
  175.                 <div class="sidebar-inner">
  176.                     <div class="category-description">
  177.                         <div class='sidebar-inner__all-text'>
  178.                             {% get_field_translate seo_page_text "bottom" LANGUAGE_CODE %}
  179.                         </div>
  180.                         <div class="btn is-more-text">{% trans "Read more" %}</div>
  181.                         <div class="btn is-minimize-text" style="display: none;">{% trans 'Свернуть' %}</div>
  182.                     </div>
  183.                 </div>
  184.             {% endif %}
  185.         </div>
  186.     {% endblock body__bottom %}
  187.  
  188. {% endblock body %}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement