refactor: remove ExternalSource and ExternalID from Conversation model and related services, update references to use ChannelID instead
This commit is contained in:
@@ -339,8 +339,8 @@ export function ConversationDetailDialog({
|
||||
value={currentConversation.currentAssigneeName || "-"}
|
||||
/>
|
||||
<InfoItem
|
||||
label="渠道类型"
|
||||
value={currentConversation.externalSource || "-"}
|
||||
label="渠道ID"
|
||||
value={`${currentConversation.channelId || "-"}`}
|
||||
/>
|
||||
<InfoItem
|
||||
label="客服未读"
|
||||
|
||||
@@ -726,7 +726,7 @@ export default function DashboardConversationsPage() {
|
||||
<div className="min-w-0">
|
||||
<div className="font-medium">{item.subject || `会话 #${item.id}`}</div>
|
||||
<div className="mt-1 text-sm text-muted-foreground">
|
||||
渠道:{item.externalSource || "-"}
|
||||
渠道ID:{item.channelId || "-"}
|
||||
</div>
|
||||
<div className="mt-1 line-clamp-2 text-sm text-muted-foreground">
|
||||
{item.lastMessageSummary || "暂无最新消息摘要"}
|
||||
|
||||
@@ -168,10 +168,10 @@ function MissingCustomerEmpty({ conversation }: { conversation: AgentConversatio
|
||||
</Button>
|
||||
</div>
|
||||
<div className="space-y-2">
|
||||
<SectionHeading>访客标识</SectionHeading>
|
||||
<SectionHeading>会话归属</SectionHeading>
|
||||
<div className="space-y-2">
|
||||
<DetailRow label="外部来源" value={conversation.externalSource} />
|
||||
<DetailRow label="外部标识" value={conversation.externalId} />
|
||||
<DetailRow label="渠道ID" value={conversation.channelId ? `${conversation.channelId}` : "-"} />
|
||||
<DetailRow label="客户ID" value={conversation.customerId ? `${conversation.customerId}` : "-"} />
|
||||
</div>
|
||||
</div>
|
||||
<CustomerLinkOrCreateDialog
|
||||
|
||||
@@ -101,12 +101,6 @@ export function ConversationList({ onAfterSelect }: ConversationListProps) {
|
||||
>
|
||||
{getEnumLabel(IMConversationStatusLabels, conversation.status)}
|
||||
</span>
|
||||
{conversation.externalSource ? (
|
||||
<>
|
||||
<span className="opacity-40">·</span>
|
||||
<span className="truncate">{conversation.externalSource}</span>
|
||||
</>
|
||||
) : null}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -292,9 +292,7 @@ export default function ConversationsPage() {
|
||||
</span>
|
||||
</div>
|
||||
<p className="mt-0.5 truncate text-xs text-muted-foreground sm:text-sm">
|
||||
<span>{conversation.externalSource}</span>
|
||||
<span className="text-muted-foreground/60"> / </span>
|
||||
<span>{conversation.externalId}</span>
|
||||
<span>渠道 #{conversation.channelId || "-"}</span>
|
||||
{conversation.customerId ? (
|
||||
<>
|
||||
<span className="text-muted-foreground/60"> / </span>
|
||||
|
||||
@@ -109,8 +109,6 @@ export type ConversationParticipant = {
|
||||
export type AdminConversation = {
|
||||
id: number
|
||||
channelId: number
|
||||
externalSource: string
|
||||
externalId: string
|
||||
subject: string
|
||||
status: number
|
||||
serviceMode: number
|
||||
|
||||
@@ -37,8 +37,6 @@ export type AgentConversation = {
|
||||
aiAgentId?: number
|
||||
channelId?: number
|
||||
customerId?: number
|
||||
externalSource: string
|
||||
externalId: string
|
||||
subject: string
|
||||
status: number
|
||||
serviceMode: number
|
||||
|
||||
@@ -34,8 +34,6 @@ export type ImConversationParticipant = {
|
||||
export type ImConversation = {
|
||||
id: number
|
||||
channelId: number
|
||||
externalSource: string
|
||||
externalId: string
|
||||
subject: string
|
||||
status: number
|
||||
serviceMode: number
|
||||
|
||||
Reference in New Issue
Block a user