Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide columns in filter based export in thymeleaf #275

Open
sundermann opened this issue Feb 12, 2015 · 1 comment
Open

Hide columns in filter based export in thymeleaf #275

sundermann opened this issue Feb 12, 2015 · 1 comment

Comments

@sundermann
Copy link

JSP seems to have a property to exclude certain columns in the export using the display attribute. For thymeleaf this option seems to be missing (at least I couldn't find it in the documentation and adding a dt:display="html" didn't exclude the columns).
Is the feature available somewhere and I didn't specifiy the right attributes or is this feature really missing?

@tduchateau
Copy link
Member

Indeed, the dt:display attribute doesn't exist in the Thymeleaf dialect.

Actually it works a bit differently. In Thymeleaf, we assume that every column will be always rendered in HTML and attributes such as dt:xls or dt:pdf allow you to configure what will be rendered in XLS and PDF exports respectively.

I would instead advise to use controller-based exports (see http://dandelion.github.io/datatables/features/export/controller-based-exports.html) which is the most flexible way of exporting. Just use the HtmlTableBuilder to configure the contents of each cell.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants