繁体   English   中英

ExtJs 3:如何根据用户网格存储值动态更新网格单元工具提示?

[英]ExtJs 3: How to dynamically update grid cell tool tip based on user grid store value?

我的工具提示功能如下

function renderTip(val, meta, rec, rowIndex, colIndex, store) {
    // meta.tdCls = 'cell-icon'; // icon
    metadata.attr = 'ext:qtip="rec.get('ERROR')"; ext:qclass="maint-usg-data-tip-error"';
    return val;
};

我在下面的网格列中添加到工具提示

     initComponent: function() {
        colDesc = this.grid.getColumnModel().getColumnById('grid_col_id');
        colDesc.renderer  = this.addToolTip;
     }

Ext.onReady(function() {
 Ext.QuickTips.init(); 
});

当更新我的一行表格可编辑网格时,该网格存储错误值更新(更改)。 但这不会更新我的工具提示值( rec.get('ERROR') )。 当我在网格更新后(在编辑一些行单元格之后)重新加载网格存储时,该工具提示将更新为新值。

如何在不重新加载网格存储的情况下将更新存储值呈现到网格工具提示?

尝试使用grid.getView()。refresh();

暂无
暂无

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

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