繁体   English   中英

Rally Grid中的拖放问题

[英]Drag and Drop issue in Rally Grid

我最近实施的Rally Grid中有一个问题。

_CreatePSIObjectiveGrid: function(myStore) {
    if (!this.objGrid) {
        var colCfgs = [{
            text: 'ID',
            dataIndex: 'DragAndDropRank',
            width: 50
        }, {
            text: 'Summary',
            dataIndex: 'Name',
            flex: 1
        }, {
            text: 'Success Rate',
            dataIndex: 'c_SuccessRate',
            width: 200
        }];

        if (!this.getSetting("useSuccessRatioOnly")) {
            colCfgs.push({
                text: 'Initial Business Value',
                dataIndex: 'PlanEstimate',
                width: 200
            });

            colCfgs.push({
                text: 'Final Business Value',
                dataIndex: 'c_FinalValue',
                width: 200
            });
        }

        this.objGrid = Ext.create('Rally.ui.grid.Grid', {
            store : myStore,
            enableRanking: true,
            defaultSortToRank: true,
            height: 550,
            overflowY: 'auto',
            margin: 10,
            showPagingToolbar: false,
            columnCfgs : colCfgs
        });

        Ext.getCmp('c-panel-obj-crud-table').add(this.objGrid);
    }
}

尽管我已将“ enableRanking”设置为“ true”,但是如果将网格添加到组件中,则排名拖放操作将无效。 但是,如果我将最后一条语句更改为

Ext.getCmp('c-panel-obj-crud-table').add(this.objGrid);

this.add(this.objGrid);

我不知道这是否是Rally错误。 尝试比较生成的最终html文件,没有发现任何线索。

这几秒钟的视频显示 ,下面的代码,其中一个rankable网添加到子面板,而不是直接到thisthis指向应用程序的全局范围)仍然保留其重新排名的能力:

Ext.define('CustomApp', {
    extend: 'Rally.app.App',
    componentCls: 'app',
    launch: function() {
        var panel = Ext.create('Ext.panel.Panel', {
            layout: 'hbox',
            itemId: 'parentPanel',
            componentCls: 'panel',
            items: [
                {
                xtype: 'panel',
                title: 'Panel 1',
                width: 600,
                itemId: 'childPanel1'
                },
                {
                xtype: 'panel',
                title: 'Panel 2',
                width: 600,
                itemId: 'childPanel2'
                }
            ],
        });
        this.add(panel);
        this.down('#childPanel1').add({
            xtype: 'rallygrid',
            columnCfgs: [
                'FormattedID',
                'Name',
                'ScheduleState',
                'Owner'
            ],
            context: this.getContext(),
            enableRanking: true,
            defaultSortToRank: true,
            storeConfig: {
                model: 'userstory'
            }
        });
    }
});

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM