|
Lines 816-821
function _dt_buttons(params) {
Link Here
|
| 816 |
}, |
816 |
}, |
| 817 |
}; |
817 |
}; |
| 818 |
|
818 |
|
|
|
819 |
const export_format_print = { |
| 820 |
body: function (data, row, column, node) { |
| 821 |
const newnode = node.cloneNode(true); |
| 822 |
const no_export_nodes = newnode.querySelectorAll(".no-export"); |
| 823 |
no_export_nodes.forEach(child => { |
| 824 |
child.parentNode.removeChild(child); |
| 825 |
}); |
| 826 |
//Note: innerHTML is the same thing as the data variable, |
| 827 |
//minus the ".no-export" nodes that we've removed |
| 828 |
//Note: See dataTables.buttons.js for original function usage |
| 829 |
const str = DataTable.Buttons.stripData(newnode.innerHTML, { |
| 830 |
decodeEntities: false, |
| 831 |
stripHtml: true, |
| 832 |
stripNewlines: true, |
| 833 |
trim: true, |
| 834 |
}); |
| 835 |
return str; |
| 836 |
}, |
| 837 |
}; |
| 838 |
|
| 819 |
var export_format = { |
839 |
var export_format = { |
| 820 |
body: function (data, row, column, node) { |
840 |
body: function (data, row, column, node) { |
| 821 |
var newnode = $(node); |
841 |
var newnode = $(node); |
|
Lines 855-861
function _dt_buttons(params) {
Link Here
|
| 855 |
extend: "print", |
875 |
extend: "print", |
| 856 |
exportOptions: { |
876 |
exportOptions: { |
| 857 |
columns: exportColumns, |
877 |
columns: exportColumns, |
| 858 |
format: export_format, |
878 |
format: export_format_print, |
| 859 |
}, |
879 |
}, |
| 860 |
}, |
880 |
}, |
| 861 |
]; |
881 |
]; |
| 862 |
- |
|
|