src/Aqarmap/Bundle/MainBundle/Resources/views/Default/sitemapFlow.html.twig line 1

  1. {% extends "base.html.twig" %}
  2. {# Page title #}
  3. {% block title %}{{ parent() }} • {{ ('layout.homepage_'~country) |trans }}{% endblock %}
  4. {% block htmlhead %}
  5. <link rel="alternate" hreflang="ar"
  6. href="{{ url(app.request.get('_route'), app.request.get('_route_params')|merge({'_locale': 'ar'})) }}"/>
  7. <link rel="alternate" hreflang="en"
  8. href="{{ url(app.request.get('_route'), app.request.get('_route_params')|merge({'_locale': 'en'})) }}"/>
  9. <link rel="alternate" hreflang="x-default"
  10. href="{{ url(app.request.get('_route'), app.request.get('_route_params')|merge({'_locale': 'ar'})) }}"/>
  11. {% endblock %}
  12. {% block body %}
  13. {% set histogramMaxPrices = {
  14. 'for-sale': [
  15. 100000, 200000, 300000, 400000, 500000, 600000, 700000, 800000, 900000, 1000000,
  16. 1250000, 1500000, 1750000, 2000000, 2250000, 2500000, 2750000, 3000000, 3250000,
  17. 3500000, 3750000, 4000000, 4500000, 5000000, 6000000, 7000000, 8000000, 9000000,
  18. 10000000, 15000000, 20000000, 30000000, 40000000, 50000000, 100000000, 250000000,
  19. 500000000
  20. ],
  21. 'for-rent': [
  22. 250, 500, 1000, 1500, 2000, 2500, 3000, 3500, 4000, 4500, 5000, 6000, 7000, 8000,
  23. 9000, 10000, 15000, 20000, 30000, 40000, 50000, 75000, 100000, 250000, 500000
  24. ]
  25. } %}
  26. <section class="container filterContainer {{ app.request.get('_route') }}">
  27. <div class="row">
  28. <div class="col-md-12">
  29. <div class="page-header">
  30. <h1>{{ 'layout.sitemap'|trans }}</h1>
  31. </div>
  32. <div class="container">
  33. {% if searchableSections is defined %}
  34. <ul>
  35. {% for searchableSection in searchableSections %}
  36. <li>
  37. <a title="{{ 'layout.title.search_short'|trans({'%property_type%': '','%section%': searchableSection.title}) }}"
  38. href="{{ url('sitemap_section_flow', {section: searchableSection.slug}) }}">
  39. {{ searchableSection.title }}
  40. </a>
  41. </li>
  42. {% endfor %}
  43. </ul>
  44. {% elseif section is defined %}
  45. <h2>
  46. {% if propertyType is defined and propertyType %}
  47. <a href="{{ url('property_type_search', {section_slug: section.slug, property_type_slug: propertyType.slug}) }}">{{ propertyType.title }}</a>
  48. {% endif %}
  49. <a href="{{ url('homepage') }}">{{ section.title }}</a>
  50. </h2>
  51. {% if searchableProperties is defined and not propertyType %}
  52. <ul>
  53. {% for searchableProperty in searchableProperties %}
  54. <li>
  55. <a href="{{ url('sitemap_section_property_type_flow', {section: section.slug, property_type: searchableProperty.propertyTypeSlug}) }}">
  56. {{ searchableProperty.propertyTypeTitle }}
  57. </a>
  58. </li>
  59. {% endfor %}
  60. </ul>
  61. {% endif %}
  62. {% if not propertyType and section.slug in histogramMaxPrices|keys %}
  63. <h3>{{ 'search_filters.price_range'|trans }}</h3>
  64. <ul>
  65. {% for maxPrice in attribute(histogramMaxPrices, section.slug) %}
  66. <li class="col-md-4">
  67. <a href="{{ url('property_type_search', {section_slug: section.slug, property_type_slug: 'property-type', maxPrice: maxPrice}) }}">
  68. {{ maxPrice|number_format(0, '.', ',') }}
  69. </a>
  70. </li>
  71. {% endfor %}
  72. </ul>
  73. {% endif %}
  74. {% if searchableLocations is defined and propertyType %}
  75. <ul class="col-md-12">
  76. {% for searchableLocation in searchableLocations %}
  77. <li class="col-md-4">
  78. <a href="{{ url('sitemap_section_property_type_location_flow', {section: section.slug, property_type: propertyType.slug, location: searchableLocation.locationSlug}) }}">
  79. {{ searchableLocation.locationTitle }}
  80. </a>
  81. </li>
  82. {% endfor %}
  83. </ul>
  84. {% endif %}
  85. {% if parentLocationBuild is defined %}
  86. <ul class="breadcrumb">
  87. {{ parentLocationBuild|raw }}
  88. </ul>
  89. {% endif %}
  90. {% if locationBuild is defined %}
  91. {{ locationBuild|raw }}
  92. {% endif %}
  93. {% endif %}
  94. </div>
  95. </div>
  96. </div>
  97. </section>
  98. {% endblock %}
  99. {% block footer %}
  100. {% include "footer.v2.html.twig" %}
  101. {% endblock %}