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

Fixes #4370 - Filters list show permissions #1343

Closed
wants to merge 1 commit into from

Conversation

dLobatog
Copy link
Member

@dLobatog dLobatog commented Apr 1, 2014

@dmitri-d
Copy link
Member

dmitri-d commented Apr 8, 2014

I'm getting "Invalid search query: the field 'permissions' in the order statement is not valid field for search" when attempting to sort by permissions -- filter model is missing corresponding scoped search definition.

I'm not sure how useful this sorting order is, perhaps it's better to leave it out? Would it be better to allow filtering based on permission name?

@dLobatog
Copy link
Member Author

dLobatog commented Apr 8, 2014

@thomasmckay ^^

@thomasmckay
Copy link
Contributor

@elobato Not sorting seems fine to me. I assume search works?

@dmitri-d
Copy link
Member

dmitri-d commented Apr 8, 2014

Search on permissions isn't working atm; should be straightforward to add though.

@dLobatog
Copy link
Member Author

dLobatog commented Apr 8, 2014

I'll add scoped_search to permissions then.

@domcleal
Copy link
Contributor

domcleal commented Apr 9, 2014

Some of the columns (like the last one with dropdown + button) look rather squashed to me when viewing something like the manager role.

@dLobatog
Copy link
Member Author

I'm not quite sure how to handle searches with spaces, queries should be made like this now:
role = "Manager" and permission = edit_organizations

It's understandable for us devs but regular users will see stuff like "Edit organizations" in the permissions column, should I better change that to "edit_organizations" like what users see when editing the filter?

@domcleal
Copy link
Contributor

I think edit_organizations is clearer, keep it consistent.

@dmitri-d
Copy link
Member

+1 to what @domcleal said.

@dLobatog
Copy link
Member Author

Ask and you shall receive. 😄

@dmitri-d
Copy link
Member

Sorting by permissions is still enabled, but isn't working: "Invalid search query: the field 'permissions' in the order statement is not valid field for search". Filtering by permission name works, but values are not being auto-suggested as for other fields (I tried it -- looks helpful, although the auto-suggest list can get pretty long).

Filter scoped_search

Don't humanize permission names

Remove sorting permissions
@dLobatog
Copy link
Member Author

I disabled sorting by permissions.

@domcleal
Copy link
Contributor

domcleal commented May 1, 2014

Merged as 46da92f for Foreman 1.5.0, thanks @elobato!

@domcleal domcleal closed this May 1, 2014
@dLobatog dLobatog deleted the 4370 branch July 29, 2014 09:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants