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

Fixed the parallel API calling for the org details tabs(Cookbooks, Roles and Org edit tabs) #3589

Merged
merged 10 commits into from
May 12, 2020

Conversation

vinay033
Copy link
Collaborator

@vinay033 vinay033 commented May 5, 2020

Signed-off-by: vinay033 [email protected]

🔩 Description: What code changed, and why?

Org details page has different tabs, when we click to a particular tab then all API's calling parallel, on this page we are going to add more tabs so we have to manage like if we click to particular tab then only related API will calling.

I have added changes to separate the API calls, now if we click to particular tab then only specific API is called.

⛓️ Related Resources

#3410

👍 Definition of Done

we have separated the API calls now only specific tabs related API is calling when we clicking to a particular tab.

👟 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

✅ Checklist

📷 Screenshots, if applicable

org
cookbooklists
org-details
Roleslist

Copy link
Contributor

@srenatus srenatus left a comment

Choose a reason for hiding this comment

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

Haven't gone through all of this, just added something that caught my eye. Sorry for the half-review 😅

Copy link
Contributor

@srenatus srenatus left a comment

Choose a reason for hiding this comment

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

Thanks for addressing my other comments! I'm afraid I have another two small ones to share 😉

@vinay033 vinay033 force-pushed the Vinay/Fixed_parallel_API_calling branch from d4dda6d to bafac6c Compare May 8, 2020 07:34
@vinay033 vinay033 linked an issue May 8, 2020 that may be closed by this pull request
Copy link
Contributor

@SEAjamieD SEAjamieD left a comment

Choose a reason for hiding this comment

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

Found a couple duplicates - but overall is looking pretty good 👍

I wasn't able to totally test this out, when I get to an org detail page I have an error, but its because I don't have a valid org setup to check. I used infra_service_load_sample_data -N 10 -S infra-server -O infra-org to set it up - do you happen to have the curl call for 4th coffee that I could use?

@vinay033 vinay033 force-pushed the Vinay/Fixed_parallel_API_calling branch from bafac6c to 70c881e Compare May 10, 2020 16:07
@vjeffrey
Copy link

@SEAjamieD you'll find the curl call you need to test this out pinned in #automate-infra-views slack -- it's the (currently) 2nd item pinned, from mar 6th

Copy link
Contributor

@SEAjamieD SEAjamieD left a comment

Choose a reason for hiding this comment

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

Seeing a flash of [object, object] populating input fields on details tab when switching back and forth between details
object flash

Comment on lines 27 to 28
public serverId;
public OrgId;
public updateOrgForm: FormGroup;
public tabValue: OrgTabName = 'cookbooks';
public orgId;
Copy link
Contributor

Choose a reason for hiding this comment

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

One of these isn't yours, but would be cool if you could add types for these while you're in here

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I have added types.

Copy link
Contributor

@SEAjamieD SEAjamieD left a comment

Choose a reason for hiding this comment

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

Left a few more comments to address otherwise I think this is looking really good 🎉

@vinay033 vinay033 force-pushed the Vinay/Fixed_parallel_API_calling branch from 70c881e to 7127933 Compare May 12, 2020 08:20
@vinay033
Copy link
Collaborator Author

Seeing a flash of [object, object] populating input fields on details tab when switching back and forth between details
object flash

I have added a loading spinner on edit org.

@vinay033 vinay033 force-pushed the Vinay/Fixed_parallel_API_calling branch from 20a800b to eb39583 Compare May 12, 2020 14:10
@btm btm merged commit d1ab190 into master May 12, 2020
@chef-expeditor chef-expeditor bot deleted the Vinay/Fixed_parallel_API_calling branch May 12, 2020 15:32
@btm btm mentioned this pull request May 12, 2020
14 tasks
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.

Fix the parallel API calling for the org details tabs
6 participants