如何使用渲染列输入字段从extjs网格发送表单数据

时间:2015-07-31 13:01:46

标签: javascript extjs

我有一个ExtJs表格面板

{
    xtype: 'form',
    items: [{
        xtype: 'grid',
        forceFit: true,
        selType: 'checkboxmodel',
        collapsible: true,
        store: duplicateDataStore,
        title: 'Data (' + duplicateDataStore.getCount() + ')',
        columns: [
            this.getRadioButton()
        ]
    }]
}

...

getRadioButton: function() {
    return {
        header: 'name',
        hideable: false,
        renderer: this.renderRadioBox,
        formBind: true
    };
},

renderRadioBox: function( val, meta, record, rowIndex, colIndex, store ) {
    return '<input type="checkbox" id="checkbox" role="checkbox" name="test" value="1" >';
},

点击提交按钮后,我选择当前的表格值。

this.lookupReference( 'data' ).down( 'form' ).getForm().getValues();

但是我无法从这个选择中获得任何数据。当我向表单添加checkbox-item时,数据将是可读的,但不是来自网格列。

有解决方案吗?

0 个答案:

没有答案
相关问题