-
Notifications
You must be signed in to change notification settings - Fork 63
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
Set Up #14
Comments
So much information online and almost none of it works or is useful. Anything that looks solid is out of date, even as recently as 2020. Stumbled across this library but not sure how to implement, wish microsoft would do a better and singular location to house their docs, It all ends up being a circular rabbit hole that never ends and people have to hack together. I dread anything to do with powerBI. Hope you get this to work and would love to see your solution! @DomTripodi93 |
@eddyizm As best as I can tell, it is not ready to be used, which is a shame, because it is very nearly functional. As of now, my solution is to use React, or just embed in a regular IFrame and make the user log in to view the report. There is no telling what the intended replacement is for "https://aka.ms/CaptureViewsReportEmbedConfig", or if there even is one yet. Hopefully this will become functional and documented early next year, and we'll get to use it. |
Looks like I finally got it to work late last month. Forgot to come back here but just wanted to let you that it was possible. Or at least I believe I used this library lol |
For the benefit of anyone else arriving here and getting stuck on the same problem, this is how I managed to get the component working;
Here is what my angular component looks like; template; <powerbi-report [embedConfig]="reportConfig" [eventHandlers]="eventHandlersMap" [cssClassName]="reportClass">
</powerbi-report> ts file; public reportConfig: IReportEmbedConfiguration; // binds to embedConfig on the powerbi-report component above
// called from onInit - builds the reportConfig property
public async embedReport(): Promise<void> {
// call to my controller action from step 5, requestedReport contains report id, work set id & data set id
let embedConfig = await this.powerBiService.GetEmbeddedReportConfig(this.requestedReport);
this.reportConfig = {
type: 'report',
embedUrl: embedConfig.embedUrl,
id: embedConfig.id,
accessToken: embedConfig.token,
tokenType: models.TokenType.Embed,
settings: {
panes: {
filters: {
expanded: false,
visible: false
}
},
background: models.BackgroundType.Transparent
},
};
} Some pitfalls to be aware of;
|
Hello, I have been trying to get this working in an Angular project, and haven't had a lot of success.
I can't figure out what I should change the 'https://aka.ms/CaptureViewsReportEmbedConfig' endpoint to, so that I can pull down my own access token and report.
I had been working on trying to get the React UserOwnsData converted over to work with Angular, but I can't get from receiving the id_token to embedding the report.
it looks like the id token passed back is not what the React demo uses in the embed call, and I couldn't figure out where it is getting the correct access token from.
Dominic
The text was updated successfully, but these errors were encountered: