rallyappsdk2

Popups in rally grids: rallypercentdonepopoverplugin


I'm creating some rallygrids that show feature level portfolio items within a tab panel container within a accordion container.

Unfortunately there are problems if the rallygrid is hidden when the container is first rendered if I include the rallypercentdonepopoverplugin plugin:

  1. Using a tab panel, rallygrids in an inactive panel crash when they are rendered if they contain the rallypercentdonepopoverplugin and display a field that uses it.
  2. Using an accordion panel, if a grid is not open when it is first rendered (set 'collapsed: true' on the gridspec), the popup for % done does not display.

Is there perhaps a tricky way to get this to work, perhaps changing the timing on when objects are created?

My app requires are:

requires: [
    'Rally.data.util.Sorter',
    'Rally.data.wsapi.Filter',
    'Rally.ui.grid.Grid',
    'Rally.data.ModelFactory',
    'Rally.ui.grid.plugin.PercentDonePopoverPlugin'
],

The gridspec plugins include:

plugins: ['rallypercentdonepopoverplugin']

Other than that, at the low level just a pretty straight forward rallygrid showing feature level portfolio items, plus the boolean 'collapsed: true' if it is not supposed to open during render

And the following subroutines to layout the system of panels:

_createTabPanel: function() {
    var curAccord   = this._createAccordian('current');
    var pastAccord  = this._createAccordian('past');

    curAccord.title     = 'Upcoming Releases';
    pastAccord.title    = 'Previous Releases';

    var tabPanelSpec = {
        xtype: 'tabpanel',
        border: 0,
        forceFit: true,
        activeTab: 0,
        minTabWidth: 200,
        items: [curAccord, pastAccord]
    };

    return tabPanelSpec;
},

_createAccordian: function(displayType) {
    var gridSpecs   = this._getGridSpecs(displayType);

    var accordSpec  = {
        xtype: 'panel',
        layout: {
            type: 'accordion',
            expandedItem: false,
            animate: true,
        multi: true,
            activeOnTop: true
        },
        items: gridSpecs,
    };

    return accordSpec;
},

Solution

  • I replicated the problem with an app in this repo. When the grid with the rallypercentdonepopoverplugin is inside a panel inside accordion the popup does not work. Maybe there is a trick to make it work, but I submitted a bug.