mirror of
https://github.com/lingble/chatwoot.git
synced 2025-11-03 04:27:53 +00:00
fix: Add missing timestamp in the real-time event (#6349)
* fix: Add missing timestamp in the real-time event * Fix broken specs
This commit is contained in:
@@ -38,7 +38,8 @@ class Conversations::EventDataPresenter < SimpleDelegator
|
|||||||
{
|
{
|
||||||
agent_last_seen_at: agent_last_seen_at.to_i,
|
agent_last_seen_at: agent_last_seen_at.to_i,
|
||||||
contact_last_seen_at: contact_last_seen_at.to_i,
|
contact_last_seen_at: contact_last_seen_at.to_i,
|
||||||
timestamp: last_activity_at.to_i
|
timestamp: last_activity_at.to_i,
|
||||||
|
created_at: created_at.to_i
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -458,6 +458,7 @@ RSpec.describe Conversation, type: :model do
|
|||||||
first_reply_created_at: nil,
|
first_reply_created_at: nil,
|
||||||
contact_last_seen_at: conversation.contact_last_seen_at.to_i,
|
contact_last_seen_at: conversation.contact_last_seen_at.to_i,
|
||||||
agent_last_seen_at: conversation.agent_last_seen_at.to_i,
|
agent_last_seen_at: conversation.agent_last_seen_at.to_i,
|
||||||
|
created_at: conversation.created_at.to_i,
|
||||||
unread_count: 0
|
unread_count: 0
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ RSpec.describe Conversations::EventDataPresenter do
|
|||||||
first_reply_created_at: nil,
|
first_reply_created_at: nil,
|
||||||
contact_last_seen_at: conversation.contact_last_seen_at.to_i,
|
contact_last_seen_at: conversation.contact_last_seen_at.to_i,
|
||||||
agent_last_seen_at: conversation.agent_last_seen_at.to_i,
|
agent_last_seen_at: conversation.agent_last_seen_at.to_i,
|
||||||
|
created_at: conversation.created_at.to_i,
|
||||||
unread_count: 0
|
unread_count: 0
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user