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

Added UI for edit environment. #4844

Merged
merged 7 commits into from
Mar 23, 2021
Merged

Added UI for edit environment. #4844

merged 7 commits into from
Mar 23, 2021

Conversation

himanshi-chhabra
Copy link
Contributor

@himanshi-chhabra himanshi-chhabra commented Mar 19, 2021

πŸ”© Description: What code changed, and why?

We need to add UI for EDIT Environment

⛓️ Related Resources

#4545

πŸ‘ Definition of Done

Added edit functionality for Environment in which we can edit:

  1. cookbook constraints
  2. Attributes: default, override

πŸ‘Ÿ How to Build and Test the Change

STEP 1
inside the hab studio

[default:/src:0]# build components/automate-ui-devproxy/
[default:/src:0]# start_automate_ui_background
[default:/src:0]# start_all_services

STEP 2
open new window
go to automate UI path

$ cd components/automate-ui
and run the command 

npm run serve:hab

To add data https://github.com/chef/automate/blob/master/dev-docs/adding-data/adding_test_data.md#adding-data-to-infra-views

Steps:

  1. Go To Infrastructure -> Chef Servers -> click server name-> click on org name -> Environment
  2. Click on and Environment name -> Cookbook constraint Tab -> click on edit button for editing cookbook.
  3. Click on Attribute tab -> click on edit button for default or override attribute.

βœ… Checklist

πŸ“· Screenshots, if applicable

edit_environment_1
edit_env_2
edit_env_3
edit_env_4
edit_env_5

@netlify
Copy link

netlify bot commented Mar 19, 2021

Deploy preview for chef-automate processing.

Building with commit 788b25f

https://app.netlify.com/sites/chef-automate/deploys/605a1e746fb85b0008a11ff3

filter(({ payload }: UpdateEnvironmentFailure) => payload.status !== HttpStatus.CONFLICT),
map(({ payload }: UpdateEnvironmentFailure) => new CreateNotification({
type: Type.error,
message: `Could not Update notification: ${payload.error.error || payload}.`
Copy link
Collaborator

Choose a reason for hiding this comment

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

change this error message, relace with the environment.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated the changes

Copy link
Collaborator

@vinay033 vinay033 left a comment

Choose a reason for hiding this comment

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

changes looks good to me, need to update the error message for update failure.

Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Signed-off-by: Himanshi Chhabra <himanshi.chhabra@msystechnologies.com>
Copy link

@kvivek1115 kvivek1115 left a comment

Choose a reason for hiding this comment

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

Pulled the branch locally and tested out the feature, it working as expected. Thanks!

@kalroy kalroy merged commit 1b705a4 into master Mar 23, 2021
@kalroy kalroy deleted the Himanshi/edit_Environment_UI branch March 23, 2021 18:18
@himanshi-chhabra
Copy link
Contributor Author

himanshi-chhabra commented Mar 25, 2021

While acceptance testing, observed

  • Add no preview image in the attributes tab if no JSON available.
  • Change border-size of details box 1px.
  • When we click the button of edit or expand we have to click twice then the pop-up visible. need to update this.
  • Edit, Expand, collapse buttons are not keyboard accessible.
  • In the edit environment pop-up, change the border size of the label.
    will cover in UI Improvements for Edit ViewΒ #4873

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.

None yet

4 participants