0
$("#rfqDetails").flexigrid({
        dataType: 'json',
        colModel: [
         { display: 'checkbox', name: '', width: 30, align: 'center' },
         { display: 'RfqNo', name: 'RfqNo', width: 80, sortable: false, align: 'center' },
         { display: 'PreferredSupplier', name: 'PreferredSupplier', width: 100, sortable: false, align: 'center' },
         { display: 'Status', name: 'Status', width: 80, sortable: false, align: 'center' },
         { display: 'Company', name: 'Company', width: 80, sortable: false, align: 'center' },
         { display: 'Edit', name: '', width: 80, sortable: false, align: 'center' },
         { display: 'View', name: '', width: 80, sortable: false, align: 'center' },
        ],
        title: "RFQ Summary",
        height: 320,
        showToggleBtn: false,
        singleSelect: false,
        resizable: false
    });


$('#rfqDetails').click(function ()
{
    var selected = $('#rfqDetails .trSelected td:eq(0)');

    $(selected).each(function ()
    {
        selected.attr('checked', 'checked')
    });
});

以上是我的flexigrid代码。在第一列中,我通过选择必须选择复选框的行来获得复选框,并且在取消选择行时,复选框必须取消选择。

4

0 回答 0