-
-
Save uno-de-piera/eab92c21351fd77f770abe5752ec67fe to your computer and use it in GitHub Desktop.
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
<!-- COLUMNA DELETE --> | |
<ng-container matColumnDef="delete"> | |
<mat-header-cell *matHeaderCellDef>Eliminar</mat-header-cell> | |
<mat-cell *matCellDef="let asignatura"> | |
<button mat-raised-button color="warn" (click)="remove(asignatura.id)">Eliminar</button> | |
</mat-cell> | |
</ng-container> |
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
<!-- COLUMNA DELETE --> | |
<ng-container matColumnDef="delete"> | |
<mat-header-cell *matHeaderCellDef>Eliminar</mat-header-cell> | |
<mat-cell *matCellDef="let asignatura"> | |
<button mat-raised-button color="warn" (click)="remove(asignatura)">Eliminar</button> | |
</mat-cell> | |
</ng-container> |
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
remove(id) { | |
this.asignaturaService.delete(id).then(() => { | |
this.snackService.launch('Asignatura eliminada correctamente', 'Cerrar', 5000); | |
}) | |
} |
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
remove(asignatura) { | |
this.asignaturaService.delete(asignatura.id).then(() => { | |
this.snackService.launch('Asignatura eliminada correctamente', 'Cerrar', 5000); | |
}) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment