feat: Show teams on sidebar (#1754)
Co-authored-by: Pranav Raj S <pranav@chatwoot.com> Co-authored-by: Sojan <sojan@pepalo.com>
This commit is contained in:
committed by
GitHub
parent
8d45849d0c
commit
eaafc45f45
@@ -3,6 +3,7 @@
|
||||
<chat-list
|
||||
:conversation-inbox="inboxId"
|
||||
:label="label"
|
||||
:active-team="activeTeam"
|
||||
@conversation-load="onConversationLoad"
|
||||
>
|
||||
<button class="search--button" @click="onSearch">
|
||||
@@ -61,6 +62,10 @@ export default {
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
teamId: {
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@@ -81,6 +86,12 @@ export default {
|
||||
}
|
||||
return false;
|
||||
},
|
||||
activeTeam() {
|
||||
if (this.teamId) {
|
||||
return this.$store.getters['teams/getTeam'](this.teamId);
|
||||
}
|
||||
return {};
|
||||
},
|
||||
},
|
||||
|
||||
mounted() {
|
||||
|
||||
@@ -64,5 +64,24 @@ export default {
|
||||
label: route.params.label,
|
||||
}),
|
||||
},
|
||||
{
|
||||
path: frontendURL('accounts/:accountId/team/:teamId'),
|
||||
name: 'team_conversations',
|
||||
roles: ['administrator', 'agent'],
|
||||
component: ConversationView,
|
||||
props: route => ({ teamId: route.params.teamId }),
|
||||
},
|
||||
{
|
||||
path: frontendURL(
|
||||
'accounts/:accountId/team/:teamId/conversations/:conversationId'
|
||||
),
|
||||
name: 'conversations_through_team',
|
||||
roles: ['administrator', 'agent'],
|
||||
component: ConversationView,
|
||||
props: route => ({
|
||||
conversationId: route.params.conversationId,
|
||||
teamId: route.params.teamId,
|
||||
}),
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user