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

Add custom_button_events subcollection for users, tenants and groups #464

Merged

Conversation

skateman
Copy link
Member

@skateman skateman commented Aug 31, 2018

As we discussed with @Hyperkid123 and @h-kataria, the new API-driven react/redux-based RBAC UI should include the custom button events via the API instead of using nested resources.

@miq-bot add_label enhancement, gaprindashvili/no
cc @Hyperkid123 you can start working with this in your PR

https://bugzilla.redhat.com/show_bug.cgi?id=1634053

@h-kataria
Copy link
Contributor

@skateman if a feature is marked as a hidden feature it is not displayed in the features tree but role_allows call returns true for the hidden features, in this case since we are not making role_allows call it should work.

@skateman
Copy link
Member Author

@h-kataria thanks, that's great, then we would need to specify somehow that this feature is for admins and super admins only. Is there a way to do so?

@skateman skateman force-pushed the custom-button-events-subcollection branch from f93814c to 18f67cb Compare September 5, 2018 07:51
@skateman skateman changed the title [WIP] Add custom_button_events subcollection for users, tenants and groups Add custom_button_events subcollection for users, tenants and groups Sep 5, 2018
@miq-bot miq-bot removed the wip label Sep 5, 2018
@skateman
Copy link
Member Author

@miq-bot assign @abellotti

- :subcollection
:verbs: *g
:klass: CustomButtonEvent
:subcollection_actions:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we also need subresource_actions for get?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not completely familiar what that would allow us, can you please help me?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIUC, subcollection_actions get allows get /api/users/:id/custom_button_events, but you would need subresource_actions get to allow get /api/users/:id/custom_button_events/:id. Is that correct @abellotti?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bdunne we don't need those, this feature is an admin-only debug thing

@skateman skateman force-pushed the custom-button-events-subcollection branch from db00209 to 80e6115 Compare October 26, 2018 11:59
@miq-bot
Copy link
Member

miq-bot commented Oct 26, 2018

Checked commit skateman@80e6115 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
7 files checked, 0 offenses detected
Everything looks fine. 🏆

@Hyperkid123
Copy link
Contributor

@bdunne what is the progress with this PR?

@bdunne bdunne merged commit 8a51e4a into ManageIQ:master Nov 9, 2018
@bdunne bdunne added this to the Sprint 99 Ending Nov 19, 2018 milestone Nov 9, 2018
@bdunne bdunne assigned bdunne and unassigned abellotti Nov 9, 2018
@skateman skateman deleted the custom-button-events-subcollection branch November 9, 2018 15:20
@skateman
Copy link
Member Author

skateman commented Nov 9, 2018

@Hyperkid123 unleash the monster react

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.

6 participants