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

Is it possible to hide ▲ in sort_link for a particular column? #430

Closed
astr0gator opened this issue Sep 16, 2014 · 1 comment · Fixed by #473
Closed

Is it possible to hide ▲ in sort_link for a particular column? #430

astr0gator opened this issue Sep 16, 2014 · 1 comment · Fixed by #473

Comments

@astr0gator
Copy link

Hi folks! Thank's a lot for you job. Helps a lot!

Question in short: Would it be possible to hide triangle (▲) just for one column in sortable table?

Question detailed: I have a tiny question. I have a model and one of the column in db is "starred" which is boolean. I don't really need text, but rather a star in the head of the table. However, I have default sorting-triangle (▲) which is very helpful in general but a bit unnecessary for column, that has no text in the head (like star in my case). So, would it be possible to hide triangle (▲) just for one column in sortable table?

Thank you beforehand!

@jonatack
Copy link
Contributor

jonatack commented Oct 1, 2014

Hi @fertingoff, thanks! At the moment, no. It shouldn't be too difficult to monkey_patch the sort_link method in Ransack::Helpers::FormHelper or write a PR that enables passing an optional argument to hide the triangle, if you wanted to do that.

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

Successfully merging a pull request may close this issue.

2 participants