In Rally, is it possible to dynamically change script source so that I can load multiple apps?

38 Views Asked by At

I would like to have a drop down of app Names (or url parameter) and load the app on select: Something like:

Ext.define('TestPage', {
    extend: 'Rally.app.App',
    items: [{
        xtype: 'container',
        id: "appDiv"
    }],
    launch: function () {
        var me = this;
        me.add({
            xtype: 'box',
            autoEl: {
                tag: 'iframe',
                src: 'https://rally-apps.com/Test.CFD.html',
                width: 1020,
                height: 1000
            }
        });
    }

}); 

But I get error: Blocked a frame with origin https://rally-apps.com" from accessing a cross-origin frame. Is there any other way I can achieve this?

1

There are 1 best solutions below

0
Kyle Morse On

That error is a standard browser security limitation, where code in one domain cannot access code in another one. You may be able to work around it by instead making an ajax request to that url to load the app content and then injecting it into your current app. Hard to say.

The other idea that comes to mind is just adding these apps to your subscription app catalog, so anyone can add them to any pages they like...