-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(IN): visualizacion de registros en sidebar (#2973)
- Loading branch information
Showing
11 changed files
with
827 additions
and
216 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
...camas/views/listado-internacion-capas/filtros-listado/filtros-medicamentos.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<plex-wrapper> | ||
<plex-text (change)="filtrar()" [(ngModel)]="filtros.paciente" label="Sector"> | ||
</plex-text> | ||
<plex-datetime type="date" (change)="filtrarFecha()" [(ngModel)]="filtros.fechaIngresoDesde" | ||
name="fechaIngresoDesde" label="Fecha desde" [max]="filtros.fechaIngresoHasta" [debounce]="600"> | ||
</plex-datetime> | ||
<plex-datetime type="date" [(ngModel)]="filtros.fechaIngresoHasta" name='fechaIngresoHasta' label="Fecha hasta" | ||
(change)="filtrarFecha()" [min]="filtros.fechaIngresoDesde" [debounce]="600"> | ||
</plex-datetime> | ||
<!-- <plex-datetime type="date" (change)="filtrarFecha()" [(ngModel)]="filtros.fechaEgresoDesde" name="fechaIngresoDesde" | ||
label="Egreso desde" [max]="filtros.fechaEgresoHasta" [debounce]="600"> | ||
</plex-datetime> | ||
<plex-datetime type="date" [(ngModel)]="filtros.fechaEgresoHasta" name='fechaEgresoHasta' label="Egreso hasta" | ||
(change)="filtrarFecha()" [min]="filtros.fechaEgresoDesde" [debounce]="600"> | ||
</plex-datetime> --> | ||
</plex-wrapper> |
52 changes: 52 additions & 0 deletions
52
...a-camas/views/listado-internacion-capas/filtros-listado/filtros-medicamentos.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
import { Component, OnInit } from '@angular/core'; | ||
import * as enumerados from '../../../../../../utils/enumerados'; | ||
import { PermisosMapaCamasService } from '../../../services/permisos-mapa-camas.service'; | ||
import { ListadoInternacionCapasService } from '../listado-internacion-capas.service'; | ||
|
||
@Component({ | ||
selector: 'app-filtros-medicamentos', | ||
templateUrl: './filtros-medicamentos.component.html', | ||
}) | ||
|
||
export class FiltrosMedicamentosComponent implements OnInit { | ||
filtros: any = { | ||
fechaIngresoDesde: moment().subtract(1, 'months').toDate(), | ||
fechaIngresoHasta: moment().toDate(), | ||
fechaEgresoDesde: null, | ||
fechaEgresoHasta: null | ||
}; | ||
estadosInternacion; | ||
requestInProgress: boolean; | ||
|
||
constructor( | ||
private listadoInternacionService: ListadoInternacionCapasService, | ||
public permisosMapaCamasService: PermisosMapaCamasService, | ||
) { } | ||
|
||
ngOnInit() { | ||
this.resetFiltros(); | ||
this.estadosInternacion = enumerados.getObjEstadoInternacion(); | ||
} | ||
|
||
resetFiltros() { | ||
this.listadoInternacionService.pacienteText.next(null); | ||
this.listadoInternacionService.estado.next(null); | ||
this.filtrarFecha(); | ||
} | ||
|
||
filtrar() { | ||
this.listadoInternacionService.pacienteText.next(this.filtros.paciente); | ||
if (this.filtros.estado) { | ||
this.listadoInternacionService.estado.next(this.filtros.estado.id); | ||
} else { | ||
this.listadoInternacionService.estado.next(null); | ||
} | ||
} | ||
|
||
filtrarFecha() { | ||
this.listadoInternacionService.fechaIngresoDesde.next(this.filtros.fechaIngresoDesde); | ||
this.listadoInternacionService.fechaIngresoHasta.next(this.filtros.fechaIngresoHasta); | ||
this.listadoInternacionService.fechaEgresoDesde.next(this.filtros.fechaEgresoDesde); | ||
this.listadoInternacionService.fechaEgresoHasta.next(this.filtros.fechaEgresoHasta); | ||
} | ||
} |
79 changes: 79 additions & 0 deletions
79
.../rup/mapa-camas/views/listado-internacion-capas/listado-medicamentos-capas.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
<plex-layout-main *ngIf="mainView$ | async as mainView"> | ||
<header *ngIf="mainView === 'principal'"> | ||
<plex-title titulo="Listado de medicamentos"> | ||
<plex-button label="VOLVER" type="danger" (click)="volver()"></plex-button> | ||
</plex-title> | ||
</header> | ||
<!-- <app-filtros-medicamentos></app-filtros-medicamentos> --> | ||
<plex-wrapper> | ||
<!-- <plex-text (change)="filtrar()" [(ngModel)]="filtros.paciente" label="Sector"> | ||
</plex-text> --> | ||
<plex-datetime type="date" (change)="filtrar()" [(ngModel)]="fechaDesdeEntrada" name="fechaIngresoDesde" | ||
label="Fecha desde" [max]="fechaHastaEntrada" [debounce]="600"> | ||
</plex-datetime> | ||
<plex-datetime type="date" [(ngModel)]="fechaHastaIngreso" name='fechaIngresoHasta' label="Fecha hasta" | ||
(change)="filtrar()" [min]="fechaDesdeEntrada" [debounce]="600"> | ||
</plex-datetime> | ||
<!-- <plex-datetime type="date" (change)="filtrarFecha()" [(ngModel)]="filtros.fechaEgresoDesde" name="fechaIngresoDesde" | ||
label="Egreso desde" [max]="filtros.fechaEgresoHasta" [debounce]="600"> | ||
</plex-datetime> | ||
<plex-datetime type="date" [(ngModel)]="filtros.fechaEgresoHasta" name='fechaEgresoHasta' label="Egreso hasta" | ||
(change)="filtrarFecha()" [min]="filtros.fechaEgresoDesde" [debounce]="600"> | ||
</plex-datetime> --> | ||
</plex-wrapper> | ||
<ng-container *ngIf="mainView === 'principal'"> | ||
<!-- <div *ngIf="listadoInternacionCapasService.missingFilters$ | async" justify="center" class="mt-5"> | ||
<plex-label class="flex-column" icon="magnify" type="info" size="xl" direction="column" | ||
titulo="No hay resultados" | ||
subtitulo="Debe ingresar un rango valido de fechas de ingreso o egreso"> | ||
</plex-label> | ||
</div> --> | ||
<ng-container> | ||
<!-- <div justify="center" class="mt-5"> | ||
<plex-label class="flex-column" icon="magnify" type="info" size="xl" direction="column" | ||
titulo="No hay resultados" | ||
subtitulo="No hay resultados que coincidan con los filtros de búsqueda"> | ||
</plex-label> | ||
</div> --> | ||
<plex-table [columns]="columns" #table="plTable" (scroll)="onScroll()"> | ||
<plex-table-columns> | ||
</plex-table-columns> | ||
|
||
<!-- <tr *ngFor="let internacion of (listaMedicamentos$)" class="selectable" (click)="onSelect(internacion)"> --> | ||
<tr *ngFor="let internacion of (listaMedicamentos$| plSort:table| async)"> | ||
|
||
<td></td> | ||
<td *plTableCol="'organizacion'"> | ||
{{internacion.organizacion.nombre }} | ||
</td> | ||
<td *plTableCol="'nombre'"> | ||
{{internacion.paciente | nombre }} | ||
</td> | ||
<td *plTableCol="'documento'"> | ||
{{ internacion.paciente | documento }} | ||
</td> | ||
<td *plTableCol="'diagnostico'"> | ||
<span *ngIf="internacion.valor.nombre || internacion.valor.medicamento?.term"> | ||
{{ internacion.valor.nombre || internacion.valor.medicamento?.term}} | ||
</span> | ||
</td> | ||
<td *plTableCol="'estado'"> | ||
<span *ngIf="internacion.estadoActual?.verificacion?.estado"> | ||
{{ internacion.estadoActual?.verificacion?.estado}} | ||
</span> | ||
</td> | ||
<td *plTableCol="'fecha'"> | ||
<span *ngIf="internacion.fechaInicio"> | ||
{{ internacion.fechaInicio | fecha}} | ||
</span> | ||
</td> | ||
<td *plTableCol="'fechaEstado'"> | ||
<span *ngIf="internacion.estadoActual?.fecha"> | ||
{{ internacion.estadoActual?.fecha | fecha}} | ||
</span> | ||
</td> | ||
|
||
</tr> | ||
</plex-table> | ||
</ng-container> | ||
</ng-container> |
Oops, something went wrong.