Advertisement
Guest User

Untitled

a guest
Jan 20th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.63 KB | None | 0 0
  1. $(document).ready(function() {
  2.  
  3. var table = $('#example').DataTable( {
  4.  
  5.  
  6. ///Se adicionar botões exportar não aparecem
  7. columns: [
  8. null,
  9. null,
  10. null,
  11. null,
  12. null,
  13. {
  14. render: function(data, type, row){
  15. return data.split(", ").join("<br/>");
  16. }
  17. }
  18. ],
  19. ///Se adicionar botões exportar não aparecem
  20.  
  21.  
  22. lengthChange: false,
  23. buttons: [
  24.  
  25.  
  26. {
  27. extend: 'copy',
  28. text: 'Copiar'
  29. },
  30. {
  31. extend: 'print',
  32. text: 'Imprimir',
  33. message: '<?php echo $TextoArquivoExport;?>',
  34. },
  35. {
  36. extend: 'excelHtml5',
  37. title: '<?php echo $NomeArquivoExport;?>'
  38. },
  39. {
  40. extend: 'pdfHtml5',
  41. orientation: 'landscape',
  42. pageSize: 'LEGAL',
  43. fieldSeparator: 't',
  44. message: '<?php echo $TextoArquivoExport;?>',
  45. title: '<?php echo $NomeArquivoExport;?>',
  46. exportOptions: {
  47. stripNewlines: false
  48. }
  49. },
  50. {
  51. extend: 'colvis',
  52. text: 'Exibir/Ocultar Coluna'
  53. }
  54.  
  55. ],
  56.  
  57. language: {
  58. buttons: {
  59. copyTitle: 'Informações do relatório copiadas',
  60. copyKeys: 'Foram copiados <i>ctrl</i> ou <i>u2318</i> + <i>C</i> registros. <br><br>Por favor, pressione o botão ESC para sair.',
  61. copySuccess: {
  62. _: '%d registros copiados',
  63. 1: '1 linha copiada'
  64. }
  65. }
  66. }
  67.  
  68. } );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement