-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDialogWidget.ts
More file actions
46 lines (37 loc) · 1.54 KB
/
Copy pathDialogWidget.ts
File metadata and controls
46 lines (37 loc) · 1.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/// <reference path='../../Infor.BI.WebFramework.Web/Scripts/Infor.d.ts'/>
/// <reference path='ReportContent.ts'/>
import ReportContent = module("./ReportContent");
export class DialogWidget extends ReportContent.ReportContent implements Infor.BI.dashboards.IDialog {
constructor(public dashboard: Infor.BI.dashboards.IDialogContainer, public config: ReportContent.ASWSReportConfiguration) {
super(dashboard, config);
}
init(config: Infor.BI.dashboards.IWidgetConfiguration): void {
this.config = <ReportContent.ASWSReportConfiguration>config;
this.loadUrl(false);
}
buttonClicked(clickedButtonKey: string): void {
}
dialogDataChanged(data: Infor.BI.dashboards.IDialogData, modified?: Infor.BI.dashboards.IDialogData): void {
}
// protected
processSpecificPostMessage(detailsJson: any) {
if (detailsJson === null) {
} else if (detailsJson.action === "init") {
this.onContentInit();
} else if (detailsJson.action === "closeDialog") {
this.closeWidgetDialog(detailsJson);
}
}
private closeWidgetDialog(detailsJson: any): void {
// since the parent report is unknown in the context of the open dialog,
// Dashboard closes the dialog and informs WS about it afterwards
var jsonData = {
actionToken: detailsJson.actionToken,
returnValue: detailsJson.returnValue
};
this.dashboard.close(jsonData);
}
private onContentInit() {
this.dashboard.UX.hideLoadingMask();
}
}