feat: navigate from customer to chat

This commit is contained in:
Vlad Stan 2023-03-29 16:38:12 +03:00
parent 5ed77e68c4
commit 08e71e28e3
2 changed files with 6 additions and 2 deletions

View file

@ -2,10 +2,13 @@ async function directMessages(path) {
const template = await loadTemplateAsync(path) const template = await loadTemplateAsync(path)
Vue.component('direct-messages', { Vue.component('direct-messages', {
name: 'direct-messages', name: 'direct-messages',
props: ['adminkey', 'inkey'], props: ['active-chat-customer', 'adminkey', 'inkey'],
template, template,
watch: { watch: {
activeChatCustomer: async function (n) {
this.activePublicKey = n
},
activePublicKey: async function (n) { activePublicKey: async function (n) {
await this.getDirectMessages(n) await this.getDirectMessages(n)
} }

View file

@ -148,8 +148,9 @@
<direct-messages <direct-messages
:inkey="g.user.wallets[0].inkey" :inkey="g.user.wallets[0].inkey"
:adminkey="g.user.wallets[0].adminkey" :adminkey="g.user.wallets[0].adminkey"
:active-chat-customer="activeChatCustomer"
> >
<!-- :active-public-key="activeChatCustomer" -->
</direct-messages> </direct-messages>
</div> </div>
</div> </div>