@memberjunction/ng-skip-chat 2.48.0 → 2.49.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/artifacts/skip-artifact-viewer.component.js +254 -270
- package/dist/lib/artifacts/skip-artifact-viewer.component.js.map +1 -1
- package/dist/lib/artifacts/skip-artifacts-counter.component.js +82 -90
- package/dist/lib/artifacts/skip-artifacts-counter.component.js.map +1 -1
- package/dist/lib/drill-down-info.js +4 -3
- package/dist/lib/drill-down-info.js.map +1 -1
- package/dist/lib/dynamic-report/base-report.js +147 -164
- package/dist/lib/dynamic-report/base-report.js.map +1 -1
- package/dist/lib/dynamic-report/dynamic-chart.js +77 -86
- package/dist/lib/dynamic-report/dynamic-chart.js.map +1 -1
- package/dist/lib/dynamic-report/dynamic-grid.js +80 -93
- package/dist/lib/dynamic-report/dynamic-grid.js.map +1 -1
- package/dist/lib/dynamic-report/dynamic-ui-component.js +173 -188
- package/dist/lib/dynamic-report/dynamic-ui-component.js.map +1 -1
- package/dist/lib/dynamic-report/linear-report.js +16 -26
- package/dist/lib/dynamic-report/linear-report.js.map +1 -1
- package/dist/lib/dynamic-report/skip-dynamic-report-wrapper.js +28 -28
- package/dist/lib/dynamic-report/skip-dynamic-report-wrapper.js.map +1 -1
- package/dist/lib/dynamic-report/skip-react-component-host.js +203 -212
- package/dist/lib/dynamic-report/skip-react-component-host.js.map +1 -1
- package/dist/lib/module.js +22 -22
- package/dist/lib/module.js.map +1 -1
- package/dist/lib/report-cache.js +2 -5
- package/dist/lib/report-cache.js.map +1 -1
- package/dist/lib/skip-chat/skip-chat.component.js +1052 -1087
- package/dist/lib/skip-chat/skip-chat.component.js.map +1 -1
- package/dist/lib/skip-single-message/skip-single-message.component.js +251 -259
- package/dist/lib/skip-single-message/skip-single-message.component.js.map +1 -1
- package/dist/lib/split-panel/skip-split-panel.component.js +52 -51
- package/dist/lib/split-panel/skip-split-panel.component.js.map +1 -1
- package/package.json +13 -13
|
@@ -1,12 +1,3 @@
|
|
|
1
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
1
|
import { Directive, EventEmitter, Input, Output } from "@angular/core";
|
|
11
2
|
import { LogError } from "@memberjunction/core";
|
|
12
3
|
import { ConvertMarkdownStringToHtmlList } from "@memberjunction/global";
|
|
@@ -14,86 +5,86 @@ import { BaseAngularComponent } from "@memberjunction/ng-base-types";
|
|
|
14
5
|
import { SkipConversationReportCache } from "../report-cache";
|
|
15
6
|
import * as i0 from "@angular/core";
|
|
16
7
|
export class SkipDynamicReportBase extends BaseAngularComponent {
|
|
8
|
+
cdRef;
|
|
9
|
+
SkipData;
|
|
10
|
+
ShowCreateReportButton = false;
|
|
11
|
+
ConversationID = null;
|
|
12
|
+
ConversationName = null;
|
|
13
|
+
ConversationDetailID = null;
|
|
14
|
+
DataContext;
|
|
15
|
+
ReportEntity;
|
|
16
|
+
UserNotification = new EventEmitter();
|
|
17
|
+
/**
|
|
18
|
+
* This event fires whenever the component has a click on a matching report link.
|
|
19
|
+
* The provided parameter is the ID of the matching report.
|
|
20
|
+
*/
|
|
21
|
+
NavigateToMatchingReport = new EventEmitter();
|
|
22
|
+
/**
|
|
23
|
+
* This event fires whenever a new report is created.
|
|
24
|
+
*/
|
|
25
|
+
NewReportCreated = new EventEmitter();
|
|
26
|
+
/**
|
|
27
|
+
* This event fires whenever a drill down is requested within a given report.
|
|
28
|
+
*/
|
|
29
|
+
DrillDownEvent = new EventEmitter();
|
|
17
30
|
constructor(cdRef) {
|
|
18
31
|
super();
|
|
19
32
|
this.cdRef = cdRef;
|
|
20
|
-
this.ShowCreateReportButton = false;
|
|
21
|
-
this.ConversationID = null;
|
|
22
|
-
this.ConversationName = null;
|
|
23
|
-
this.ConversationDetailID = null;
|
|
24
|
-
this.UserNotification = new EventEmitter();
|
|
25
|
-
/**
|
|
26
|
-
* This event fires whenever the component has a click on a matching report link.
|
|
27
|
-
* The provided parameter is the ID of the matching report.
|
|
28
|
-
*/
|
|
29
|
-
this.NavigateToMatchingReport = new EventEmitter();
|
|
30
|
-
/**
|
|
31
|
-
* This event fires whenever a new report is created.
|
|
32
|
-
*/
|
|
33
|
-
this.NewReportCreated = new EventEmitter();
|
|
34
|
-
/**
|
|
35
|
-
* This event fires whenever a drill down is requested within a given report.
|
|
36
|
-
*/
|
|
37
|
-
this.DrillDownEvent = new EventEmitter();
|
|
38
|
-
this.matchingReportID = null;
|
|
39
|
-
this.matchingReportName = null;
|
|
40
|
-
this._loaded = false;
|
|
41
|
-
this._isCreatingReport = false;
|
|
42
33
|
}
|
|
43
34
|
ngAfterViewInit() {
|
|
44
35
|
this.RefreshMatchingReport();
|
|
45
36
|
}
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
37
|
+
matchingReportID = null;
|
|
38
|
+
matchingReportName = null;
|
|
39
|
+
static _reportCache = [];
|
|
40
|
+
_loaded = false;
|
|
41
|
+
async RefreshMatchingReport() {
|
|
42
|
+
if (this.SkipData && !this._loaded && this.ConversationDetailID && this.ConversationID) {
|
|
43
|
+
this._loaded = true;
|
|
44
|
+
if (this.ShowCreateReportButton) {
|
|
45
|
+
// check to see if a report has been created that is linked to this ConvoID/ConvoDetailID
|
|
46
|
+
// if so don't allow the user to create another report, show a link to the existing one
|
|
47
|
+
const cachedItem = SkipDynamicReportBase._reportCache.find((x) => x.conversationId === this.ConversationID && x.conversationDetailId === this.ConversationDetailID);
|
|
48
|
+
if (cachedItem) {
|
|
49
|
+
this.matchingReportID = cachedItem.reportId;
|
|
50
|
+
this.matchingReportName = cachedItem.reportName;
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
// no cached items locally so use the generalized ReportCache which can load for us if needed
|
|
54
|
+
const reports = await SkipConversationReportCache.Instance.GetConversationReports(this.ConversationID, this.RunViewToUse);
|
|
55
|
+
const matchingReports = reports ? reports.filter((x) => x.ConversationDetailID === this.ConversationDetailID) : [];
|
|
56
|
+
if (matchingReports && matchingReports.length > 0) {
|
|
57
|
+
const item = matchingReports[0];
|
|
58
|
+
this.matchingReportID = item.ID;
|
|
59
|
+
this.matchingReportName = item.Name;
|
|
60
|
+
// cache for future to avoid db call
|
|
61
|
+
SkipDynamicReportBase._reportCache.push({
|
|
62
|
+
reportId: item.ID,
|
|
63
|
+
conversationId: this.ConversationID,
|
|
64
|
+
reportName: item.Name,
|
|
65
|
+
conversationDetailId: this.ConversationDetailID,
|
|
66
|
+
});
|
|
74
67
|
}
|
|
75
|
-
this.cdRef.detectChanges(); // the above will change the view so we need to manually trigger change detection
|
|
76
68
|
}
|
|
69
|
+
this.cdRef.detectChanges(); // the above will change the view so we need to manually trigger change detection
|
|
77
70
|
}
|
|
78
|
-
}
|
|
71
|
+
}
|
|
79
72
|
}
|
|
80
73
|
HandleDrillDownEvent(drillDownInfo) {
|
|
81
74
|
// bubble the event up to the parent component
|
|
82
75
|
this.DrillDownEvent.emit(drillDownInfo);
|
|
83
76
|
}
|
|
84
77
|
get Columns() {
|
|
85
|
-
|
|
86
|
-
return ((_a = this.SkipData) === null || _a === void 0 ? void 0 : _a.tableDataColumns) || [];
|
|
78
|
+
return this.SkipData?.tableDataColumns || [];
|
|
87
79
|
}
|
|
88
80
|
get ResultType() {
|
|
89
|
-
var _a, _b, _c, _d;
|
|
90
81
|
// support for legacy format where the resultType was within executionResults and for the new location at the root of SkipData
|
|
91
|
-
let rt =
|
|
82
|
+
let rt = this.SkipData?.resultType?.trim().toLowerCase();
|
|
92
83
|
if (!rt) {
|
|
93
84
|
// we don't have the new format, so check for legacy location
|
|
94
|
-
const executionResults =
|
|
85
|
+
const executionResults = this.SkipData?.executionResults; // becuase new type does NOT have resultType on executionResults as it was moved
|
|
95
86
|
if (executionResults) {
|
|
96
|
-
rt =
|
|
87
|
+
rt = executionResults.resultType?.trim().toLowerCase();
|
|
97
88
|
}
|
|
98
89
|
}
|
|
99
90
|
return rt || '';
|
|
@@ -112,8 +103,7 @@ export class SkipDynamicReportBase extends BaseAngularComponent {
|
|
|
112
103
|
* @returns
|
|
113
104
|
*/
|
|
114
105
|
CreateAnalysisHtml() {
|
|
115
|
-
|
|
116
|
-
const analysis = (_a = this.SkipData) === null || _a === void 0 ? void 0 : _a.analysis;
|
|
106
|
+
const analysis = this.SkipData?.analysis;
|
|
117
107
|
if (analysis && analysis.length > 0) {
|
|
118
108
|
return ConvertMarkdownStringToHtmlList('Unordered', analysis);
|
|
119
109
|
}
|
|
@@ -126,36 +116,35 @@ export class SkipDynamicReportBase extends BaseAngularComponent {
|
|
|
126
116
|
get IsCreatingReport() {
|
|
127
117
|
return this._isCreatingReport;
|
|
128
118
|
}
|
|
119
|
+
_isCreatingReport = false;
|
|
129
120
|
/**
|
|
130
121
|
* This method is used to create a report from the current conversation detail
|
|
131
122
|
*/
|
|
132
|
-
DoCreateReport() {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
123
|
+
async DoCreateReport() {
|
|
124
|
+
this._isCreatingReport = true;
|
|
125
|
+
if (!this.SkipData || !this.ConversationID || !this.ConversationName || !this.ConversationDetailID) {
|
|
126
|
+
throw new Error('Must set SkipData, ConversationID, ConversationName, and ConversationDetailID to enable saving report');
|
|
127
|
+
}
|
|
128
|
+
else {
|
|
129
|
+
const result = await this._GraphQLCreateNewReport();
|
|
130
|
+
if (result && result.Success) {
|
|
131
|
+
this.matchingReportID = result.ReportID;
|
|
132
|
+
this.matchingReportName = result.ReportName;
|
|
133
|
+
// let the user know we saved the report
|
|
134
|
+
this.RaiseUserNotification(`Report "${result.ReportName}"Saved`, 'success', 2500);
|
|
135
|
+
// tell our shared report cache about the new report
|
|
136
|
+
const report = await this.ProviderToUse.GetEntityObject('Reports', this.ProviderToUse.CurrentUser);
|
|
137
|
+
report.Load(result.ReportID).then(() => {
|
|
138
|
+
// do async so the user doesn't wait for this to finish
|
|
139
|
+
SkipConversationReportCache.Instance.AddConversationReport(this.ConversationID, report);
|
|
140
|
+
});
|
|
141
|
+
this.NewReportCreated.emit(result.ReportID); // finally emit the event
|
|
137
142
|
}
|
|
138
143
|
else {
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
this.matchingReportID = result.ReportID;
|
|
142
|
-
this.matchingReportName = result.ReportName;
|
|
143
|
-
// let the user know we saved the report
|
|
144
|
-
this.RaiseUserNotification(`Report "${result.ReportName}"Saved`, 'success', 2500);
|
|
145
|
-
// tell our shared report cache about the new report
|
|
146
|
-
const report = yield this.ProviderToUse.GetEntityObject('Reports', this.ProviderToUse.CurrentUser);
|
|
147
|
-
report.Load(result.ReportID).then(() => {
|
|
148
|
-
// do async so the user doesn't wait for this to finish
|
|
149
|
-
SkipConversationReportCache.Instance.AddConversationReport(this.ConversationID, report);
|
|
150
|
-
});
|
|
151
|
-
this.NewReportCreated.emit(result.ReportID); // finally emit the event
|
|
152
|
-
}
|
|
153
|
-
else {
|
|
154
|
-
this.RaiseUserNotification('Error saving report', 'error', 2500);
|
|
155
|
-
this._isCreatingReport = false;
|
|
156
|
-
}
|
|
144
|
+
this.RaiseUserNotification('Error saving report', 'error', 2500);
|
|
145
|
+
this._isCreatingReport = false;
|
|
157
146
|
}
|
|
158
|
-
}
|
|
147
|
+
}
|
|
159
148
|
}
|
|
160
149
|
RaiseUserNotification(message, style, hideAfter) {
|
|
161
150
|
this.UserNotification.emit({ message, style, hideAfter });
|
|
@@ -163,10 +152,9 @@ export class SkipDynamicReportBase extends BaseAngularComponent {
|
|
|
163
152
|
/**
|
|
164
153
|
* This method does the internal work with the current GraphQLDataProvider to actually create a new report on the server.
|
|
165
154
|
*/
|
|
166
|
-
_GraphQLCreateNewReport() {
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
const mutation = `mutation CreateReportFromConversationDetailIDMutation ($ConversationDetailID: String!) {
|
|
155
|
+
async _GraphQLCreateNewReport() {
|
|
156
|
+
// do this via a single gql call to make it faster than doing operation via standard objects since it is a multi-step operation
|
|
157
|
+
const mutation = `mutation CreateReportFromConversationDetailIDMutation ($ConversationDetailID: String!) {
|
|
170
158
|
CreateReportFromConversationDetailID(ConversationDetailID: $ConversationDetailID) {
|
|
171
159
|
ReportID
|
|
172
160
|
ReportName
|
|
@@ -174,39 +162,36 @@ export class SkipDynamicReportBase extends BaseAngularComponent {
|
|
|
174
162
|
ErrorMessage
|
|
175
163
|
}
|
|
176
164
|
}`;
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
});
|
|
181
|
-
if (result && result.CreateReportFromConversationDetailID)
|
|
182
|
-
return result.CreateReportFromConversationDetailID;
|
|
183
|
-
else
|
|
184
|
-
return {
|
|
185
|
-
Success: false,
|
|
186
|
-
ErrorMessage: 'Failed to execute',
|
|
187
|
-
ReportID: '',
|
|
188
|
-
ReportName: '',
|
|
189
|
-
};
|
|
165
|
+
const p = this.ProviderToUse;
|
|
166
|
+
const result = await p.ExecuteGQL(mutation, {
|
|
167
|
+
ConversationDetailID: this.ConversationDetailID,
|
|
190
168
|
});
|
|
169
|
+
if (result && result.CreateReportFromConversationDetailID)
|
|
170
|
+
return result.CreateReportFromConversationDetailID;
|
|
171
|
+
else
|
|
172
|
+
return {
|
|
173
|
+
Success: false,
|
|
174
|
+
ErrorMessage: 'Failed to execute',
|
|
175
|
+
ReportID: '',
|
|
176
|
+
ReportName: '',
|
|
177
|
+
};
|
|
191
178
|
}
|
|
192
179
|
/**
|
|
193
180
|
* This method will refresh the report by re-running the script that generated the report.
|
|
194
181
|
* @returns
|
|
195
182
|
*/
|
|
196
|
-
DoRefreshReport() {
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
this.RaiseUserNotification('Refreshing report...', 'info', 2500);
|
|
209
|
-
const gql = `query ExecuteAskSkipRunScript($dataContextId: String!, $scriptText: String!) {
|
|
183
|
+
async DoRefreshReport() {
|
|
184
|
+
try {
|
|
185
|
+
if (!this.SkipData) {
|
|
186
|
+
this.RaiseUserNotification('No data to refresh', 'error', 2500);
|
|
187
|
+
return;
|
|
188
|
+
}
|
|
189
|
+
if (!this.ReportEntity || !this.ReportEntity.ID) {
|
|
190
|
+
this.RaiseUserNotification('No report to refresh', 'error', 2500);
|
|
191
|
+
return;
|
|
192
|
+
}
|
|
193
|
+
this.RaiseUserNotification('Refreshing report...', 'info', 2500);
|
|
194
|
+
const gql = `query ExecuteAskSkipRunScript($dataContextId: String!, $scriptText: String!) {
|
|
210
195
|
ExecuteAskSkipRunScript(DataContextId: $dataContextId, ScriptText: $scriptText) {
|
|
211
196
|
Success
|
|
212
197
|
Status
|
|
@@ -216,51 +201,49 @@ export class SkipDynamicReportBase extends BaseAngularComponent {
|
|
|
216
201
|
AIMessageConversationDetailId
|
|
217
202
|
}
|
|
218
203
|
}`;
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
}
|
|
230
|
-
// it worked, refresh the report here
|
|
231
|
-
const newSkipData = JSON.parse(resultObj.Result);
|
|
232
|
-
this.SkipData.analysis = newSkipData.analysis; // update the analysis
|
|
233
|
-
this.SkipData.executionResults = newSkipData.executionResults; // drives the chart/table bindings
|
|
234
|
-
this.SkipData.dataContext = newSkipData.dataContext; // drives the HTML report bindings
|
|
235
|
-
// make sure to push the techExplanation and userExplanation to the newSkipData object as that WILL NOT come back with that info from the original report
|
|
236
|
-
newSkipData.userExplanation = this.SkipData.userExplanation;
|
|
237
|
-
newSkipData.techExplanation = this.SkipData.techExplanation;
|
|
238
|
-
newSkipData.resultType = this.SkipData.resultType;
|
|
239
|
-
newSkipData.responsePhase = this.SkipData.responsePhase;
|
|
240
|
-
newSkipData.messages = this.SkipData.messages; // this is the array of messages that are used to create the report from the original message, we don't want message from the refresh, it is simple message
|
|
241
|
-
newSkipData.reportTitle = this.SkipData.reportTitle; // legacy property, carry it over if it exists
|
|
242
|
-
newSkipData.title = this.SkipData.title || this.SkipData.reportTitle; // favor the new title but fallback to the legacy reportTitle. This is the title of the component, we don't want to change it
|
|
243
|
-
newSkipData.drillDown = this.SkipData.drillDown; // this is the drill down data, we don't want to change it
|
|
244
|
-
this.ReportEntity.Configuration = JSON.stringify(newSkipData);
|
|
245
|
-
const saveResult = yield this.ReportEntity.Save();
|
|
246
|
-
if (!saveResult) {
|
|
247
|
-
LogError('Error refreshing report: failed to save report entity', undefined, this.ReportEntity.LatestResult);
|
|
248
|
-
this.RaiseUserNotification('Error refreshing report', 'error', 2500);
|
|
249
|
-
}
|
|
250
|
-
else {
|
|
251
|
-
this.RaiseUserNotification('Report refreshed', 'success', 2500);
|
|
252
|
-
}
|
|
204
|
+
const p = this.ProviderToUse;
|
|
205
|
+
const result = await p.ExecuteGQL(gql, {
|
|
206
|
+
dataContextId: this.ReportEntity.DataContextID,
|
|
207
|
+
scriptText: this.SkipData?.scriptText,
|
|
208
|
+
});
|
|
209
|
+
const resultObj = result.ExecuteAskSkipRunScript;
|
|
210
|
+
if (!resultObj.Success) {
|
|
211
|
+
LogError('Error refreshing report: resultObj.Success was false');
|
|
212
|
+
this.RaiseUserNotification('Error refreshing report', 'error', 2500);
|
|
213
|
+
return;
|
|
253
214
|
}
|
|
254
|
-
|
|
215
|
+
// it worked, refresh the report here
|
|
216
|
+
const newSkipData = JSON.parse(resultObj.Result);
|
|
217
|
+
this.SkipData.analysis = newSkipData.analysis; // update the analysis
|
|
218
|
+
this.SkipData.executionResults = newSkipData.executionResults; // drives the chart/table bindings
|
|
219
|
+
this.SkipData.dataContext = newSkipData.dataContext; // drives the HTML report bindings
|
|
220
|
+
// make sure to push the techExplanation and userExplanation to the newSkipData object as that WILL NOT come back with that info from the original report
|
|
221
|
+
newSkipData.userExplanation = this.SkipData.userExplanation;
|
|
222
|
+
newSkipData.techExplanation = this.SkipData.techExplanation;
|
|
223
|
+
newSkipData.resultType = this.SkipData.resultType;
|
|
224
|
+
newSkipData.responsePhase = this.SkipData.responsePhase;
|
|
225
|
+
newSkipData.messages = this.SkipData.messages; // this is the array of messages that are used to create the report from the original message, we don't want message from the refresh, it is simple message
|
|
226
|
+
newSkipData.reportTitle = this.SkipData.reportTitle; // legacy property, carry it over if it exists
|
|
227
|
+
newSkipData.title = this.SkipData.title || this.SkipData.reportTitle; // favor the new title but fallback to the legacy reportTitle. This is the title of the component, we don't want to change it
|
|
228
|
+
newSkipData.drillDown = this.SkipData.drillDown; // this is the drill down data, we don't want to change it
|
|
229
|
+
this.ReportEntity.Configuration = JSON.stringify(newSkipData);
|
|
230
|
+
const saveResult = await this.ReportEntity.Save();
|
|
231
|
+
if (!saveResult) {
|
|
232
|
+
LogError('Error refreshing report: failed to save report entity', undefined, this.ReportEntity.LatestResult);
|
|
255
233
|
this.RaiseUserNotification('Error refreshing report', 'error', 2500);
|
|
256
|
-
console.error(err);
|
|
257
234
|
}
|
|
258
|
-
|
|
235
|
+
else {
|
|
236
|
+
this.RaiseUserNotification('Report refreshed', 'success', 2500);
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
catch (err) {
|
|
240
|
+
this.RaiseUserNotification('Error refreshing report', 'error', 2500);
|
|
241
|
+
console.error(err);
|
|
242
|
+
}
|
|
259
243
|
}
|
|
244
|
+
static ɵfac = function SkipDynamicReportBase_Factory(t) { return new (t || SkipDynamicReportBase)(i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
245
|
+
static ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: SkipDynamicReportBase, inputs: { SkipData: "SkipData", ShowCreateReportButton: "ShowCreateReportButton", ConversationID: "ConversationID", ConversationName: "ConversationName", ConversationDetailID: "ConversationDetailID", DataContext: "DataContext", ReportEntity: "ReportEntity" }, outputs: { UserNotification: "UserNotification", NavigateToMatchingReport: "NavigateToMatchingReport", NewReportCreated: "NewReportCreated", DrillDownEvent: "DrillDownEvent" }, features: [i0.ɵɵInheritDefinitionFeature] });
|
|
260
246
|
}
|
|
261
|
-
SkipDynamicReportBase._reportCache = [];
|
|
262
|
-
SkipDynamicReportBase.ɵfac = function SkipDynamicReportBase_Factory(t) { return new (t || SkipDynamicReportBase)(i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
263
|
-
SkipDynamicReportBase.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: SkipDynamicReportBase, inputs: { SkipData: "SkipData", ShowCreateReportButton: "ShowCreateReportButton", ConversationID: "ConversationID", ConversationName: "ConversationName", ConversationDetailID: "ConversationDetailID", DataContext: "DataContext", ReportEntity: "ReportEntity" }, outputs: { UserNotification: "UserNotification", NavigateToMatchingReport: "NavigateToMatchingReport", NewReportCreated: "NewReportCreated", DrillDownEvent: "DrillDownEvent" }, features: [i0.ɵɵInheritDefinitionFeature] });
|
|
264
247
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SkipDynamicReportBase, [{
|
|
265
248
|
type: Directive
|
|
266
249
|
}], () => [{ type: i0.ChangeDetectorRef }], { SkipData: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-report.js","sourceRoot":"","sources":["../../../src/lib/dynamic-report/base-report.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"base-report.js","sourceRoot":"","sources":["../../../src/lib/dynamic-report/base-report.ts"],"names":[],"mappings":"AAAA,OAAO,EAA+C,SAAS,EAAE,YAAY,EAAE,KAAK,EAAU,MAAM,EAAE,MAAM,eAAe,CAAC;AAC5H,OAAO,EAAuC,QAAQ,EAAqB,MAAM,sBAAsB,CAAC;AAGxG,OAAO,EAAE,+BAA+B,EAAE,MAAM,wBAAwB,CAAC;AAEzE,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAErE,OAAO,EAAE,2BAA2B,EAAE,MAAM,iBAAiB,CAAC;;AAI9D,MAAM,OAAgB,qBAAuB,SAAQ,oBAAoB;IA4BjD;IA3Bb,QAAQ,CAA8C;IACtD,sBAAsB,GAAY,KAAK,CAAC;IACxC,cAAc,GAAkB,IAAI,CAAC;IACrC,gBAAgB,GAAkB,IAAI,CAAC;IACvC,oBAAoB,GAAkB,IAAI,CAAC;IAC3C,WAAW,CAAe;IAC1B,YAAY,CAAgB;IAE3B,gBAAgB,GAAG,IAAI,YAAY,EAAmG,CAAC;IAEjJ;;;OAGG;IACO,wBAAwB,GAAG,IAAI,YAAY,EAAU,CAAC;IAEhE;;OAEG;IACO,gBAAgB,GAAG,IAAI,YAAY,EAAU,CAAC;IAExD;;OAEG;IACO,cAAc,GAAG,IAAI,YAAY,EAAiB,CAAC;IAG7D,YAAsB,KAAwB;QAC5C,KAAK,EAAE,CAAC;QADY,UAAK,GAAL,KAAK,CAAmB;IAE9C,CAAC;IAED,eAAe;QACb,IAAI,CAAC,qBAAqB,EAAE,CAAC;IAC/B,CAAC;IAGM,gB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