feat: Allow Dashboard App Frames to query the information (#5313)
Co-authored-by: Fayaz Ahmed <15716057+fayazara@users.noreply.github.com>
This commit is contained in:
parent
f33ff351cf
commit
bef3f66501
1 changed files with 12 additions and 0 deletions
|
@ -38,6 +38,18 @@ export default {
|
|||
return this.currentChat?.meta?.sender?.id;
|
||||
},
|
||||
},
|
||||
|
||||
mounted() {
|
||||
window.onmessage = e => {
|
||||
if (
|
||||
typeof e.data !== 'string' ||
|
||||
e.data !== 'chatwoot-dashboard-app:fetch-info'
|
||||
) {
|
||||
return;
|
||||
}
|
||||
this.onIframeLoad(0);
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
onIframeLoad(index) {
|
||||
const frameElement = document.getElementById(
|
||||
|
|
Loading…
Reference in a new issue