feat: Add Instagram Channel (#2955)
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
<thumbnail
|
||||
v-if="!hideThumbnail"
|
||||
:src="currentContact.thumbnail"
|
||||
:badge="inboxBadge"
|
||||
:badge="chatBadge"
|
||||
class="columns"
|
||||
:username="currentContact.name"
|
||||
:status="currentContact.availability_status"
|
||||
@@ -119,6 +119,10 @@ export default {
|
||||
accountId: 'getCurrentAccountId',
|
||||
}),
|
||||
|
||||
chatExtraAttributes() {
|
||||
return this.chat.additional_attributes;
|
||||
},
|
||||
|
||||
chatMetadata() {
|
||||
return this.chat.meta || {};
|
||||
},
|
||||
@@ -127,6 +131,14 @@ export default {
|
||||
return this.chatMetadata.assignee || {};
|
||||
},
|
||||
|
||||
chatBadge() {
|
||||
if(this.chatExtraAttributes['type']){
|
||||
return this.chatExtraAttributes['type']
|
||||
} else {
|
||||
return this.chatMetadata.channel
|
||||
}
|
||||
},
|
||||
|
||||
currentContact() {
|
||||
return this.$store.getters['contacts/getContact'](
|
||||
this.chatMetadata.sender.id
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<Thumbnail
|
||||
:src="currentContact.thumbnail"
|
||||
size="40px"
|
||||
:badge="inboxBadge"
|
||||
:badge="chatBadge"
|
||||
:username="currentContact.name"
|
||||
:status="currentContact.availability_status"
|
||||
/>
|
||||
@@ -73,9 +73,23 @@ export default {
|
||||
uiFlags: 'inboxAssignableAgents/getUIFlags',
|
||||
currentChat: 'getSelectedChat',
|
||||
}),
|
||||
|
||||
chatExtraAttributes() {
|
||||
return this.chat.additional_attributes;
|
||||
},
|
||||
|
||||
chatMetadata() {
|
||||
return this.chat.meta;
|
||||
},
|
||||
|
||||
chatBadge() {
|
||||
if(this.chatExtraAttributes['type']){
|
||||
return this.chatExtraAttributes['type']
|
||||
} else {
|
||||
return this.chatMetadata.channel
|
||||
}
|
||||
},
|
||||
|
||||
currentContact() {
|
||||
return this.$store.getters['contacts/getContact'](
|
||||
this.chat.meta.sender.id
|
||||
|
||||
Reference in New Issue
Block a user