jquery easyui checkbox 显示表头

The code is like this:

function initDatagrid()
{
   $('#tools').datagrid({
    title: 'All Tool Configurations',
    url: '@Url.Action("GetTools","SystemConfiguration")',
    width: '800',
    height: 'auto',
    pagination: true,
    rownumbers: true,
    fitColumns: true,
    selectOnCheck: false,
    checkOnSelect: false,
    columns: [[
                { field: 'ToolName', title: 'Name', width: 80, editor: 'text', align: 'center' },
                {field:'Obsolete',title:'Obsolete',width:100,formatter: function(value,row,index){
                    
                    if(row.Obsolete)
                    {
                        return '<input type="checkbox" checked="checked"/>';
                    }
                    else
                    {
                        return '<input type="checkbox"/>';
                    }
                }}
             ]],
   toolbar: [。。。。

 出处:http://blog.csdn.net/baronyang/article/details/9323463

posted @ 2014-09-29 14:41  邹邹  Views(519)  Comments(0Edit  收藏  举报