fix: field about time type (#92)

This commit is contained in:
junwen-lee 2025-07-28 00:36:14 +08:00 committed by GitHub
parent f294e19af5
commit 033df3f8ee
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 5 additions and 4 deletions

View File

@ -140,7 +140,7 @@ func (c *ConversationApplicationService) CreateConversation(ctx context.Context,
Id: conversationData.ID, Id: conversationData.ID,
LastSectionID: &conversationData.SectionID, LastSectionID: &conversationData.SectionID,
ConnectorID: &conversationData.ConnectorID, ConnectorID: &conversationData.ConnectorID,
CreatedAt: conversationData.CreatedAt, CreatedAt: conversationData.CreatedAt / 1000,
} }
return resp, nil return resp, nil
} }
@ -176,7 +176,7 @@ func (c *ConversationApplicationService) ListConversation(ctx context.Context, r
Id: conv.ID, Id: conv.ID,
LastSectionID: &conv.SectionID, LastSectionID: &conv.SectionID,
ConnectorID: &conv.ConnectorID, ConnectorID: &conv.ConnectorID,
CreatedAt: conv.CreatedAt, CreatedAt: conv.CreatedAt / 1000,
} }
}) })

View File

@ -299,6 +299,7 @@ func buildARSM2ApiMessage(chunk *entity.AgentRunResponse) []byte {
MetaData: chunkMessageItem.Ext, MetaData: chunkMessageItem.Ext,
ChatID: strconv.FormatInt(chunkMessageItem.RunID, 10), ChatID: strconv.FormatInt(chunkMessageItem.RunID, 10),
ReasoningContent: chunkMessageItem.ReasoningContent, ReasoningContent: chunkMessageItem.ReasoningContent,
CreatedAt: ptr.Of(chunkMessageItem.CreatedAt / 1000),
} }
mCM, _ := json.Marshal(chunkMessage) mCM, _ := json.Marshal(chunkMessage)

View File

@ -110,8 +110,8 @@ func (m *OpenapiMessageApplication) buildMessageListResponse(ctx context.Context
Content: content, Content: content,
ContentType: string(dm.ContentType), ContentType: string(dm.ContentType),
SectionID: strconv.FormatInt(dm.SectionID, 10), SectionID: strconv.FormatInt(dm.SectionID, 10),
CreatedAt: dm.CreatedAt, CreatedAt: dm.CreatedAt / 1000,
UpdatedAt: dm.UpdatedAt, UpdatedAt: dm.UpdatedAt / 1000,
ChatID: dm.RunID, ChatID: dm.RunID,
MetaData: dm.Ext, MetaData: dm.Ext,
} }