-
Notifications
You must be signed in to change notification settings - Fork 356
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 "Add New Network Manager" unless Nuage is enabled #3979
Conversation
@djberg96 apologies for the troubles because we didn't think of this scenario when we flipped |
Nuage is somewhat special in a way it allows adding NetworkManager directly, without CloudManager. For all other providers such behavior is not feasible, therefore "Add New Network Manager" button should be hidden. With this commit we make sure that the button is hidden unless config/permissions.yaml file contains entry allowing user to use Nuage provider: ``` - ems-type:nuage_network ``` BZ: https://bugzilla.redhat.com/show_bug.cgi?id=1577888 Signed-off-by: Miha Pleško <[email protected]>
ebde790
to
85e559e
Compare
Checked commit miha-plesko@85e559e with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0 |
Won't this always return true by default as well? Or are users expected to remove it?
|
It's the other way around: by default the
(unless you add permissions.yaml on your own) 😄 |
👍 |
@blomquisg @juliancheal would you agree that UI should check config/permissions.yaml in order to decide whether "Add a New Network Provider" button is to be visible? |
👍 LGTM |
Nuage is somewhat special in a way it allows adding NetworkManager directly, without CloudManager. For all other providers such behavior is not feasible, therefore "Add New Network Manager" button should be hidden.
With this commit we make sure that the button is hidden unless config/permissions.yaml file contains entry allowing user to use Nuage provider:
- ems-type:nuage_network
BZ: https://bugzilla.redhat.com/show_bug.cgi?id=1577888
@miq-bot add_label enhancement,gaprindashvili/yes
@miq-bot assign @blomquisg
/cc @djberg96