mirror of
https://github.com/lingble/chatwoot.git
synced 2025-11-01 11:37:58 +00:00
chore: Message API improvements (#2396)
Co-authored-by: Pranav Raj S <pranav@chatwoot.com>
This commit is contained in:
@@ -152,7 +152,10 @@ export default {
|
||||
return !messageType ? 'left' : 'right';
|
||||
},
|
||||
readableTime() {
|
||||
return this.messageStamp(this.data.created_at, 'LLL d, h:mm a');
|
||||
return this.messageStamp(
|
||||
this.contentAttributes.external_created_at || this.data.created_at,
|
||||
'LLL d, h:mm a'
|
||||
);
|
||||
},
|
||||
isBubble() {
|
||||
return [0, 1, 3].includes(this.data.message_type);
|
||||
@@ -205,7 +208,7 @@ export default {
|
||||
},
|
||||
isSentByBot() {
|
||||
if (this.isPending) return false;
|
||||
return !this.sender.type || this.sender.type === 'bot';
|
||||
return !this.sender.type || this.sender.type === 'agent_bot';
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user