Merged PR 19200: Merge dev to master
This commit is contained in:
Родитель
b3fc219590
Коммит
8104c39d95
|
@ -503,6 +503,23 @@ function _Report_Reload() {
|
|||
});
|
||||
}
|
||||
|
||||
function _Report_Refresh() {
|
||||
// Get a reference to the embedded report HTML element
|
||||
var reportContainer = $('#reportContainer')[0];
|
||||
|
||||
// Get a reference to the embedded report.
|
||||
report = powerbi.get(reportContainer);
|
||||
|
||||
// Refresh the displayed report
|
||||
report.refresh()
|
||||
.then(function (result) {
|
||||
Log.log(result);
|
||||
})
|
||||
.catch(function (errors) {
|
||||
Log.log(errors);
|
||||
});
|
||||
}
|
||||
|
||||
function _Report_FullScreen() {
|
||||
// Get a reference to the embedded report HTML element
|
||||
var reportContainer = $('#reportContainer')[0];
|
||||
|
|
|
@ -4,6 +4,7 @@ const SessionKeys = {
|
|||
AccessToken : "accessToken",
|
||||
EmbedUrl : "embedUrl",
|
||||
EmbedId : "embedId",
|
||||
GroupId : "groupId",
|
||||
IsSampleReport: "isSampleReport"
|
||||
};
|
||||
|
||||
|
@ -48,6 +49,17 @@ function SetTextBoxesFromSessionOrUrlParam(accessTokenSelector, embedUrlSelector
|
|||
if (!embedUrl)
|
||||
{
|
||||
embedUrl = GetSession(SessionKeys.EmbedUrl);
|
||||
} else {
|
||||
var groupId = GetParameterByName(SessionKeys.GroupId);
|
||||
if(groupId)
|
||||
{
|
||||
if (embedUrl.indexOf("?") != -1)
|
||||
{
|
||||
embedUrl += "&groupId=" + groupId;
|
||||
} else {
|
||||
embedUrl += "?groupId=" + groupId;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var embedId = GetParameterByName(SessionKeys.EmbedId);
|
||||
|
|
|
@ -35,6 +35,10 @@ function Report_Reload() {
|
|||
SetCode(_Report_Reload);
|
||||
}
|
||||
|
||||
function Report_Refresh() {
|
||||
SetCode(_Report_Refresh);
|
||||
}
|
||||
|
||||
function Report_FullScreen() {
|
||||
SetCode(_Report_FullScreen);
|
||||
}
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
<li class="" onclick="Report_PrintCurrentReport()">Print</li>
|
||||
<li class="" onclick="Report_UpdateSettings()">Update settings</li>
|
||||
<li class="" onclick="Report_Reload()">Reload</li>
|
||||
<li class="" onclick="Report_Refresh()">Refresh</li>
|
||||
<li class="" onclick="Report_FullScreen()">Full screen</li>
|
||||
<li class="" onclick="Report_ExitFullScreen()">Exit full screen</li>
|
||||
</ul>
|
||||
|
|
|
@ -313,7 +313,13 @@ return /******/ (function(modules) { // webpackBootstrap
|
|||
/** Removes the iframe from the element. */
|
||||
var iframe = element.querySelector('iframe');
|
||||
if (iframe) {
|
||||
iframe.remove();
|
||||
if (iframe.remove !== undefined) {
|
||||
iframe.remove();
|
||||
}
|
||||
else {
|
||||
/** Workaround for IE: unhandled rejection TypeError: object doesn't support propert or method 'remove' */
|
||||
iframe.parentElement.removeChild(iframe);
|
||||
}
|
||||
}
|
||||
};
|
||||
/**
|
||||
|
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -69,7 +69,7 @@ export class Service implements IService {
|
|||
/**
|
||||
* A list of components that this service can embed
|
||||
*/
|
||||
private static components: (typeof Report | typeof Tile | typeof Dashboard)[] = [
|
||||
private static components: (typeof Report | typeof Tile | typeof Dashboard)[] = [
|
||||
Tile,
|
||||
Report,
|
||||
Dashboard
|
||||
|
@ -170,7 +170,6 @@ export class Service implements IService {
|
|||
let powerBiElement = <IPowerBiElement>element;
|
||||
const component = new Create(this, powerBiElement, config);
|
||||
powerBiElement.powerBiEmbed = component;
|
||||
|
||||
this.addOrOverwriteEmbed(component, element);
|
||||
|
||||
return component;
|
||||
|
@ -350,7 +349,13 @@ export class Service implements IService {
|
|||
/** Removes the iframe from the element. */
|
||||
const iframe = element.querySelector('iframe');
|
||||
if (iframe) {
|
||||
iframe.remove();
|
||||
if(iframe.remove !== undefined) {
|
||||
iframe.remove();
|
||||
}
|
||||
else {
|
||||
/** Workaround for IE: unhandled rejection TypeError: object doesn't support propert or method 'remove' */
|
||||
iframe.parentElement.removeChild(iframe);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
"check-decl",
|
||||
"check-operator",
|
||||
"check-module",
|
||||
"check-seperator",
|
||||
"check-separator",
|
||||
"check-type"
|
||||
],
|
||||
"object-literal-sort-keys": false
|
||||
|
|
Загрузка…
Ссылка в новой задаче