mirror of https://github.com/ColorlibHQ/gentelella
37 lines
1.0 KiB
XML
Executable File
37 lines
1.0 KiB
XML
Executable File
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<dt-example table-type="html" order="1">
|
|
|
|
<css lib="datatables tabletools" />
|
|
<js lib="jquery datatables tabletools">
|
|
<![CDATA[
|
|
$(document).ready(function() {
|
|
$('#example').DataTable( {
|
|
"dom": 'T<"clear">lfrtip',
|
|
"tableTools": {
|
|
"aButtons": [
|
|
"copy",
|
|
"print",
|
|
{
|
|
"sExtends": "collection",
|
|
"sButtonText": "Save",
|
|
"aButtons": [ "csv", "xls", "pdf" ]
|
|
}
|
|
]
|
|
}
|
|
} );
|
|
} );
|
|
]]>
|
|
</js>
|
|
|
|
<title lib="TableTools">Button collections</title>
|
|
|
|
<info><![CDATA[
|
|
|
|
TableTools provides the ability to group buttons into a hidden drop down list, which is activated by clicking on a top-level button. This is achieved by extending the 'collection' predefined button type and setting it's `aButtons` parameter with the same options as the top level buttons (note that you cannot currently use a collection within a collection).
|
|
|
|
The example below shows the file save buttons grouped into a collection, while the copy and print buttons are left on the top level.
|
|
|
|
]]></info>
|
|
|
|
</dt-example>
|