templates/tennis_court_availability/parts/venue_header_single_venue.html.twig line 1

Open in your IDE?
  1. <div class="desktop">
  2.     {% if app.user %}
  3.         {% include 'tennis_court_availability/parts/favoured_venues.html.twig' %}
  4.     {% endif %}
  5.     {% set url =  "Check Booking Engine allocation" %}
  6.     {% if tennis_venue.bookingEngine == "ClubSpark" %}
  7.         {% set url = "https://clubspark.lta.org.uk/"~tennis_venue.bookingUrl~"/Booking/BookByDate#?date="~date|date('Y-m-d')~"&role=guest" %}
  8.     {% endif %}
  9.     {% if tennis_venue.bookingEngine == "ParkSports" %}
  10.         {% set url = "https://"~tennis_venue.bookingUrl~ ".parksports.co.uk/Booking/BookByDate#?date="~date|date('Y-m-d')~"&role=guest" %}
  11.     {% endif %}
  12.     {% if tennis_venue.bookingUrl is not null %}
  13.         {% if is_granted('ROLE_ACEIFY') %}
  14.             <a target="_blank"
  15.                title="{{ url }}"
  16.                href={{ url }}> <i syle="font-size: 20px; colour: red" class="fas fa-link"></i>
  17.             </a>
  18.         {% endif %}
  19.     {% endif %}
  20.     {% if tennis_venue.mapLink is not null %}
  21.         <a target="_blank"
  22.            title="{{ tennis_venue.address }}, {{ tennis_venue.addressCity }} {{ tennis_venue.addressPostcode }}"
  23.            href={{ path('venue_address', {id: tennis_venue.id}) }}><i
  24.                     style="font-size: 15px; color: red" class="fas fa-map-marker"></i></a>
  25.     {% endif %}
  26.     {% if is_granted('ROLE_ACEIFY') %}
  27.         <i title="Last updated: {{ CourtLastScrapeTime.returnCourtScrapeTime(12, tennis_venue, date)|date('d-M-y H:i') }}  "
  28.            style="color: grey   " class="fa fa-clock-o"></i>
  29.         {% if  CourtLastScrapeTime.returnCourtScrapeTime(12, tennis_venue, date)  is not null %}
  30.             {{ CourtLastScrapeTime.timeDifference('now'|date('Y-m-d H:i'),CourtLastScrapeTime.returnCourtScrapeTime(12, tennis_venue, date)) }}
  31.         {% endif %}
  32.     {% endif %}
  33.     {% if app.user %}<br>
  34.         {% include 'tennis_court_availability/parts/distance_to_venue_by_player_home.html.twig' %}
  35.         {% include 'tennis_court_availability/parts/distance_to_venue_by_player_work.html.twig' %}
  36.     {% endif %}
  37.     {% if is_granted('ROLE_ACEIFY') %}
  38.         <a href={{ path('tennis_court_availability_scrape', {venue: tennis_venue.id, date: date|date('Y-m-d')}) }}>
  39.             <i style="font-size: 15px; color: red; background-color: yellow" class="fas fa-download"></i></a>
  40.     {% endif %}
  41. </div>