Skip to content

Commit

Permalink
fix(MONIT-57): Visualización listado de elementos rup
Browse files Browse the repository at this point in the history
  • Loading branch information
aldoEMatamala committed Oct 4, 2023
1 parent 8698b11 commit 7591955
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,35 @@
<b label>Nombre</b>
<b label>Concepto</b>
<b label>Componente</b>
<b></b>
<b label>Tipo</b>
<b label>Requeridos</b>
<b button></b>
</plex-heading>
<plex-item *ngFor="let elemento of elementosRup$ | async">
<plex-label titulo="{{ elemento.nombre }}"> </plex-label>
<plex-label titulo="{{ elemento.conceptos[0].term }}"> </plex-label>
<plex-label titulo="{{ elemento.nombre? elemento.nombre: 'S/N' }}">
</plex-label>
<plex-label titulo="{{ elemento.conceptos[0]?.term }}"> </plex-label>
<plex-label titulo="{{ elemento.componente }}" [tituloBold]="false"> </plex-label>
<plex-label></plex-label>
<plex-label titulo="{{ elemento.tipo }}" [tituloBold]="false"> </plex-label>
<plex-label [tituloBold]="false"> {{ elemento.requeridos?.length || 0 }} </plex-label>

<plex-button type="success" style="display: none;">hola</plex-button>
<ng-container [ngSwitch]="elemento.componente" ngProjectAs="plex-button">
<plex-button *ngSwitchCase="'MoleculaBaseComponent'" type="warning" icon="pencil" size="sm"
[routerLink]="['molecula', elemento.id]">
</plex-button>
<plex-button *ngSwitchCase="'SeccionadoComponent'" type="warning" icon="pencil" size="sm"
[routerLink]="['seccion', elemento.id]">
</plex-button>
<plex-button *ngSwitchCase="'PRESTACION'" type="warning" icon="pencil" size="sm"
[routerLink]="['prestacion', elemento.id]">
</plex-button>
<plex-button *ngSwitchDefault type="warning" icon="pencil" size="sm"
[routerLink]="['atomo', elemento.id]">
</plex-button>

</ng-container>

<div class="d-flex justify-content-end w-100">
<ng-container [ngSwitch]="elemento.componente" ngProjectAs="plex-button">
<plex-button *ngSwitchCase="'MoleculaBaseComponent'" type="warning" icon="pencil" size="sm"
[routerLink]="['molecula', elemento.id]">
</plex-button>
<plex-button *ngSwitchCase="'SeccionadoComponent'" type="warning" icon="pencil" size="sm"
[routerLink]="['seccion', elemento.id]">
</plex-button>
<plex-button *ngSwitchCase="'PRESTACION'" type="warning" icon="pencil" size="sm"
[routerLink]="['prestacion', elemento.id]">
</plex-button>
<plex-button *ngSwitchDefault type="warning" icon="pencil" size="sm"
[routerLink]="['atomo', elemento.id]">
</plex-button>
</ng-container>
</div>
</plex-item>
</plex-list>
</plex-layout-main>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export class ElementosRupListadoService {
*/
elementosVisibles(elementos: IElementoRUP[]) {
return elementos.filter(e => {
return !!e.updatedAt || !!e.createdAt;
return e.activo;
});
}

Expand Down

0 comments on commit 7591955

Please sign in to comment.