@ -1,6 +1,6 @@
|
||||
<h2 mat-dialog-title>Delete {{employee.firstName}} {{employee.lastName}}</h2>
|
||||
<mat-dialog-content>Are you sure you want to delete {{employee.firstName}} {{employee.lastName}}? This cant be undone.</mat-dialog-content>
|
||||
<mat-dialog-actions>
|
||||
<button mat-button mat-dialog-close>Cancel</button>
|
||||
<button mat-button [mat-dialog-close]="true" (click)="deleteEmployee(employee.id ?? 0)">Delete</button>
|
||||
<button mat-button [mat-dialog-close]="false">Cancel</button>
|
||||
<button mat-button mat-dialog-close (click)="deleteEmployee(employee.id ?? 0)" cdkFocusInitial>Delete</button>
|
||||
</mat-dialog-actions>
|
||||
|
@ -1,4 +1,4 @@
|
||||
<section class="!space-y-6">
|
||||
<section class="!space-y-6 mb-6">
|
||||
@defer {
|
||||
@if (employees$ | async; as employees) {
|
||||
<div class="!space-y-6">
|
||||
@ -38,7 +38,7 @@
|
||||
<mat-icon>edit</mat-icon>
|
||||
</button>
|
||||
<button mat-icon-button color="warn" [matTooltip]="'Delete employee'" (click)="openDeleteDialogue(employee)">
|
||||
🗑️
|
||||
<mat-icon>delete</mat-icon>
|
||||
</button>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
@ -35,9 +35,6 @@ import EmployeeApiService from "../../services/employee-api.service";
|
||||
MatSortModule
|
||||
],
|
||||
templateUrl: './table.component.html',
|
||||
host: {
|
||||
class: 'block w-full p-6'
|
||||
},
|
||||
styleUrl: './table.component.css'
|
||||
})
|
||||
export class TableComponent implements OnInit{
|
||||
|
Reference in New Issue
Block a user