`

Pentaho Ctools to change CDEdashboard tooltip

阅读更多

 

 

 

to change CDEdashboard tooltip, add this function in to Post Fetch.

 

function f(data) {

    // Configure the category dimension
    // See http://webdetails.github.io/ccc/charts/jsdoc/symbols/pvc.options.charts.Chart.html#dimensions
    this.chartDefinition.dimensions = {
        series:   {
            label: '题号'
            // , isHidden: true
        },
        category: {
            label: '分数段'
            , valueType: Number
            // , format: '0.00%' 如果值需要转为百分比,或者使用formatter
            // , formatter: function(v) { return Utils.numberFormat(v, '0.00%'); } // extract month, remove zero-prefix, if any
        },
        value:    {
            label: '值'
        }
        
    };

    return data;
} 

 

如果出现 Utils 未定义,则添加如下:

 

Add Resource

 

Resource Type             Resource Source 

Javascript                Code Snippet

window.Utils = Utils

 

 

Base Axis Tick Formatter

function f(v) {
    return Utils.numberFormat(v, '0.00%');
}

 

 

...

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics