Fix: Explicitly import models in database.py to ensure table creation on Render
This commit is contained in:
@ -105,18 +105,30 @@ function clearRouteAndClose() {
|
||||
</div>
|
||||
|
||||
<div v-else>
|
||||
<!-- Route selector card (same style as MapView) -->
|
||||
<div v-if="routeStore.allRoutes.length > 0" class="route-card" ref="routeCardRef">
|
||||
<!-- Quick Select Route Buttons (Nexus Style) -->
|
||||
<div class="quick-routes-container">
|
||||
<div
|
||||
v-for="route in routeStore.allRoutes"
|
||||
:key="route.id"
|
||||
class="route-chip-nexus"
|
||||
:class="{ 'active': route.id === routeStore.selectedRouteId }"
|
||||
@click="selectRouteAndClose(route.id, route.name)"
|
||||
>
|
||||
<span class="material-icons chip-icon">directions_bus</span>
|
||||
<span class="chip-text">{{ route.name }}</span>
|
||||
<div v-if="route.id === routeStore.selectedRouteId" class="active-dot"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Route selector card (As backup/dropdown) -->
|
||||
<div class="route-card" ref="routeCardRef">
|
||||
<div class="route-card-content" @click.stop="showRouteDropdown = !showRouteDropdown">
|
||||
<span class="material-icons route-icon">route</span>
|
||||
<span class="material-icons route-icon">search</span>
|
||||
<div class="route-info">
|
||||
<div v-if="routeStore.selectedRouteId && routeStore.selectedRouteName" class="route-name">
|
||||
{{ t('schedules.route') }}: {{ routeStore.selectedRouteName }}
|
||||
</div>
|
||||
<div v-else class="route-name">{{ t('schedules.selectRoute') }}</div>
|
||||
<div v-if="routeStore.selectedRouteId && scheduleStore.schedules.length > 0" class="route-stops">
|
||||
{{ scheduleStore.schedules.length }} {{ t('schedules.schedules') }}
|
||||
{{ routeStore.selectedRouteName }}
|
||||
</div>
|
||||
<div v-else class="route-name">Buscar otra ruta...</div>
|
||||
</div>
|
||||
<span class="material-icons arrow-icon" :class="{ 'rotated': showRouteDropdown }">
|
||||
keyboard_arrow_down
|
||||
@ -134,13 +146,6 @@ function clearRouteAndClose() {
|
||||
>
|
||||
{{ route.name }}
|
||||
</div>
|
||||
<div
|
||||
v-if="routeStore.selectedRouteId"
|
||||
class="route-option clear-option"
|
||||
@click="clearRouteAndClose"
|
||||
>
|
||||
{{ t('common.clearSelection') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -208,9 +213,72 @@ function clearRouteAndClose() {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.quick-routes-container {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
gap: 12px;
|
||||
margin-bottom: 24px;
|
||||
max-width: 800px;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
.route-chip-nexus {
|
||||
background: rgba(255, 255, 255, 0.05);
|
||||
border: 1px solid var(--border-color);
|
||||
padding: 12px 20px;
|
||||
border-radius: 16px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.route-chip-nexus:hover {
|
||||
background: rgba(254, 231, 21, 0.1);
|
||||
border-color: var(--active-color);
|
||||
transform: translateY(-2px);
|
||||
}
|
||||
|
||||
.route-chip-nexus.active {
|
||||
background: var(--active-color);
|
||||
border-color: var(--active-color);
|
||||
color: #101820;
|
||||
box-shadow: 0 8px 20px rgba(254, 231, 21, 0.3);
|
||||
}
|
||||
|
||||
.chip-icon {
|
||||
font-size: 20px;
|
||||
color: var(--active-color);
|
||||
}
|
||||
|
||||
.route-chip-nexus.active .chip-icon {
|
||||
color: #101820;
|
||||
}
|
||||
|
||||
.chip-text {
|
||||
font-weight: 800;
|
||||
font-size: 0.9rem;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
.active-dot {
|
||||
position: absolute;
|
||||
top: 6px;
|
||||
right: 6px;
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
background: #101820;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.route-card {
|
||||
margin-bottom: 2rem;
|
||||
max-width: 600px;
|
||||
max-width: 400px;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user