:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
feat(conversations): include ticket ID in ticket-detail tab title (#71044)
Xander0cf6919a9f53
diff --git a/products/conversations/frontend/scenes/ticket/SupportTicketScene.tsx b/products/conversations/frontend/scenes/ticket/SupportTicketScene.tsxindex e6011f97414e..5be0c7166bd2 100644--- a/products/conversations/frontend/scenes/ticket/SupportTicketScene.tsx+++ b/products/conversations/frontend/scenes/ticket/SupportTicketScene.tsx@@ -43,11 +43,11 @@ import { StaffActionsPanel } from './StaffActionsPanel'import { supportTicketSceneLogic } from './supportTicketSceneLogic'import { TicketActivityPanel } from './TicketActivityPanel'-export const scene: SceneExport<{ ticketId: string }> = {+export const scene: SceneExport<{ ticketId: string; id: string }> = {component: SupportTicketScene,logic: supportTicketSceneLogic,productKey: ProductKey.CONVERSATIONS,- paramsToProps: ({ params: { ticketId } }) => ({ ticketId: ticketId || 'new' }),+ paramsToProps: ({ params: { ticketId } }) => ({ ticketId, id: ticketId || 'new' }),}// Builds a deep link to the originating Slack thread so the Channel tag can be clickable.diff --git a/products/conversations/frontend/scenes/ticket/supportTicketSceneLogic.ts b/products/conversations/frontend/scenes/ticket/supportTicketSceneLogic.tsindex dd1dd0719b08..8ffdca1f8b19 100644--- a/products/conversations/frontend/scenes/ticket/supportTicketSceneLogic.ts+++ b/products/conversations/frontend/scenes/ticket/supportTicketSceneLogic.ts@@ -7,6 +7,7 @@ import { lemonToast } from '@posthog/lemon-ui'import { dayjs } from 'lib/dayjs'import { getCurrentTeamId } from 'lib/utils/getAppContext'+import { isUUIDLike } from 'lib/utils/guards'import { teamLogic } from 'scenes/teamLogic'import { urls } from 'scenes/urls'@@ -16,7 +17,7 @@ import { PERSON_DISPLAY_NAME_COLUMN_NAME } from '~/lib/constants'import { CLOUD_HOSTNAMES } from '~/lib/constants'import { defaultDataTableColumns } from '~/queries/nodes/DataTable/utils'import { DataTableNode, NodeKind } from '~/queries/schema/schema-general'-import type { CommentType, PersonType } from '~/types'+import type { Breadcrumb, CommentType, PersonType } from '~/types'import { PropertyFilterType, PropertyOperator, Region } from '~/types'import {@@ -405,6 +406,21 @@ export const supportTicketSceneLogic = kea<supportTicketSceneLogicType>([],}),selectors({+ breadcrumbs: [+ (_, p) => [p.id],+ (id): Breadcrumb[] => {+ let name: string+ if (id === 'new') {+ name = 'New ticket'+ } else if (typeof id === 'string' && isUUIDLike(id)) {+ // Legacy UUID URLs: show the first segment without a # (which implies a number)+ name = `Ticket ${id.split('-')[0]}`+ } else {+ name = `Ticket #${id}`+ }+ return [{ key: ['SupportTicketDetail', id], name }]+ },+ ],emailReplyBlockedReason: [(s) => [s.ticket, s.currentTeam],(ticket, currentTeam): EmailReplyBlockedReason | null =>