I'm need to create a function that contains two separate rest calls as data is needed to be passed from the first call to the second. How should this be structured within angular.
This code is basically what I need it to do but not sure how to structure or format.
getInfo(CName: string, PName: string, Id: string): void {
this.subscriptions.push(
this.FindService.getG(CName, PName)
.subscribe((details: data) => {this.data = details})
)
this.subscriptions.push(
this.FindAdminService.getP(CName, PName, Id)
.subscribe((details: Info) => {this.data = details})
)
}