diff --git a/web/src/app/tickets/[id]/page.tsx b/web/src/app/tickets/[id]/page.tsx index cca6c51..407d8a4 100644 --- a/web/src/app/tickets/[id]/page.tsx +++ b/web/src/app/tickets/[id]/page.tsx @@ -104,10 +104,12 @@ function userLabel(users: User[], userId: string | null) { function TransactionCard({ tx, users, + teams, customFieldLabels, }: { tx: Transaction; users: User[]; + teams: Team[]; customFieldLabels: Record; }) { const isSystem = @@ -134,7 +136,8 @@ function TransactionCard({ } else if (tx.transaction_type === "SetOwner") { message = tx.new_value ? `Assigned to ${userLabel(users, tx.new_value)}` : "Unassigned"; } else if (tx.transaction_type === "SetTeam") { - message = "Team changed"; + const teamName = tx.new_value ? (teams.find((t) => t.id === tx.new_value)?.name ?? "?") : null; + message = teamName ? `Team → ${teamName}` : "Team cleared"; } else if (tx.transaction_type === "CustomFieldChange") { const fieldName = tx.field ? customFieldLabels[tx.field] ?? "Custom field" : "Custom field"; message = tx.new_value ? `${fieldName} set to ${tx.new_value}` : `${fieldName} cleared`; @@ -664,6 +667,7 @@ export default function TicketDetailPage({ key={tx.id} tx={tx} users={users} + teams={teams} customFieldLabels={customFieldLabels} /> ))}