fix: Use last_activity_at instead of updated_at for sorting (#1281)
Co-authored-by: Akash Srivastava <akash.srivastava.1911@gmail.com>
This commit is contained in:
@@ -11,7 +11,7 @@ json.data do
|
||||
json.status conversation.status
|
||||
json.muted conversation.muted?
|
||||
json.can_reply conversation.can_reply?
|
||||
json.timestamp conversation.messages.last.try(:created_at).try(:to_i)
|
||||
json.timestamp conversation.last_activity_at.to_i
|
||||
json.contact_last_seen_at conversation.contact_last_seen_at.to_i
|
||||
json.agent_last_seen_at conversation.agent_last_seen_at.to_i
|
||||
json.additional_attributes conversation.additional_attributes
|
||||
|
||||
@@ -21,7 +21,7 @@ json.inbox_id conversation.inbox_id
|
||||
json.status conversation.status
|
||||
json.muted conversation.muted?
|
||||
json.can_reply conversation.can_reply?
|
||||
json.timestamp conversation.messages.last.try(:created_at).try(:to_i)
|
||||
json.timestamp conversation.last_activity_at.to_i
|
||||
json.contact_last_seen_at conversation.contact_last_seen_at.to_i
|
||||
json.agent_last_seen_at conversation.agent_last_seen_at.to_i
|
||||
json.unread_count conversation.unread_incoming_messages.count
|
||||
|
||||
Reference in New Issue
Block a user