Fix employee details opened from qualification details not showing any skills (#34)

Co-authored-by: Phan Huy Tran <p.tran@neusta.de>
Reviewed-on: http://git.simonis.lol/angular/ems-frontend/pulls/34
Reviewed-by: Constantin Simonis <constantin@simonis.lol>
This commit is contained in:
Huy
2025-01-15 08:31:12 +00:00
parent 8284e1634d
commit d96bf3d475
3 changed files with 29 additions and 15 deletions

View File

@ -1,20 +1,22 @@
<h2 mat-dialog-title class="text-xl font-semibold mb-4">
Employees with {{ qualification.skill }}
{{ qualification.skill }} Developers
</h2>
<mat-dialog-content>
<mat-dialog-content class="px-1">
@if (employees$ | async; as employees) {
@if (employees.length === 0) {
<p class="text-gray-500 italic">No employees found with this qualification.</p>
} @else {
@for (employee of employees; track employee.id) {
<a
class="flex items-center p-3 bg-gray-50 rounded-lg hover:bg-gray-100 transition-colors"
(click)="openEmployeeDetailsModal(employee)"
>
<span class="font-medium">{{ employee.firstName }} {{ employee.lastName }}</span>
</a>
}
<div class="space-y-1">
@for (employee of employees; track employee.id) {
<a
class="block w-full px-4 py-2 text-blue-600 rounded-lg hover:bg-blue-50 transition-colors cursor-pointer"
(click)="openEmployeeDetailsModal(employee.id)"
>
<span class="font-medium">{{ employee.firstName }} {{ employee.lastName }}</span>
</a>
}
</div>
}
}
</mat-dialog-content>