문제

I'm in the midst of converting some tables that are using DisplayTag over to using DataTables w/ the TableTools plugin for export. One nice thing about the former is that there's a media field for each column which specifies if that column should be present in HTML, CSV, etc such that you can have different columns in different media.

Is there some way to replicate this in the DataTable/TableTool environment? The specific use case is that a lot of our tables will have columns which are abbreviated summarizations of a few columns in the HTML display while the exported versions are intended to have the full columns.

도움이 되었습니까?

해결책

The equivalent in TableTools is the "mColumns" option, which allows you to define 'all', 'visible', 'hidden' or an array of column indexes that you want to include in the output: http://datatables.net/extras/tabletools/button_options#mColumns

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top