数据表在标题上显示双顺序图标

Mar*_*rta 2 twitter-bootstrap-3 datatables-1.10

我正在使用带有引导程序的数据表使用此说明创建一个简单的表

var bTable = $('#example2').DataTable( {
        language: {  url: 'assets/plugins/datatables/i18n/Spanish.json'     },
        processing: true,
        fixedHeader: true,
        serverSide: true,
        responsive:true,
        ajax: "modulos/estados.data.php",
        columns: [
            { data: "id561" },
            { data: "des561" },
            { data: "accion561" },
            { data: "res561" }
        ],
        order: [[ 1, "asc" ]],
        columnDefs: [
            {
                targets : 0,
                searchable: false,
                render: function ( data, type, row ) 
                { return row.id561 }
            },
            {
                targets : 1,
                searchable: true,
                render: function ( data, type, row ) 
                { return data }
            },
            {
                targets : 2,
                searchable: false,
                render: function ( data, type, row ) 
                { return data }
            },
            {
                targets : 3,
                orderable: false,
                searchable: false,
                render: function ( data, type, row ) 
                { return data }
            }
        ]
    } );
Run Code Online (Sandbox Code Playgroud)

问题是它在标题上显示订单图标两次,如图所示 在此处输入图片说明

问题只是激活 Bootstrap css,如果我使用 jquery 它的作品

感谢帮助!

Gyr*_*com 5

确保您不包含 DataTables CSS 文件 ( jquery.dataTables.min.css),只包含dataTables.bootstrap.min.css.

如果您使用的是Download Builder,请在样式部分中选择Bootstrap。如果您已经包含 Bootstrap,请选择No style library,否则选择Include library以包含最新的 Bootstrap 。

有关正确用法的演示,请参阅此示例