select_os.xml 1.2KB

1234567891011121314151617181920212223242526272829303132333435
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <dt-example table-type="html" order="1">
  3. <css lib="datatables tabletools" />
  4. <js lib="jquery datatables tabletools">
  5. <![CDATA[
  6. $(document).ready(function() {
  7. $('#example').DataTable( {
  8. dom: 'T<"clear">lfrtip',
  9. tableTools: {
  10. "sRowSelect": "os",
  11. "aButtons": [ "select_all", "select_none" ]
  12. }
  13. } );
  14. } );
  15. ]]>
  16. </js>
  17. <title lib="TableTools">Row selection - operating system style</title>
  18. <info><![CDATA[
  19. As well as providing a button toolbar, TableTools provides everything needed to have selectable rows in the table. TableTools has four row selection modes of operation:
  20. * `none` - Default, where no user row selection options are available
  21. * `single` - A single row can be selected
  22. * `multi` - Multiple rows can be selected simply by clicking on the rows
  23. * `os` - Operating System like selection where you can use the shift and ctrl / cmd keys on your keyboard to add / remove rows from the selection.
  24. This example shows the `os` select option. Without keyboard interaction a single row can be selected at a time, but multiple rows can be selected in a range using the shift key, while rows can be added and removed from the selection using the ctrl / cmd key.
  25. ]]></info>
  26. </dt-example>