{% extends 'frontend/base.html.twig' %}{% block metaTitle %}{% trans %}Trova i Rivenditori Piscine Astralpool Vicini Alla tua Zona{% endtrans %}{% endblock %}{% block metaDescription %}{% trans %}I rivenditori qualificati AstralPool Official Partner possono essere il tuo fornitore personale e la tua guida nella scelta della tua prossima piscina{% endtrans %}.{% endblock %}{% block body %} {% include 'frontend/partials/_breadcrumb.html.twig' %} <section class="space-1"> <div class="container"> <div class="position-relative mb-4"> <div class="d-lg-none"> <figure class="media equal-1-1"> <span style="background-image: url('{{ asset('images/reseller.jpg') }}')"></span> </figure> </div> <div class="d-none d-lg-block"> <figure class="media equal-2-1"> <span style="background-image: url('{{ asset('images/reseller.jpg') }}')"></span> </figure> </div> </div> </div> </section> <section class="space-top-lg-1 space-bottom-lg-3 space-bottom-2"> <div class="container"> <h1 class="display-5 fw-bold mb-4"> {{ pageIntroduction(constant('App\\Entity\\PageIntroduction::PAGE_RESELLER')).title }} </h1> <div class="page-content"> {{ pageIntroduction(constant('App\\Entity\\PageIntroduction::PAGE_RESELLER')).description|raw }} </div> <div class="space-top-1" id="reseller-app"> <div class="row mb-4"> <div class="col-12 col-lg-4 mb-3 mb-lg-0"> <input type="text" class="form-control" placeholder="{% trans %}Inserisci località / cap per cercare un rivenditore{% endtrans %}" v-model="query"> </div> <div class="col-12 col-lg-8 text-end"> <div class="dropdown" id="filter-dropdown"> <button class="btn btn-outline-primary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false"> Tipologia<span v-if="type">: [[ Translator.trans(type) ]]</span> <span class="ms-2">{{ svg_inject('filter') }}</span> </button> <ul class="dropdown-menu dropdown-menu-end"> <li><a class="dropdown-item" href="#" @click.prevent="type = null">{% trans %}Tutti{% endtrans %}</a></li> <li><a class="dropdown-item" href="#" @click.prevent="type = t" v-for="t in types">[[ Translator.trans(t) ]]</a></li> </ul> </div> </div> </div> <div class="row"> <div class="col-12 col-lg-4 order-1 order-lg-0"> <div id="reseller-list"> <div class="position-relative"> <div class="search-result-box shadow bg-light rounded p-3" v-show="showResults" > <div v-if="filteredResellers.length > 0"> <div class="text-muted fs-sm text-uppercase">{% trans %}Rivenditori{% endtrans %}</div> <div ref="resellerList"> <div v-for="reseller in filteredResellers" :key="reseller.id" class="search-box-item d-flex align-items-center" tabindex="0" @click="() => selectReseller(reseller)" @keydown.enter="() => selectReseller(reseller)" > <div class="rounded bg-white me-2 result-icon"> <figure class="media equal-1-1" style="width: 16px; height: 16px"> <span :style="{'background-image': `url('${reseller.icon.icon.publicUrl}')`}"></span> </figure> </div> <span class="fw-medium">[[ reseller.name ]]</span> </div> </div> </div> <div v-if="shownPlaces.length > 0"> <div class="text-muted fs-sm text-uppercase">{% trans %}Luoghi{% endtrans %}</div> <div ref="placeList"> <div v-for="place in shownPlaces" :key="place.place_id" class="search-box-item d-flex align-items-center" tabindex="0" @click="() => selectPlace(place)" @keydown.enter="() => selectPlace(place)" > <span class="rounded bg-white me-2 result-icon"> <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="#000000" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"/> <circle cx="12" cy="11" r="3"/> <path d="M17.657 16.657l-4.243 4.243a2 2 0 0 1 -2.827 0l-4.244 -4.243a8 8 0 1 1 11.314 0z"/> </svg> </span> <span class="fw-medium">[[ place.description ]]</span> </div> </div> </div> </div> </div> <div class="flex-grow-1" style="overflow: scroll"> <div> <div v-for="reseller in shownResellers" class="mb-3 p-3 bg-light cursor-pointer d-flex align-items-center" @click="onSelectReseller(reseller)"> <div style="min-width: 100px"> <figure class="media equal-1-1"> <span :style="{'background-image': `url('${reseller.icon.icon.publicUrl}')`}"></span> </figure> </div> <div class="ms-3 w-100"> <div class="w-100 d-flex justify-content-between align-content-center"> <span class="h5 mb-0">[[ reseller.name ]]</span> <span class="text-primary fw-bold text-nowrap">[[ resellerDistanceFromCenter(reseller) ]] km</span> </div> <p class="m-0 text-primary text-uppercase fw-bold">[[ reseller.type === 'official_partner' ? 'Official Partner' : 'E-Partner' ]]</p> <p class="m-0" v-html="reseller.address.fullAddress"></p> <div class="d-flex"> <a class="m-0 text-primary me-3" :href="`tel:${reseller.phone}`" v-if="reseller.phone"> [[ reseller.phone ]] </a> <a class="m-0 text-primary" :href="`mailto:${reseller.email}`" v-if="reseller.email"> [[ reseller.email ]] </a> </div> <div class="d-block"> <a class="m-0 text-primary" :href="reseller.website" target="_blank" v-if="reseller.website"> [[ reseller.website ]] </a> </div> </div> </div> <div v-if="filteredResellers.length === 0" class="text-center py-5"> <span class="h5 text-muted">{% trans %}Nessun risultato trovato{% endtrans %}</span> </div> </div> </div> </div> </div> <div class="col-12 col-lg-8 order-0 order-lg-1 position-relative"> <div id="reseller-map"></div> <div v-if="selectedReseller" class="position-absolute w-100" style="top: 5px; left: 0"> <div class="p-3 bg-light mx-3 d-flex align-items-center"> <div style="min-width: 100px"> <figure class="media equal-1-1"> <span :style="{'background-image': `url('${selectedReseller.icon.icon.publicUrl}')`}"></span> </figure> </div> <div class="ms-3"> <span class="h5">[[ selectedReseller.name ]]</span> <p class="m-0 text-primary text-uppercase fw-bold">[[ selectedReseller.type === 'official_partner' ? 'Official Partner' : 'E-Partner' ]]</p> <p class="m-0" v-html="selectedReseller.address.fullAddress"></p> <div class="d-flex"> <a class="m-0 text-primary me-3" :href="`tel:${selectedReseller.phone}`" v-if="selectedReseller.phone"> [[ selectedReseller.phone ]] </a> <a class="m-0 text-primary" :href="`mailto:${selectedReseller.email}`" v-if="selectedReseller.email"> [[ selectedReseller.email ]] </a> </div> <div class="d-block"> <a class="m-0 text-primary" :href="selectedReseller.website" target="_blank" v-if="selectedReseller.website"> [[ selectedReseller.website ]] </a> </div> </div> </div> </div> </div> </div> </div> </div> </section>{% endblock %}{% block javascripts %} <script> window.resellers = {{ resellers|serialize('json', { groups: 'api' })|raw }}; </script> {{ encore_entry_script_tags('frontend_reseller') }}{% endblock %}{% block stylesheets %} {{ encore_entry_link_tags('frontend_reseller') }}{% endblock %}