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:
Nithin David Thomas
2021-02-13 14:58:05 +05:30
committed by GitHub
parent 8d45849d0c
commit eaafc45f45
12 changed files with 110 additions and 4 deletions

View File

@@ -80,6 +80,10 @@ export default {
type: String,
default: '',
},
activeTeam: {
type: Object,
default: () => {},
},
},
data() {
return {
@@ -128,12 +132,16 @@ export default {
status: this.activeStatus,
page: this.currentPage + 1,
labels: this.label ? [this.label] : undefined,
teamId: this.activeTeam.name ? this.activeTeam.id : undefined,
};
},
pageTitle() {
if (this.inbox.name) {
return this.inbox.name;
}
if (this.activeTeam.name) {
return this.activeTeam.name;
}
if (this.label) {
return `#${this.label}`;
}
@@ -162,6 +170,9 @@ export default {
},
},
watch: {
activeTeam() {
this.resetAndFetchData();
},
conversationInbox() {
this.resetAndFetchData();
},