Commit c0adc990654d220abdfe8d2400dacb8da6baf0ec

Authored by Marcelo Puebla
1 parent 1e9fe0ea4d
Exists in develop

Change

Leyenda y tamaño de boton ir al carrito
src/app/modules/seleccion-articulos/seleccion-articulos.component.html
1 <div class="h-92 bg-white fade-in-left"> 1 <div class="h-92 bg-white fade-in-left">
2 <!-- PUBLICIDADES --> 2 <!-- PUBLICIDADES -->
3 <app-header-publicidad></app-header-publicidad> 3 <app-header-publicidad></app-header-publicidad>
4 4
5 <div class="row mx-0 align-items-end" 5 <div class="row mx-0 align-items-end"
6 [ngClass]="boxCarrito.classList.contains('media-pantalla') 6 [ngClass]="boxCarrito.classList.contains('media-pantalla')
7 ? 'h-68' : 'h-80'"> 7 ? 'h-68' : 'h-80'">
8 <!-- CABECERA --> 8 <!-- CABECERA -->
9 <div class="row w-100 mx-3 h-auto border border-primary rounded-sm"> 9 <div class="row w-100 mx-3 h-auto border border-primary rounded-sm">
10 <div class="col-12 p-2 align-self-center"> 10 <div class="col-12 p-2 align-self-center">
11 <div class="px-3"> 11 <div class="px-3">
12 <p class="h6 text-truncate">SELECCIONÁ TÚ COMIDA Y/O BEBIDA</p> 12 <p class="h6 text-truncate">SELECCIONÁ TÚ COMIDA Y/O BEBIDA</p>
13 </div> 13 </div>
14 </div> 14 </div>
15 </div> 15 </div>
16 <!-- CUERPO --> 16 <!-- CUERPO -->
17 <div class="row w-100 mr-4 h-50 h-md-70" id="content"> 17 <div class="row w-100 mr-4 h-50 h-md-70" id="content">
18 <div class="col-12 h-100 px-0 py-3"> 18 <div class="col-12 h-100 px-0 py-3">
19 <div class="row mx-0 h-100"> 19 <div class="row mx-0 h-100">
20 <app-filtro-categorias 20 <app-filtro-categorias
21 class="col-5 col-sm-3 col-xl-2 h-100" 21 class="col-5 col-sm-3 col-xl-2 h-100"
22 #filtroCategorias 22 #filtroCategorias
23 (getProductos)="getProductos()" 23 (getProductos)="getProductos()"
24 (setProductos)="setProductos()" 24 (setProductos)="setProductos()"
25 (filterItems)="filterItems()"> 25 (filterItems)="filterItems()">
26 </app-filtro-categorias> 26 </app-filtro-categorias>
27 <!-- LISTA DE ARTICULOS --> 27 <!-- LISTA DE ARTICULOS -->
28 <div 28 <div
29 class="col-7 col-sm-9 col-xl-10 pb-3 h-100 align-self-center scroll-y-visible" 29 class="col-7 col-sm-9 col-xl-10 pb-3 h-100 align-self-center scroll-y-visible"
30 (scroll)="scrollEvent($event)"> 30 (scroll)="scrollEvent($event)">
31 <!-- SPINNER --> 31 <!-- SPINNER -->
32 <div 32 <div
33 class="d-flex justify-content-center" 33 class="d-flex justify-content-center"
34 *ngIf="loading"> 34 *ngIf="loading">
35 <div class="spinner-border text-primary mt-5" role="status"> 35 <div class="spinner-border text-primary mt-5" role="status">
36 <span class="sr-only">Loading...</span> 36 <span class="sr-only">Loading...</span>
37 </div> 37 </div>
38 </div> 38 </div>
39 <div class="row row-cols-1 row-cols-sm-3 row-cols-xl-6"> 39 <div class="row row-cols-1 row-cols-sm-3 row-cols-xl-6">
40 <!-- ARTICULO --> 40 <!-- ARTICULO -->
41 <div 41 <div
42 *ngFor="let articulo of auxArticulos | slice:0:showQuantity;" 42 *ngFor="let articulo of auxArticulos | slice:0:showQuantity;"
43 [hidden]="validarFecha(articulo.FECHA_VIGENCIA_DESDE, articulo.FECHA_VIGENCIA_HASTA)" 43 [hidden]="validarFecha(articulo.FECHA_VIGENCIA_DESDE, articulo.FECHA_VIGENCIA_HASTA)"
44 class="col px-2 my-1 my-md-3 h-auto"> 44 class="col px-2 my-1 my-md-3 h-auto">
45 <div 45 <div
46 class="swing-in-top-fwd btn-effect card h-auto" 46 class="swing-in-top-fwd btn-effect card h-auto"
47 (click)="selectArticulo(articulo)"> 47 (click)="selectArticulo(articulo)">
48 <img 48 <img
49 draggable="false" 49 draggable="false"
50 ondragstart="return false;" 50 ondragstart="return false;"
51 (contextmenu)="false" 51 (contextmenu)="false"
52 *ngIf="articulo.ExiVta < 1" 52 *ngIf="articulo.ExiVta < 1"
53 class="w-50 position-fixed right-0" 53 class="w-50 position-fixed right-0"
54 src="assets/img/sin-stock.svg"> 54 src="assets/img/sin-stock.svg">
55 <img 55 <img
56 draggable="false" 56 draggable="false"
57 ondragstart="return false;" 57 ondragstart="return false;"
58 (contextmenu)="false" 58 (contextmenu)="false"
59 src="{{urlImagenes}}{{articulo.imagenes[0].imagen}}" 59 src="{{urlImagenes}}{{articulo.imagenes[0].imagen}}"
60 onerror="this.src='assets/img/imagen-no-encontrada.jpg'" 60 onerror="this.src='assets/img/imagen-no-encontrada.jpg'"
61 class="card-img-top w-100 h-auto h-md-55 rounded-sm"> 61 class="card-img-top w-100 h-auto h-md-55 rounded-sm">
62 <div class="row mx-0 py-1 h-auto justify-content-center"> 62 <div class="row mx-0 py-1 h-auto justify-content-center">
63 <p class="col-12 px-1 h6 h-auto text-primary text-center min-h-60"> 63 <p class="col-12 px-1 h6 h-auto text-primary text-center min-h-60">
64 {{articulo.MKT_DESC ? articulo.MKT_DESC.toUpperCase() : articulo.DetArt.toUpperCase()}} 64 {{articulo.MKT_DESC ? articulo.MKT_DESC.toUpperCase() : articulo.DetArt.toUpperCase()}}
65 </p> 65 </p>
66 <div class="col-12 px-1 align-self-end h-auto"> 66 <div class="col-12 px-1 align-self-end h-auto">
67 <div class="row mx-0 justify-content-between bg-primary badge-pill"> 67 <div class="row mx-0 justify-content-between bg-primary badge-pill">
68 <div class="col px-0 align-self-center text-white text-right"> 68 <div class="col px-0 align-self-center text-white text-right">
69 {{articulo.PreVen | currency}} 69 {{articulo.PreVen | currency}}
70 </div> 70 </div>
71 <div class="col-5 px-0"> 71 <div class="col-5 px-0">
72 <img 72 <img
73 draggable="false" 73 draggable="false"
74 ondragstart="return false;" 74 ondragstart="return false;"
75 (contextmenu)="false" 75 (contextmenu)="false"
76 class="d-block ml-auto py-1 icon-30" 76 class="d-block ml-auto py-1 icon-30"
77 src="assets/img/ir.svg"> 77 src="assets/img/ir.svg">
78 </div> 78 </div>
79 </div> 79 </div>
80 </div> 80 </div>
81 </div> 81 </div>
82 </div> 82 </div>
83 </div> 83 </div>
84 </div> 84 </div>
85 <!-- BOTON VER MAS --> 85 <!-- BOTON VER MAS -->
86 <div class="row mx-0"> 86 <div class="row mx-0">
87 <div 87 <div
88 *ngIf="showQuantity <= auxArticulos.slice(0, showQuantity).length" 88 *ngIf="showQuantity <= auxArticulos.slice(0, showQuantity).length"
89 class="col-12 px-0 mb-2"> 89 class="col-12 px-0 mb-2">
90 <button 90 <button
91 (click)="increaseShow()" 91 (click)="increaseShow()"
92 class="btn btn-block btn-outline-primary"> 92 class="btn btn-block btn-outline-primary">
93 Ver Más 93 Ver Más
94 </button> 94 </button>
95 </div> 95 </div>
96 </div> 96 </div>
97 </div> 97 </div>
98 </div> 98 </div>
99 </div> 99 </div>
100 </div> 100 </div>
101 <!-- FOOTER CARRITO DE COMPRAS --> 101 <!-- FOOTER CARRITO DE COMPRAS -->
102 <div class="row w-90 mx-auto h-auto justify-content-center"> 102 <div class="row w-90 mx-auto h-auto justify-content-center">
103 <div class="h-75 px-0 border border-primary rounded" #boxCarrito 103 <div class="h-75 px-0 border border-primary rounded" #boxCarrito
104 [ngClass]="boxCarrito.classList.contains('media-pantalla') 104 [ngClass]="boxCarrito.classList.contains('media-pantalla')
105 ? 'col-8' : 'col-12'" id="boxCarrito"> 105 ? 'col-8' : 'col-12'" id="boxCarrito">
106 <!-- CABECERA --> 106 <!-- CABECERA -->
107 <div class="row mx-0 h-15 border-bottom border-primary"> 107 <div class="row mx-0 h-15 border-bottom border-primary">
108 <p class="col align-self-center text-truncate"><small>ARTÍCULOS EN TÚ CARRITO DE COMPRAS</small></p> 108 <p class="col align-self-center text-truncate"><small>ARTÍCULOS EN TÚ CARRITO DE COMPRAS</small></p>
109 </div> 109 </div>
110 <!-- CUERPO --> 110 <!-- CUERPO -->
111 <div class="row h-85 mx-0 justify-content-around"> 111 <div class="row h-85 mx-0 justify-content-around">
112 <!-- BOTON SCROLL IZQUIERDA --> 112 <!-- BOTON SCROLL IZQUIERDA -->
113 <div *ngIf="articuloService.carrito.length" class="col-auto btn-effect h-20 align-self-center"> 113 <div *ngIf="articuloService.carrito.length" class="col-auto btn-effect h-20 align-self-center">
114 <img 114 <img
115 draggable="false" 115 draggable="false"
116 ondragstart="return false;" 116 ondragstart="return false;"
117 (contextmenu)="false" 117 (contextmenu)="false"
118 class="icon-30 rotate-180-neg" 118 class="icon-30 rotate-180-neg"
119 src="assets/img/ir-fondo-color.svg" 119 src="assets/img/ir-fondo-color.svg"
120 (mousedown)="scrollX(templateCarrito, -100)" 120 (mousedown)="scrollX(templateCarrito, -100)"
121 (mouseup)="mouseup()" 121 (mouseup)="mouseup()"
122 (mouseleave)="mouseup()"> 122 (mouseleave)="mouseup()">
123 </div> 123 </div>
124 <!-- CARRITO --> 124 <!-- CARRITO -->
125 <div class="col-6 col-sm-8 col-lg-10 h-100"> 125 <div class="col-6 col-sm-8 col-lg-10 h-100">
126 <div 126 <div
127 #templateCarrito 127 #templateCarrito
128 class="row flex-row flex-nowrap h-100 mx-0 my-2 scroll-x" 128 class="row flex-row flex-nowrap h-100 mx-0 my-2 scroll-x"
129 (scroll)="scrollEvent($event)"> 129 (scroll)="scrollEvent($event)">
130 <!-- ARTICULOS --> 130 <!-- ARTICULOS -->
131 <div 131 <div
132 class="col-10 col-sm-4 col-lg-2 px-2 px-xl-4 align-self-center border-right border-primary" 132 class="col-10 col-sm-4 col-lg-2 px-2 px-xl-4 align-self-center border-right border-primary"
133 *ngFor="let articulo of articuloService.carrito; let i = index;" 133 *ngFor="let articulo of articuloService.carrito; let i = index;"
134 @EnterLeaveY> 134 @EnterLeaveY>
135 <img 135 <img
136 class="btn-effect icon-20 mr-2 position-absolute right-0" 136 class="btn-effect icon-20 mr-2 position-absolute right-0"
137 src="assets/img/icono-cancelar-color.svg" 137 src="assets/img/icono-cancelar-color.svg"
138 (click)="deleteArticulo(i)"> 138 (click)="deleteArticulo(i)">
139 <img 139 <img
140 draggable="false" 140 draggable="false"
141 ondragstart="return false;" 141 ondragstart="return false;"
142 (contextmenu)="false" 142 (contextmenu)="false"
143 class="d-block img-fluid p-2 mx-auto rounded w-100 h-auto" 143 class="d-block img-fluid p-2 mx-auto rounded w-100 h-auto"
144 src="{{urlImagenes}}{{articulo.imagenes[0].imagen}}" 144 src="{{urlImagenes}}{{articulo.imagenes[0].imagen}}"
145 onerror="this.src='assets/img/imagen-no-encontrada.jpg'"> 145 onerror="this.src='assets/img/imagen-no-encontrada.jpg'">
146 <p class="d-block mt-auto text-center text-primary text-truncate"> 146 <p class="d-block mt-auto text-center text-primary text-truncate">
147 <small>{{articulo.MKT_DESC ? articulo.MKT_DESC.toUpperCase() : articulo.DetArt.toUpperCase()}}</small> 147 <small>{{articulo.MKT_DESC ? articulo.MKT_DESC.toUpperCase() : articulo.DetArt.toUpperCase()}}</small>
148 </p> 148 </p>
149 <app-articulo-cantidad [articulo]="articulo"></app-articulo-cantidad> 149 <app-articulo-cantidad [articulo]="articulo"></app-articulo-cantidad>
150 </div> 150 </div>
151 <!-- MENSAJE DE ADVERTENCIA --> 151 <!-- MENSAJE DE ADVERTENCIA -->
152 <div *ngIf="!articuloService.carrito.length" class="col h-100"> 152 <div *ngIf="!articuloService.carrito.length" class="col h-100">
153 <p class="text-center py-5">No hay artículos en el carrito</p> 153 <p class="text-center py-5">No hay artículos en el carrito</p>
154 </div> 154 </div>
155 </div> 155 </div>
156 </div> 156 </div>
157 <!-- BOTON SCROLL DERECHA --> 157 <!-- BOTON SCROLL DERECHA -->
158 <div *ngIf="articuloService.carrito.length" 158 <div *ngIf="articuloService.carrito.length"
159 class="col-auto btn-effect h-20 align-self-center d-contents"> 159 class="col-auto btn-effect h-20 align-self-center d-contents">
160 <img 160 <img
161 draggable="false" 161 draggable="false"
162 ondragstart="return false;" 162 ondragstart="return false;"
163 (contextmenu)="false" 163 (contextmenu)="false"
164 class="icon-30" 164 class="icon-30"
165 src="assets/img/ir-fondo-color.svg" 165 src="assets/img/ir-fondo-color.svg"
166 (mousedown)="scrollX(templateCarrito, 100)" 166 (mousedown)="scrollX(templateCarrito, 100)"
167 (mouseup)="mouseup()" 167 (mouseup)="mouseup()"
168 (mouseleave)="mouseup()"> 168 (mouseleave)="mouseup()">
169 </div> 169 </div>
170 </div> 170 </div>
171 </div> 171 </div>
172 <!-- TOTAL--> 172 <!-- TOTAL-->
173 <div 173 <div
174 class="col-auto mt-2 ml-auto h-20"> 174 class="col-auto mt-2 ml-auto h-20">
175 <div class="row mx-0"> 175 <div class="row mx-0">
176 <div class="col-auto font-weight-bold align-self-center text-primary py-2 h3">TOTAL</div> 176 <p class="col-auto font-weight-bold align-self-center text-primary py-2 h3">TOTAL</p>
177 <div class="col-auto align-self-center bg-primary badge-pill"> 177 <div class="col-auto align-self-center bg-primary badge-pill">
178 <p class="text-center font-weight-bold text-white py-2 h3 px-2">{{articuloService.total | currency}}</p> 178 <p class="text-center font-weight-bold text-white py-2 h3 px-2">{{articuloService.total | currency}}</p>
179 </div> 179 </div>
180 </div> 180 </div>
181 </div> 181 </div>
182 182
183 <!-- VER CARRITO --> 183 <!-- VER CARRITO -->
184 <div 184 <div
185 class="col-auto px-0 h-20" 185 class="col-auto px-0 h-20"
186 *ngIf="articuloService.carrito.length" 186 *ngIf="articuloService.carrito.length"
187 [ngClass]="boxCarrito.classList.contains('media-pantalla') ? 'ml-auto' : 'mt-3'"> 187 [ngClass]="boxCarrito.classList.contains('media-pantalla') ? 'ml-auto' : 'mt-2'">
188 <div 188 <div
189 class="btn-effect col-auto px-0 align-self-center bg-white" 189 class="btn-effect col-auto px-0 align-self-center bg-white"
190 [routerLink]="['/carrito']"> 190 [routerLink]="['/carrito']">
191 <div class="row mx-0 bg-light"> 191 <div class="row mx-0 bg-light">
192 <div class="col-auto p-0 bg-primary"> 192 <div class="col-auto px-0 bg-primary">
193 <img 193 <img
194 draggable="false" 194 draggable="false"
195 ondragstart="return false;" 195 ondragstart="return false;"
196 (contextmenu)="false" 196 (contextmenu)="false"
197 class="p-2 icon-40" 197 class="p-2 icon-60"
198 src="assets/img/carrito.svg"> 198 src="assets/img/carrito.svg">
199 </div> 199 </div>
200 <div class="col-auto align-self-center text-primary d-none d-sm-block">IR AL CARRITO</div> 200 <div class="col-auto align-self-center text-primary d-none d-sm-block">PAGAR</div>
201 </div> 201 </div>
202 </div> 202 </div>
203 </div> 203 </div>
204 204
205 </div> 205 </div>
206 </div> 206 </div>
207 207
208 </div> 208 </div>
209 209