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:
@@ -38,6 +38,18 @@ export default {
|
|||||||
return this.currentChat?.meta?.sender?.id;
|
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: {
|
methods: {
|
||||||
onIframeLoad(index) {
|
onIframeLoad(index) {
|
||||||
const frameElement = document.getElementById(
|
const frameElement = document.getElementById(
|
||||||
|
|||||||
Reference in New Issue
Block a user