0

如果我有一个 PortfolioItems 的拉力网格,并且在列配置中包含 PercentDoneByStoryPlanEstimate,我会按预期获得进度条。但是,当我将鼠标悬停在进度条上时,我看不到带有我在 Rally 本身中看到的额外信息的工具提示。

如何让工具提示显示在应用程序中?

示例代码:

    Rally.onReady(function() {
        Ext.define('CustomApp', {
            extend: 'Rally.app.App',
            componentCls: 'app',

            launch: function() {
                Rally.data.ModelFactory.getModel({
                    type: 'PortfolioItem',
                    success: function(model) {
                        this.grid = this.add({
                            xtype: 'rallygrid',
                            model: model,
                            columnCfgs: [
                                'FormattedID',
                                'Name',
                                'PercentDoneByStoryPlanEstimate'
                            ]
                        });
                    },
                    scope: this
                });
            }
        });

        Rally.launchApp('CustomApp', {
            name: 'Grid Example'
        });
    });
4

1 回答 1

0

您只需要指定一个 viewConfig 并添加 'rallypercentdonetooltip' 插件,如下所示:

success: function(model) {
    this.grid = this.add({
        xtype: 'rallygrid',
        model: model,
        columnCfgs: [
            'Name',
            'FormattedID',
            'PercentDoneByStoryPlanEstimate'
        ],
        viewConfig:{
            plugins:[
                {ptype:'rallypercentdonetooltip'}
            ]
        }
    });
于 2012-07-11T22:54:27.320 回答