Commit 0fa71566656abba8fd22da76a98918d6afea6d3b
Exists in
develop
Merge branch 'master' into 'develop'
Master(benjamin) See merge request !88
Showing
2 changed files
Show diff stats
src/app/shared/promocion/promocion.component.html
1 | -<!-- <div class="d-flex justify-content-center" | |
2 | - *ngIf="loading"> | |
3 | - <div class="spinner-border text-primary" role="status"> | |
4 | - <span class="sr-only">Loading...</span> | |
5 | - </div> | |
6 | -</div> --> | |
7 | 1 | <div class="bg-primary rounded"> |
8 | 2 | <div class="modal-header" *ngIf="articulosPromo.length"> |
9 | 3 | <img |
... | ... | @@ -53,6 +47,13 @@ |
53 | 47 | </div> |
54 | 48 | </div> |
55 | 49 | <div |
50 | + class="d-flex justify-content-center mt-2" | |
51 | + *ngIf="loading"> | |
52 | + <div class="spinner-border text-white" role="status"> | |
53 | + <span class="sr-only">Loading...</span> | |
54 | + </div> | |
55 | + </div> | |
56 | + <div | |
56 | 57 | class="row mt-3 no-gutters lista-promociones scroll-y-visible" |
57 | 58 | (scroll)="scrollEvent($event)"> |
58 | 59 | <div class="col-12"> |
src/app/shared/promocion/promocion.component.ts
... | ... | @@ -21,6 +21,7 @@ export class PromocionComponent implements OnInit { |
21 | 21 | promociones: IArticulo[] = []; |
22 | 22 | onClose: Subject<any>; |
23 | 23 | urlImagenes = `${APP_SETTINGS.apiImagenes}/imagenes/`; |
24 | + loading = true; | |
24 | 25 | |
25 | 26 | constructor( |
26 | 27 | public modalPromocion: BsModalRef, |
... | ... | @@ -93,6 +94,7 @@ export class PromocionComponent implements OnInit { |
93 | 94 | this.promocionService.getPromociones(sector, codigo) |
94 | 95 | .subscribe((res: IArticulo[]) => { |
95 | 96 | this.promociones = res; |
97 | + this.loading = false; | |
96 | 98 | }, error => { console.error(error); }); |
97 | 99 | } |
98 | 100 |