Skip to content

Commit 9b22091

Browse files
authored
[AIDAPP-1333]: The related to manager field in the Service Request list is not displaying the correct users (#1279)
* Refactor service request table to display assigned user instead of manager users Signed-off-by: Kevin Ullyott <kevin.ullyott@canyongbs.com> * Fix formatting Signed-off-by: Kevin Ullyott <kevin.ullyott@canyongbs.com> --------- Signed-off-by: Kevin Ullyott <kevin.ullyott@canyongbs.com>
1 parent 7214ae5 commit 9b22091

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

app-modules/service-management/src/Filament/Resources/ServiceRequests/Pages/ListServiceRequests.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function table(Table $table): Table
8181
'latestInboundServiceRequestUpdate',
8282
'latestOutboundServiceRequestUpdate',
8383
'priority.sla',
84-
'priority.type.managerUsers',
84+
'assignedTo.user',
8585
'respondent.organization',
8686
'feedback',
8787
'status',

resources/views/filament/tables/columns/service-request/related-to.blade.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
3737
$record = $getRecord();
3838
39-
$managers = $record->priority?->type?->managerUsers ?? collect();
39+
$assignedUser = $record->assignedTo?->user;
4040
4141
$respondent = $record->respondent;
4242
$customerName = $respondent?->{Contact::displayNameKey()};
@@ -46,10 +46,10 @@
4646
<div class="fi-ta-text grid w-full gap-y-1 text-sm text-gray-950 dark:text-white">
4747
<div class="flex flex-wrap items-center gap-x-2">
4848
<span class="font-medium">Manager:</span>
49-
@if ($managers->isEmpty())
49+
@if (! $assignedUser)
5050
<x-filament::badge color="gray">Unassigned</x-filament::badge>
5151
@else
52-
<span>{{ $managers->pluck("name")->join(", ") }}</span>
52+
<span>{{ $assignedUser->name }}</span>
5353
@endif
5454
</div>
5555

0 commit comments

Comments
 (0)