@posiwise/flows 0.0.2 → 0.0.3
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/fesm2022/posiwise-flows.mjs +1739 -684
- package/fesm2022/posiwise-flows.mjs.map +1 -1
- package/package.json +1 -1
- package/types/posiwise-flows.d.ts +545 -135
|
@@ -1,28 +1,30 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import { ChangeDetectionStrategy, Component, EventEmitter, HostBinding, Injectable, Input, NgModule, Output, ViewChild } from "@angular/core";
|
|
3
|
-
import * as
|
|
2
|
+
import { ChangeDetectionStrategy, Component, EventEmitter, HostBinding, HostListener, Injectable, Input, NgModule, Output, ViewChild, afterEveryRender } from "@angular/core";
|
|
3
|
+
import * as i8 from "@angular/router";
|
|
4
4
|
import { RouterModule } from "@angular/router";
|
|
5
5
|
import * as i3$1 from "@posiwise/core-guards";
|
|
6
6
|
import { PageAccessGuard, TrackDirtyFormDirective } from "@posiwise/core-guards";
|
|
7
7
|
import { AppBaseComponent } from "@posiwise/app-base-component";
|
|
8
|
-
import { Subject, combineLatest, forkJoin, throwError, timer } from "rxjs";
|
|
9
|
-
import { catchError, distinctUntilChanged, exhaustMap, finalize, map, shareReplay, takeUntil, takeWhile, tap } from "rxjs/operators";
|
|
10
|
-
import { faArrowAltCircleLeft, faBolt, faCircleCheck, faCircleExclamation, faCode, faCodeBranch, faCopy, faDiagramProject, faExpand, faEye, faLayerGroup, faMagnifyingGlass, faPaperPlane, faPenToSquare, faPlusCircle, faTableList, faTrash, faTriangleExclamation } from "@fortawesome/free-solid-svg-icons";
|
|
8
|
+
import { Subject, combineLatest, forkJoin, of, throwError, timer } from "rxjs";
|
|
9
|
+
import { catchError, distinctUntilChanged, exhaustMap, finalize, map, shareReplay, switchMap, takeUntil, takeWhile, tap } from "rxjs/operators";
|
|
10
|
+
import { faArrowAltCircleLeft, faBolt, faChevronDown, faChevronRight, faCircleCheck, faCircleExclamation, faCode, faCodeBranch, faCopy, faDiagramProject, faExpand, faEye, faLayerGroup, faMagnifyingGlass, faPaperPlane, faPenToSquare, faPlusCircle, faTableList, faTrash, faTriangleExclamation } from "@fortawesome/free-solid-svg-icons";
|
|
11
11
|
import { FLOWS_NODES_PATH, FLOWS_RUNS_PATH, FLOWS_RUN_POLL_INTERVAL_MS, FLOWS_VERSIONS_PATH, FLOWS_WORKFLOWS_PATH } from "@posiwise/flows-shared";
|
|
12
|
+
import * as i1$3 from "@posiwise/shared-product-services";
|
|
12
13
|
import { HelperService } from "@posiwise/helper-service";
|
|
13
|
-
import * as
|
|
14
|
-
import * as i2$2 from "@posiwise/app-loader";
|
|
14
|
+
import * as i4$1 from "@posiwise/app-loader";
|
|
15
15
|
import { AppLoaderModule } from "@posiwise/app-loader";
|
|
16
|
-
import * as
|
|
17
|
-
import * as
|
|
18
|
-
import * as i5 from "@posiwise/shared-components";
|
|
16
|
+
import * as i5 from "primeng/table";
|
|
17
|
+
import * as i6 from "@posiwise/shared-components";
|
|
19
18
|
import { SharedComponentsModule } from "@posiwise/shared-components";
|
|
20
|
-
import * as
|
|
19
|
+
import * as i2$3 from "@fortawesome/angular-fontawesome";
|
|
21
20
|
import { FontAwesomeModule } from "@fortawesome/angular-fontawesome";
|
|
22
|
-
import * as
|
|
21
|
+
import * as i1$2 from "@angular/common";
|
|
23
22
|
import { CommonModule } from "@angular/common";
|
|
24
|
-
import * as
|
|
23
|
+
import * as i2$4 from "@jsverse/transloco";
|
|
25
24
|
import { TRANSLOCO_SCOPE } from "@jsverse/transloco";
|
|
25
|
+
import * as i1$1 from "primeng/tooltip";
|
|
26
|
+
import * as i13 from "@posiwise/pipes";
|
|
27
|
+
import { PipesModule } from "@posiwise/pipes";
|
|
26
28
|
import * as i3$2 from "@angular/forms";
|
|
27
29
|
import { FormsModule, ReactiveFormsModule, UntypedFormBuilder, Validators } from "@angular/forms";
|
|
28
30
|
import * as i4 from "primeng/select";
|
|
@@ -30,13 +32,14 @@ import * as i1 from "@posiwise/common-services";
|
|
|
30
32
|
import { PERMISSION_NAMES } from "@posiwise/common-utilities";
|
|
31
33
|
import { AreaExtensions, AreaPlugin } from "rete-area-plugin";
|
|
32
34
|
import { ClassicPreset, NodeEditor } from "rete";
|
|
33
|
-
import * as i2$
|
|
35
|
+
import * as i2$2 from "rete-angular-plugin/22";
|
|
34
36
|
import { AngularPlugin, Presets, ReteModule } from "rete-angular-plugin/22";
|
|
35
37
|
import { ConnectionPlugin, Presets as Presets$1 } from "rete-connection-plugin";
|
|
36
|
-
import * as i2 from "@posiwise/utils";
|
|
38
|
+
import * as i2$1 from "@posiwise/utils";
|
|
37
39
|
import { takeUntilDestroyed } from "@angular/core/rxjs-interop";
|
|
38
40
|
import * as i3 from "primeng/autocomplete";
|
|
39
41
|
import { AutoCompleteModule } from "primeng/autocomplete";
|
|
42
|
+
import * as i2 from "ngx-ui-switch";
|
|
40
43
|
import * as i9 from "primeng/iconfield";
|
|
41
44
|
import { IconFieldModule } from "primeng/iconfield";
|
|
42
45
|
import * as i10 from "primeng/inputicon";
|
|
@@ -58,7 +61,9 @@ const FLOWS_ICONS = {
|
|
|
58
61
|
fit: faExpand,
|
|
59
62
|
diagram: faDiagramProject,
|
|
60
63
|
json: faCode,
|
|
61
|
-
warning: faTriangleExclamation
|
|
64
|
+
warning: faTriangleExclamation,
|
|
65
|
+
collapsed: faChevronRight,
|
|
66
|
+
expanded: faChevronDown
|
|
62
67
|
};
|
|
63
68
|
const FLOW_CATEGORY_ICONS = {
|
|
64
69
|
trigger: faBolt,
|
|
@@ -66,6 +71,57 @@ const FLOW_CATEGORY_ICONS = {
|
|
|
66
71
|
data: faTableList,
|
|
67
72
|
action: faPaperPlane
|
|
68
73
|
};
|
|
74
|
+
const FLOW_NODE_CATEGORIES = [
|
|
75
|
+
"trigger",
|
|
76
|
+
"logic",
|
|
77
|
+
"data",
|
|
78
|
+
"action"
|
|
79
|
+
];
|
|
80
|
+
const DEFAULT_FLOW_BRANCH = "next";
|
|
81
|
+
const FLOW_RETRY_DEFAULT = {
|
|
82
|
+
times: 3,
|
|
83
|
+
wait_seconds: 30
|
|
84
|
+
};
|
|
85
|
+
function emptyFlowGraph() {
|
|
86
|
+
return {
|
|
87
|
+
nodes: [],
|
|
88
|
+
edges: []
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
function isRecord(value) {
|
|
92
|
+
return !!value && typeof value === "object" && !Array.isArray(value);
|
|
93
|
+
}
|
|
94
|
+
function toFlowGraph(value) {
|
|
95
|
+
if (!isRecord(value)) return emptyFlowGraph();
|
|
96
|
+
const nodes = Array.isArray(value["nodes"]) ? value["nodes"] : [];
|
|
97
|
+
const edges = Array.isArray(value["edges"]) ? value["edges"] : [];
|
|
98
|
+
return {
|
|
99
|
+
nodes: nodes.filter((node) => isRecord(node) && typeof node["id"] === "string" && typeof node["type"] === "string"),
|
|
100
|
+
edges: edges.filter((edge) => isRecord(edge) && typeof edge["from"] === "string" && typeof edge["to"] === "string")
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
function nextId(prefix, taken) {
|
|
104
|
+
const pattern = new RegExp(String.raw`^${prefix}(\d+)$`);
|
|
105
|
+
return `${prefix}${taken.reduce((max, id) => {
|
|
106
|
+
const match = pattern.exec(id);
|
|
107
|
+
return match ? Math.max(max, Number(match[1])) : max;
|
|
108
|
+
}, 0) + 1}`;
|
|
109
|
+
}
|
|
110
|
+
function nextFlowNodeId(nodes) {
|
|
111
|
+
return nextId("n", nodes.map((node) => node.id));
|
|
112
|
+
}
|
|
113
|
+
function nextFlowEdgeId(edges) {
|
|
114
|
+
return nextId("e", edges.map((edge) => edge.id ?? ""));
|
|
115
|
+
}
|
|
116
|
+
function flowNodeLabelKey(type) {
|
|
117
|
+
return `Flows.Nodes.${type}`;
|
|
118
|
+
}
|
|
119
|
+
function flowNodeWithRetry(node, retry) {
|
|
120
|
+
const next = { ...node };
|
|
121
|
+
if (retry) next.retry = retry;
|
|
122
|
+
else delete next.retry;
|
|
123
|
+
return next;
|
|
124
|
+
}
|
|
69
125
|
const BADGE_BASE = "pw-flow-badge";
|
|
70
126
|
function flowBadgeClass(tone) {
|
|
71
127
|
return `${BADGE_BASE} ${BADGE_BASE}--${tone}`;
|
|
@@ -102,6 +158,74 @@ function flowRunStepBadgeClass(status) {
|
|
|
102
158
|
default: return flowBadgeClass("info");
|
|
103
159
|
}
|
|
104
160
|
}
|
|
161
|
+
function flowRunScheduledFor(run) {
|
|
162
|
+
const payload = run?.trigger_payload;
|
|
163
|
+
return typeof payload?.scheduled_for === "string" ? payload.scheduled_for : null;
|
|
164
|
+
}
|
|
165
|
+
var FlowsNodeService = class FlowsNodeService {
|
|
166
|
+
constructor(api) {
|
|
167
|
+
this.api = api;
|
|
168
|
+
this.cache = /* @__PURE__ */ new Map();
|
|
169
|
+
}
|
|
170
|
+
getNodes(subscriptionId) {
|
|
171
|
+
let nodes = this.cache.get(subscriptionId);
|
|
172
|
+
if (!nodes) {
|
|
173
|
+
nodes = this.api.getWithParams(FLOWS_NODES_PATH, { subscription_id: subscriptionId }).pipe(map((response) => response.flow_nodes), catchError((error) => {
|
|
174
|
+
this.cache.delete(subscriptionId);
|
|
175
|
+
return throwError(() => error);
|
|
176
|
+
}), shareReplay({
|
|
177
|
+
bufferSize: 1,
|
|
178
|
+
refCount: false
|
|
179
|
+
}));
|
|
180
|
+
this.cache.set(subscriptionId, nodes);
|
|
181
|
+
}
|
|
182
|
+
return nodes;
|
|
183
|
+
}
|
|
184
|
+
static {
|
|
185
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
186
|
+
minVersion: "12.0.0",
|
|
187
|
+
version: "22.2.0",
|
|
188
|
+
ngImport: i0,
|
|
189
|
+
type: FlowsNodeService,
|
|
190
|
+
deps: [{ token: i1$3.ProductsHttpService }],
|
|
191
|
+
target: i0.ɵɵFactoryTarget.Injectable
|
|
192
|
+
});
|
|
193
|
+
}
|
|
194
|
+
static {
|
|
195
|
+
this.ɵprov = i0.ɵɵngDeclareInjectable({
|
|
196
|
+
minVersion: "12.0.0",
|
|
197
|
+
version: "22.2.0",
|
|
198
|
+
ngImport: i0,
|
|
199
|
+
type: FlowsNodeService,
|
|
200
|
+
providedIn: "root"
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
};
|
|
204
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
205
|
+
minVersion: "12.0.0",
|
|
206
|
+
version: "22.2.0",
|
|
207
|
+
ngImport: i0,
|
|
208
|
+
type: FlowsNodeService,
|
|
209
|
+
decorators: [{
|
|
210
|
+
type: Injectable,
|
|
211
|
+
args: [{ providedIn: "root" }]
|
|
212
|
+
}],
|
|
213
|
+
ctorParameters: () => [{ type: i1$3.ProductsHttpService }]
|
|
214
|
+
});
|
|
215
|
+
const NO_FLOW_WORKFLOW_FIELDS = {
|
|
216
|
+
byNode: {},
|
|
217
|
+
ran: false
|
|
218
|
+
};
|
|
219
|
+
function flowNodeFieldsKey(nodeId, type) {
|
|
220
|
+
return `${nodeId}|${type ?? ""}`;
|
|
221
|
+
}
|
|
222
|
+
function toFlowWorkflowFields(rows) {
|
|
223
|
+
const list = rows ?? [];
|
|
224
|
+
return {
|
|
225
|
+
byNode: Object.fromEntries(list.map((row) => [flowNodeFieldsKey(row.node_id, row.node_type), row.item_fields])),
|
|
226
|
+
ran: list.length > 0
|
|
227
|
+
};
|
|
228
|
+
}
|
|
105
229
|
var FlowsRunService = class FlowsRunService {
|
|
106
230
|
constructor(api) {
|
|
107
231
|
this.api = api;
|
|
@@ -135,6 +259,9 @@ var FlowsRunService = class FlowsRunService {
|
|
|
135
259
|
hasUnsettledRun(response) {
|
|
136
260
|
return (response?.flow_runs ?? []).some((run) => !isFlowRunTerminal(run));
|
|
137
261
|
}
|
|
262
|
+
getWorkflowFields(workflowId, subscriptionId) {
|
|
263
|
+
return this.api.getWithParams(`${FLOWS_WORKFLOWS_PATH}/${workflowId}/fields`, { subscription_id: subscriptionId }).pipe(map((response) => toFlowWorkflowFields(response.flow_workflow_fields)), catchError(() => of(NO_FLOW_WORKFLOW_FIELDS)));
|
|
264
|
+
}
|
|
138
265
|
definedQuery(query) {
|
|
139
266
|
const params = {};
|
|
140
267
|
if (query.status) params["status"] = query.status;
|
|
@@ -148,7 +275,7 @@ var FlowsRunService = class FlowsRunService {
|
|
|
148
275
|
version: "22.2.0",
|
|
149
276
|
ngImport: i0,
|
|
150
277
|
type: FlowsRunService,
|
|
151
|
-
deps: [{ token: i1$
|
|
278
|
+
deps: [{ token: i1$3.ProductsHttpService }],
|
|
152
279
|
target: i0.ɵɵFactoryTarget.Injectable
|
|
153
280
|
});
|
|
154
281
|
}
|
|
@@ -171,90 +298,157 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
171
298
|
type: Injectable,
|
|
172
299
|
args: [{ providedIn: "root" }]
|
|
173
300
|
}],
|
|
174
|
-
ctorParameters: () => [{ type: i1$
|
|
301
|
+
ctorParameters: () => [{ type: i1$3.ProductsHttpService }]
|
|
175
302
|
});
|
|
176
|
-
var
|
|
177
|
-
constructor(
|
|
178
|
-
|
|
179
|
-
this.flowsRunService = flowsRunService;
|
|
180
|
-
this.cdr = cdr;
|
|
181
|
-
this.destroy$ = new Subject();
|
|
182
|
-
this.loading = true;
|
|
183
|
-
this.notFound = false;
|
|
184
|
-
this.steps = [];
|
|
185
|
-
this.icons = FLOWS_ICONS;
|
|
186
|
-
this.openSteps = /* @__PURE__ */ new Set();
|
|
187
|
-
this.trackByStep = (_, step) => step.id;
|
|
303
|
+
var FlowsWorkflowService = class FlowsWorkflowService {
|
|
304
|
+
constructor(api) {
|
|
305
|
+
this.api = api;
|
|
188
306
|
}
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
return;
|
|
195
|
-
}
|
|
196
|
-
this.watch(subscriptionId);
|
|
307
|
+
getWorkflows(subscriptionId, status, paging) {
|
|
308
|
+
return this.api.getWithParams(`${FLOWS_WORKFLOWS_PATH}/get_all`, {
|
|
309
|
+
subscription_id: subscriptionId,
|
|
310
|
+
...status ? { status } : {},
|
|
311
|
+
...HelperService.getPagingParams(paging)
|
|
197
312
|
});
|
|
198
313
|
}
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
this.watch$?.unsubscribe();
|
|
202
|
-
this.destroy$.next();
|
|
203
|
-
this.destroy$.complete();
|
|
314
|
+
getWorkflow(id, subscriptionId) {
|
|
315
|
+
return this.api.getWithParams(`${FLOWS_WORKFLOWS_PATH}/${id}`, { subscription_id: subscriptionId });
|
|
204
316
|
}
|
|
205
|
-
|
|
206
|
-
this.
|
|
317
|
+
getVersion(id, subscriptionId) {
|
|
318
|
+
return this.api.getWithParams(`${FLOWS_VERSIONS_PATH}/${id}`, { subscription_id: subscriptionId });
|
|
207
319
|
}
|
|
208
|
-
|
|
209
|
-
return
|
|
320
|
+
createWorkflow(subscriptionId, attrs) {
|
|
321
|
+
return this.api.post(FLOWS_WORKFLOWS_PATH, {
|
|
322
|
+
subscription_id: subscriptionId,
|
|
323
|
+
...attrs
|
|
324
|
+
});
|
|
210
325
|
}
|
|
211
|
-
|
|
212
|
-
return
|
|
326
|
+
updateWorkflow(id, subscriptionId, attrs) {
|
|
327
|
+
return this.api.put(`${FLOWS_WORKFLOWS_PATH}/${id}`, {
|
|
328
|
+
subscription_id: subscriptionId,
|
|
329
|
+
...attrs
|
|
330
|
+
});
|
|
213
331
|
}
|
|
214
|
-
|
|
215
|
-
return
|
|
332
|
+
deleteWorkflow(id, subscriptionId) {
|
|
333
|
+
return this.api.delete(`${FLOWS_WORKFLOWS_PATH}/${id}`, { params: { subscription_id: String(subscriptionId) } });
|
|
216
334
|
}
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
335
|
+
getVersions(workflowId, subscriptionId, paging) {
|
|
336
|
+
return this.api.getWithParams(`${FLOWS_WORKFLOWS_PATH}/${workflowId}/versions`, {
|
|
337
|
+
subscription_id: subscriptionId,
|
|
338
|
+
...HelperService.getPagingParams(paging)
|
|
339
|
+
});
|
|
220
340
|
}
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
341
|
+
createVersion(workflowId, subscriptionId, graph) {
|
|
342
|
+
return this.api.post(`${FLOWS_WORKFLOWS_PATH}/${workflowId}/versions`, {
|
|
343
|
+
subscription_id: subscriptionId,
|
|
344
|
+
graph
|
|
345
|
+
});
|
|
224
346
|
}
|
|
225
|
-
|
|
226
|
-
this.
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
this.run = detail.run;
|
|
230
|
-
this.steps = detail.steps?.flow_run_steps ?? [];
|
|
231
|
-
this.notFound = false;
|
|
232
|
-
this.settle();
|
|
233
|
-
},
|
|
234
|
-
error: () => this.fail()
|
|
347
|
+
updateVersion(id, subscriptionId, graph) {
|
|
348
|
+
return this.api.put(`${FLOWS_VERSIONS_PATH}/${id}`, {
|
|
349
|
+
subscription_id: subscriptionId,
|
|
350
|
+
graph
|
|
235
351
|
});
|
|
236
352
|
}
|
|
237
|
-
|
|
238
|
-
this.
|
|
353
|
+
checkGraph(workflowId, subscriptionId, graph) {
|
|
354
|
+
return this.api.post(`${FLOWS_WORKFLOWS_PATH}/${workflowId}/versions/check`, {
|
|
355
|
+
subscription_id: subscriptionId,
|
|
356
|
+
graph
|
|
357
|
+
});
|
|
358
|
+
}
|
|
359
|
+
publishVersion(id, subscriptionId) {
|
|
360
|
+
return this.api.put(`${FLOWS_VERSIONS_PATH}/${id}/publish`, { subscription_id: subscriptionId });
|
|
361
|
+
}
|
|
362
|
+
publishChecked(workflowId, version, subscriptionId) {
|
|
363
|
+
return this.checkGraph(workflowId, subscriptionId, version.graph).pipe(switchMap((check) => check.valid ? this.publishVersion(version.id, subscriptionId) : of(check)));
|
|
364
|
+
}
|
|
365
|
+
static {
|
|
366
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
367
|
+
minVersion: "12.0.0",
|
|
368
|
+
version: "22.2.0",
|
|
369
|
+
ngImport: i0,
|
|
370
|
+
type: FlowsWorkflowService,
|
|
371
|
+
deps: [{ token: i1$3.ProductsHttpService }],
|
|
372
|
+
target: i0.ɵɵFactoryTarget.Injectable
|
|
373
|
+
});
|
|
374
|
+
}
|
|
375
|
+
static {
|
|
376
|
+
this.ɵprov = i0.ɵɵngDeclareInjectable({
|
|
377
|
+
minVersion: "12.0.0",
|
|
378
|
+
version: "22.2.0",
|
|
379
|
+
ngImport: i0,
|
|
380
|
+
type: FlowsWorkflowService,
|
|
381
|
+
providedIn: "root"
|
|
382
|
+
});
|
|
383
|
+
}
|
|
384
|
+
};
|
|
385
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
386
|
+
minVersion: "12.0.0",
|
|
387
|
+
version: "22.2.0",
|
|
388
|
+
ngImport: i0,
|
|
389
|
+
type: FlowsWorkflowService,
|
|
390
|
+
decorators: [{
|
|
391
|
+
type: Injectable,
|
|
392
|
+
args: [{ providedIn: "root" }]
|
|
393
|
+
}],
|
|
394
|
+
ctorParameters: () => [{ type: i1$3.ProductsHttpService }]
|
|
395
|
+
});
|
|
396
|
+
function flowRunProgress(steps, nodeIds) {
|
|
397
|
+
const count = (...statuses) => steps.filter((step) => statuses.includes(step.status)).length;
|
|
398
|
+
const stepped = new Set(steps.map((step) => step.node_id));
|
|
399
|
+
const waiting = nodeIds.filter((id) => !stepped.has(id)).length;
|
|
400
|
+
const total = steps.length + waiting;
|
|
401
|
+
const done = count("succeeded");
|
|
402
|
+
const failed = count("failed");
|
|
403
|
+
const skipped = count("skipped");
|
|
404
|
+
const settled = done + failed + skipped;
|
|
405
|
+
return {
|
|
406
|
+
done,
|
|
407
|
+
failed,
|
|
408
|
+
skipped,
|
|
409
|
+
settled,
|
|
410
|
+
running: count("pending", "running", "awaiting"),
|
|
411
|
+
waiting,
|
|
412
|
+
total,
|
|
413
|
+
percent: total ? Math.round(settled / total * 100) : 0
|
|
414
|
+
};
|
|
415
|
+
}
|
|
416
|
+
var FlowsRunProgressComponent = class FlowsRunProgressComponent {
|
|
417
|
+
constructor(cdr) {
|
|
418
|
+
this.cdr = cdr;
|
|
239
419
|
this.steps = [];
|
|
240
|
-
this.
|
|
241
|
-
this.
|
|
420
|
+
this.nodeIds = [];
|
|
421
|
+
this.progress = flowRunProgress([], []);
|
|
422
|
+
this.elapsed = null;
|
|
242
423
|
}
|
|
243
|
-
|
|
244
|
-
this.
|
|
245
|
-
|
|
424
|
+
get ended() {
|
|
425
|
+
return isFlowRunTerminal(this.run);
|
|
426
|
+
}
|
|
427
|
+
ngOnChanges() {
|
|
428
|
+
this.progress = flowRunProgress(this.steps, this.nodeIds);
|
|
429
|
+
this.updateElapsed();
|
|
430
|
+
if (this.ended) {
|
|
431
|
+
this.tick$?.unsubscribe();
|
|
432
|
+
this.tick$ = void 0;
|
|
433
|
+
} else if (!this.tick$) this.tick$ = timer(1e3, 1e3).subscribe(() => {
|
|
434
|
+
this.updateElapsed();
|
|
435
|
+
this.cdr.markForCheck();
|
|
436
|
+
});
|
|
437
|
+
}
|
|
438
|
+
ngOnDestroy() {
|
|
439
|
+
this.tick$?.unsubscribe();
|
|
440
|
+
}
|
|
441
|
+
updateElapsed() {
|
|
442
|
+
const until = this.ended ? this.run.finished_at : (/* @__PURE__ */ new Date()).toISOString();
|
|
443
|
+
this.elapsed = elapsedMs(this.run.started_at, until);
|
|
246
444
|
}
|
|
247
445
|
static {
|
|
248
446
|
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
249
447
|
minVersion: "12.0.0",
|
|
250
448
|
version: "22.2.0",
|
|
251
449
|
ngImport: i0,
|
|
252
|
-
type:
|
|
253
|
-
deps: [
|
|
254
|
-
{ token: i0.Injector },
|
|
255
|
-
{ token: FlowsRunService },
|
|
256
|
-
{ token: i0.ChangeDetectorRef }
|
|
257
|
-
],
|
|
450
|
+
type: FlowsRunProgressComponent,
|
|
451
|
+
deps: [{ token: i0.ChangeDetectorRef }],
|
|
258
452
|
target: i0.ɵɵFactoryTarget.Component
|
|
259
453
|
});
|
|
260
454
|
}
|
|
@@ -262,27 +456,143 @@ var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBas
|
|
|
262
456
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
263
457
|
minVersion: "17.0.0",
|
|
264
458
|
version: "22.2.0",
|
|
265
|
-
type:
|
|
459
|
+
type: FlowsRunProgressComponent,
|
|
266
460
|
isStandalone: false,
|
|
267
|
-
selector: "pw-flows-run-
|
|
268
|
-
|
|
461
|
+
selector: "pw-flows-run-progress",
|
|
462
|
+
inputs: {
|
|
463
|
+
run: "run",
|
|
464
|
+
steps: "steps",
|
|
465
|
+
nodeIds: "nodeIds"
|
|
466
|
+
},
|
|
467
|
+
usesOnChanges: true,
|
|
269
468
|
ngImport: i0,
|
|
270
|
-
template: "<div class=\"
|
|
271
|
-
styles: [".pw-
|
|
272
|
-
dependencies: [
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
469
|
+
template: "<div class=\"pw-run-progress\"\n data-testid=\"flow-run-progress\">\n <div class=\"pw-run-progress__head\">\n <span class=\"pw-run-progress__label\">\n {{ (ended ? 'Flows.Run.Progress.Finished' : 'Flows.Run.Progress.Running') | transloco: { settled: progress.settled, total: progress.total } }}\n </span>\n @if (elapsed !== null) {\n <span class=\"pw-run-progress__elapsed\">\n {{ elapsed / 1000 | number: '1.0-0' }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n </span>\n }\n </div>\n\n <div class=\"progress pw-run-progress__bar\"\n role=\"progressbar\"\n [attr.aria-valuenow]=\"progress.percent\"\n aria-valuemin=\"0\"\n aria-valuemax=\"100\"\n [attr.aria-label]=\"'Flows.Run.Progress.Label' | transloco\">\n <!-- Width is the run's own percentage, so it cannot live in the stylesheet. -->\n <div class=\"progress-bar\"\n [class.is-failed]=\"progress.failed > 0\"\n [class.is-live]=\"!ended\"\n [style.width.%]=\"progress.percent\"></div>\n </div>\n\n <ul class=\"pw-run-progress__counts\">\n <li>{{ 'Flows.Run.Progress.Done' | transloco: { count: progress.done } }}</li>\n @if (progress.running) {\n <li class=\"is-running\">{{ 'Flows.Run.Progress.InProgress' | transloco: { count: progress.running } }}</li>\n }\n @if (progress.failed) {\n <li class=\"is-failed\">{{ 'Flows.Run.Progress.Failed' | transloco: { count: progress.failed } }}</li>\n }\n @if (progress.skipped) {\n <li>{{ 'Flows.Run.Progress.Skipped' | transloco: { count: progress.skipped } }}</li>\n }\n @if (progress.waiting) {\n <li>{{ (ended ? 'Flows.Run.Progress.NotRun' : 'Flows.Run.Progress.Waiting') | transloco: { count: progress.waiting } }}</li>\n }\n </ul>\n</div>\n",
|
|
470
|
+
styles: [".pw-run-progress{margin-bottom:16px}.pw-run-progress__head{display:flex;justify-content:space-between;gap:12px;margin-bottom:6px}.pw-run-progress__label{font-weight:600;color:#1a1d21}.pw-run-progress__elapsed{color:#5a6473}.pw-run-progress__bar{height:8px}.pw-run-progress__bar .progress-bar{background-color:var(--first);transition:width .4s ease}.pw-run-progress__bar .progress-bar.is-failed{background-color:#c0392b}.pw-run-progress__bar .progress-bar.is-live{background-image:linear-gradient(45deg,rgba(255,255,255,.2) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.2) 50%,rgba(255,255,255,.2) 75%,transparent 75%);background-size:16px 16px;animation:pw-run-progress-stripes 1s linear infinite}.pw-run-progress__counts{display:flex;flex-wrap:wrap;gap:4px 16px;list-style:none;padding:0;margin:8px 0 0;font-size:12px;color:#5a6473}.pw-run-progress__counts .is-running{color:#1a1d21}.pw-run-progress__counts .is-failed{color:#c0392b}@keyframes pw-run-progress-stripes{0%{background-position:16px 0}to{background-position:0 0}}@media(prefers-reduced-motion:reduce){.pw-run-progress__bar .progress-bar{transition:none}.pw-run-progress__bar .progress-bar.is-live{animation:none}}\n"],
|
|
471
|
+
dependencies: [{
|
|
472
|
+
kind: "pipe",
|
|
473
|
+
type: i1$2.DecimalPipe,
|
|
474
|
+
name: "number"
|
|
475
|
+
}, {
|
|
476
|
+
kind: "pipe",
|
|
477
|
+
type: i2$4.TranslocoPipe,
|
|
478
|
+
name: "transloco"
|
|
479
|
+
}]
|
|
480
|
+
});
|
|
481
|
+
}
|
|
482
|
+
};
|
|
483
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
484
|
+
minVersion: "12.0.0",
|
|
485
|
+
version: "22.2.0",
|
|
486
|
+
ngImport: i0,
|
|
487
|
+
type: FlowsRunProgressComponent,
|
|
488
|
+
decorators: [{
|
|
489
|
+
type: Component,
|
|
490
|
+
args: [{
|
|
491
|
+
selector: "pw-flows-run-progress",
|
|
492
|
+
standalone: false,
|
|
493
|
+
template: "<div class=\"pw-run-progress\"\n data-testid=\"flow-run-progress\">\n <div class=\"pw-run-progress__head\">\n <span class=\"pw-run-progress__label\">\n {{ (ended ? 'Flows.Run.Progress.Finished' : 'Flows.Run.Progress.Running') | transloco: { settled: progress.settled, total: progress.total } }}\n </span>\n @if (elapsed !== null) {\n <span class=\"pw-run-progress__elapsed\">\n {{ elapsed / 1000 | number: '1.0-0' }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n </span>\n }\n </div>\n\n <div class=\"progress pw-run-progress__bar\"\n role=\"progressbar\"\n [attr.aria-valuenow]=\"progress.percent\"\n aria-valuemin=\"0\"\n aria-valuemax=\"100\"\n [attr.aria-label]=\"'Flows.Run.Progress.Label' | transloco\">\n <!-- Width is the run's own percentage, so it cannot live in the stylesheet. -->\n <div class=\"progress-bar\"\n [class.is-failed]=\"progress.failed > 0\"\n [class.is-live]=\"!ended\"\n [style.width.%]=\"progress.percent\"></div>\n </div>\n\n <ul class=\"pw-run-progress__counts\">\n <li>{{ 'Flows.Run.Progress.Done' | transloco: { count: progress.done } }}</li>\n @if (progress.running) {\n <li class=\"is-running\">{{ 'Flows.Run.Progress.InProgress' | transloco: { count: progress.running } }}</li>\n }\n @if (progress.failed) {\n <li class=\"is-failed\">{{ 'Flows.Run.Progress.Failed' | transloco: { count: progress.failed } }}</li>\n }\n @if (progress.skipped) {\n <li>{{ 'Flows.Run.Progress.Skipped' | transloco: { count: progress.skipped } }}</li>\n }\n @if (progress.waiting) {\n <li>{{ (ended ? 'Flows.Run.Progress.NotRun' : 'Flows.Run.Progress.Waiting') | transloco: { count: progress.waiting } }}</li>\n }\n </ul>\n</div>\n",
|
|
494
|
+
styles: [".pw-run-progress{margin-bottom:16px}.pw-run-progress__head{display:flex;justify-content:space-between;gap:12px;margin-bottom:6px}.pw-run-progress__label{font-weight:600;color:#1a1d21}.pw-run-progress__elapsed{color:#5a6473}.pw-run-progress__bar{height:8px}.pw-run-progress__bar .progress-bar{background-color:var(--first);transition:width .4s ease}.pw-run-progress__bar .progress-bar.is-failed{background-color:#c0392b}.pw-run-progress__bar .progress-bar.is-live{background-image:linear-gradient(45deg,rgba(255,255,255,.2) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.2) 50%,rgba(255,255,255,.2) 75%,transparent 75%);background-size:16px 16px;animation:pw-run-progress-stripes 1s linear infinite}.pw-run-progress__counts{display:flex;flex-wrap:wrap;gap:4px 16px;list-style:none;padding:0;margin:8px 0 0;font-size:12px;color:#5a6473}.pw-run-progress__counts .is-running{color:#1a1d21}.pw-run-progress__counts .is-failed{color:#c0392b}@keyframes pw-run-progress-stripes{0%{background-position:16px 0}to{background-position:0 0}}@media(prefers-reduced-motion:reduce){.pw-run-progress__bar .progress-bar{transition:none}.pw-run-progress__bar .progress-bar.is-live{animation:none}}\n"]
|
|
495
|
+
}]
|
|
496
|
+
}],
|
|
497
|
+
ctorParameters: () => [{ type: i0.ChangeDetectorRef }],
|
|
498
|
+
propDecorators: {
|
|
499
|
+
run: [{
|
|
500
|
+
type: Input,
|
|
501
|
+
args: [{ required: true }]
|
|
502
|
+
}],
|
|
503
|
+
steps: [{ type: Input }],
|
|
504
|
+
nodeIds: [{ type: Input }]
|
|
505
|
+
}
|
|
506
|
+
});
|
|
507
|
+
const PREFIX = "Flows.Run.Errors.";
|
|
508
|
+
const BY_CODE = {
|
|
509
|
+
awaiting_timeout: "Timeout",
|
|
510
|
+
no_credentials: "NoCredentials",
|
|
511
|
+
no_crm: "NoCrm",
|
|
512
|
+
output_too_large: "OutputTooLarge",
|
|
513
|
+
unsupported_action: "CannotRunHere",
|
|
514
|
+
unsupported_connector: "CannotRunHere",
|
|
515
|
+
unsupported_request: "CannotRunHere",
|
|
516
|
+
unsupported_shard: "CannotRunHere",
|
|
517
|
+
task_request_failed: "NotSent",
|
|
518
|
+
task_received_no_items: "NoItems",
|
|
519
|
+
email_recipients_invalid: "EmailRecipients",
|
|
520
|
+
no_shard_for_email: "EmailNotSent",
|
|
521
|
+
delivery_failed: "EmailNotSent",
|
|
522
|
+
user_not_in_subscription: "UserNotInSubscription",
|
|
523
|
+
split_out_requires_a_field: "FieldNotSet",
|
|
524
|
+
aggregate_requires_a_field: "FieldNotSet",
|
|
525
|
+
split_out_field_missing: "FieldMissing",
|
|
526
|
+
split_out_field_not_a_list: "FieldNotAList",
|
|
527
|
+
template_path_missing: "PlaceholderMissing",
|
|
528
|
+
set_fields_requires_an_object: "SetFieldsInvalid",
|
|
529
|
+
set_fields_received_a_non_object_item: "SetFieldsInvalid",
|
|
530
|
+
evaluation_failed: "ConditionFailed"
|
|
531
|
+
};
|
|
532
|
+
function callFailure(detail) {
|
|
533
|
+
const status = Number(/\b([45]\d\d)\b/.exec(detail)?.[1]);
|
|
534
|
+
if (status === 401 || status === 403) return "SignInRefused";
|
|
535
|
+
if (status === 404) return "NotFound";
|
|
536
|
+
if (status === 429) return "RateLimited";
|
|
537
|
+
return status >= 500 ? "ServiceError" : "CallFailed";
|
|
538
|
+
}
|
|
539
|
+
function flowStepErrorText(error) {
|
|
540
|
+
if (!error) return null;
|
|
541
|
+
const colon = error.indexOf(":");
|
|
542
|
+
const code = (colon === -1 ? error : error.slice(0, colon)).trim();
|
|
543
|
+
const detail = colon === -1 ? "" : error.slice(colon + 1).trim();
|
|
544
|
+
if (code === "integration_call_failed") return {
|
|
545
|
+
key: PREFIX + callFailure(detail),
|
|
546
|
+
params: {}
|
|
547
|
+
};
|
|
548
|
+
const known = BY_CODE[code];
|
|
549
|
+
return known ? {
|
|
550
|
+
key: PREFIX + known,
|
|
551
|
+
params: { detail }
|
|
552
|
+
} : {
|
|
553
|
+
key: PREFIX + "Unknown",
|
|
554
|
+
params: { detail: error }
|
|
555
|
+
};
|
|
556
|
+
}
|
|
557
|
+
var FlowsStepErrorComponent = class FlowsStepErrorComponent {
|
|
558
|
+
constructor() {
|
|
559
|
+
this.error = null;
|
|
560
|
+
this.retrying = false;
|
|
561
|
+
this.icons = FLOWS_ICONS;
|
|
562
|
+
this.text = null;
|
|
563
|
+
}
|
|
564
|
+
ngOnChanges() {
|
|
565
|
+
this.text = flowStepErrorText(this.error);
|
|
566
|
+
}
|
|
567
|
+
static {
|
|
568
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
569
|
+
minVersion: "12.0.0",
|
|
570
|
+
version: "22.2.0",
|
|
571
|
+
ngImport: i0,
|
|
572
|
+
type: FlowsStepErrorComponent,
|
|
573
|
+
deps: [],
|
|
574
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
575
|
+
});
|
|
576
|
+
}
|
|
577
|
+
static {
|
|
578
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
579
|
+
minVersion: "17.0.0",
|
|
580
|
+
version: "22.2.0",
|
|
581
|
+
type: FlowsStepErrorComponent,
|
|
582
|
+
isStandalone: false,
|
|
583
|
+
selector: "pw-flows-step-error",
|
|
584
|
+
inputs: {
|
|
585
|
+
error: "error",
|
|
586
|
+
retrying: "retrying"
|
|
587
|
+
},
|
|
588
|
+
usesOnChanges: true,
|
|
589
|
+
ngImport: i0,
|
|
590
|
+
template: "@if (text) {\n@let reason = text.key | transloco: text.params;\n<span class=\"pw-step-error\"\n [class.is-retrying]=\"retrying\"\n [pTooltip]=\"error\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon [icon]=\"retrying ? icons.warning : icons.error\"\n aria-hidden=\"true\"></fa-icon>\n</span>\n<small class=\"pw-step-error__text\"\n [class.is-retrying]=\"retrying\"\n data-testid=\"flow-step-error-text\">\n {{ retrying ? ('Flows.Run.Errors.LastTry' | transloco: { reason }) : reason }}\n</small>\n}\n",
|
|
591
|
+
styles: [":host{display:contents}.pw-step-error{margin-left:6px;color:#c0392b;cursor:help}.pw-step-error__text{display:block;max-width:280px;margin-top:4px;color:#c0392b;white-space:normal;overflow-wrap:anywhere}.pw-step-error.is-retrying,.pw-step-error__text.is-retrying{color:#8a6d00}\n"],
|
|
592
|
+
dependencies: [
|
|
283
593
|
{
|
|
284
594
|
kind: "directive",
|
|
285
|
-
type:
|
|
595
|
+
type: i1$1.Tooltip,
|
|
286
596
|
selector: "[pTooltip]",
|
|
287
597
|
inputs: [
|
|
288
598
|
"tooltipPosition",
|
|
@@ -310,7 +620,205 @@ var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBas
|
|
|
310
620
|
},
|
|
311
621
|
{
|
|
312
622
|
kind: "component",
|
|
313
|
-
type:
|
|
623
|
+
type: i2$3.FaIconComponent,
|
|
624
|
+
selector: "fa-icon",
|
|
625
|
+
inputs: [
|
|
626
|
+
"icon",
|
|
627
|
+
"title",
|
|
628
|
+
"animation",
|
|
629
|
+
"mask",
|
|
630
|
+
"flip",
|
|
631
|
+
"size",
|
|
632
|
+
"pull",
|
|
633
|
+
"border",
|
|
634
|
+
"inverse",
|
|
635
|
+
"symbol",
|
|
636
|
+
"rotate",
|
|
637
|
+
"fixedWidth",
|
|
638
|
+
"transform",
|
|
639
|
+
"a11yRole"
|
|
640
|
+
],
|
|
641
|
+
outputs: [
|
|
642
|
+
"iconChange",
|
|
643
|
+
"titleChange",
|
|
644
|
+
"animationChange",
|
|
645
|
+
"maskChange",
|
|
646
|
+
"flipChange",
|
|
647
|
+
"sizeChange",
|
|
648
|
+
"pullChange",
|
|
649
|
+
"borderChange",
|
|
650
|
+
"inverseChange",
|
|
651
|
+
"symbolChange",
|
|
652
|
+
"rotateChange",
|
|
653
|
+
"fixedWidthChange",
|
|
654
|
+
"transformChange",
|
|
655
|
+
"a11yRoleChange"
|
|
656
|
+
]
|
|
657
|
+
},
|
|
658
|
+
{
|
|
659
|
+
kind: "pipe",
|
|
660
|
+
type: i2$4.TranslocoPipe,
|
|
661
|
+
name: "transloco"
|
|
662
|
+
}
|
|
663
|
+
]
|
|
664
|
+
});
|
|
665
|
+
}
|
|
666
|
+
};
|
|
667
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
668
|
+
minVersion: "12.0.0",
|
|
669
|
+
version: "22.2.0",
|
|
670
|
+
ngImport: i0,
|
|
671
|
+
type: FlowsStepErrorComponent,
|
|
672
|
+
decorators: [{
|
|
673
|
+
type: Component,
|
|
674
|
+
args: [{
|
|
675
|
+
selector: "pw-flows-step-error",
|
|
676
|
+
standalone: false,
|
|
677
|
+
template: "@if (text) {\n@let reason = text.key | transloco: text.params;\n<span class=\"pw-step-error\"\n [class.is-retrying]=\"retrying\"\n [pTooltip]=\"error\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon [icon]=\"retrying ? icons.warning : icons.error\"\n aria-hidden=\"true\"></fa-icon>\n</span>\n<small class=\"pw-step-error__text\"\n [class.is-retrying]=\"retrying\"\n data-testid=\"flow-step-error-text\">\n {{ retrying ? ('Flows.Run.Errors.LastTry' | transloco: { reason }) : reason }}\n</small>\n}\n",
|
|
678
|
+
styles: [":host{display:contents}.pw-step-error{margin-left:6px;color:#c0392b;cursor:help}.pw-step-error__text{display:block;max-width:280px;margin-top:4px;color:#c0392b;white-space:normal;overflow-wrap:anywhere}.pw-step-error.is-retrying,.pw-step-error__text.is-retrying{color:#8a6d00}\n"]
|
|
679
|
+
}]
|
|
680
|
+
}],
|
|
681
|
+
propDecorators: {
|
|
682
|
+
error: [{ type: Input }],
|
|
683
|
+
retrying: [{ type: Input }]
|
|
684
|
+
}
|
|
685
|
+
});
|
|
686
|
+
var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBaseComponent {
|
|
687
|
+
constructor(injector, flowsRunService, workflowService, nodeService, cdr) {
|
|
688
|
+
super(injector);
|
|
689
|
+
this.flowsRunService = flowsRunService;
|
|
690
|
+
this.workflowService = workflowService;
|
|
691
|
+
this.nodeService = nodeService;
|
|
692
|
+
this.cdr = cdr;
|
|
693
|
+
this.destroy$ = new Subject();
|
|
694
|
+
this.loading = true;
|
|
695
|
+
this.notFound = false;
|
|
696
|
+
this.steps = [];
|
|
697
|
+
this.icons = FLOWS_ICONS;
|
|
698
|
+
this.openSteps = /* @__PURE__ */ new Set();
|
|
699
|
+
this.trackByStep = (_, step) => step.id;
|
|
700
|
+
this.labelKey = flowNodeLabelKey;
|
|
701
|
+
this.scheduledFor = flowRunScheduledFor;
|
|
702
|
+
this.nodeTypes = {};
|
|
703
|
+
this.nodeIds = [];
|
|
704
|
+
this.definitions = {};
|
|
705
|
+
}
|
|
706
|
+
ngOnInit() {
|
|
707
|
+
combineLatest([this.route.params.pipe(map((params) => Number(params["id"]))), this.getUserSubscriptionId()]).pipe(distinctUntilChanged(([prevRun, prevSub], [nextRun, nextSub]) => prevRun === nextRun && prevSub === nextSub), takeUntil(this.destroy$)).subscribe(([runId, subscriptionId]) => {
|
|
708
|
+
this.runId = runId;
|
|
709
|
+
if (!subscriptionId || !this.runId) {
|
|
710
|
+
this.fail();
|
|
711
|
+
return;
|
|
712
|
+
}
|
|
713
|
+
this.watch(subscriptionId);
|
|
714
|
+
});
|
|
715
|
+
}
|
|
716
|
+
ngOnDestroy() {
|
|
717
|
+
super.ngOnDestroy();
|
|
718
|
+
this.watch$?.unsubscribe();
|
|
719
|
+
this.destroy$.next();
|
|
720
|
+
this.destroy$.complete();
|
|
721
|
+
}
|
|
722
|
+
back() {
|
|
723
|
+
this.router.navigate(["runs"], { relativeTo: this.route.parent });
|
|
724
|
+
}
|
|
725
|
+
runBadgeClass(status) {
|
|
726
|
+
return flowRunBadgeClass(status);
|
|
727
|
+
}
|
|
728
|
+
stepBadgeClass(status) {
|
|
729
|
+
return flowRunStepBadgeClass(status);
|
|
730
|
+
}
|
|
731
|
+
elapsed(from, to) {
|
|
732
|
+
return elapsedMs(from, to);
|
|
733
|
+
}
|
|
734
|
+
toggleItems(stepId) {
|
|
735
|
+
if (!this.openSteps.delete(stepId)) this.openSteps.add(stepId);
|
|
736
|
+
}
|
|
737
|
+
asJson(value) {
|
|
738
|
+
if (value === null || value === void 0) return "—";
|
|
739
|
+
return JSON.stringify(value, null, 2);
|
|
740
|
+
}
|
|
741
|
+
watch(subscriptionId) {
|
|
742
|
+
this.watch$?.unsubscribe();
|
|
743
|
+
this.watch$ = this.flowsRunService.watchRun(this.runId, subscriptionId).pipe(takeUntil(this.destroy$)).subscribe({
|
|
744
|
+
next: (detail) => {
|
|
745
|
+
this.run = detail.run;
|
|
746
|
+
this.steps = detail.steps?.flow_run_steps ?? [];
|
|
747
|
+
this.nameNodes(subscriptionId);
|
|
748
|
+
this.notFound = false;
|
|
749
|
+
this.settle();
|
|
750
|
+
},
|
|
751
|
+
error: () => this.fail()
|
|
752
|
+
});
|
|
753
|
+
}
|
|
754
|
+
nameNodes(subscriptionId) {
|
|
755
|
+
const versionId = this.run?.flow_version_id;
|
|
756
|
+
if (!versionId || versionId === this.namedVersionId) return;
|
|
757
|
+
this.namedVersionId = versionId;
|
|
758
|
+
forkJoin({
|
|
759
|
+
version: this.workflowService.getVersion(versionId, subscriptionId),
|
|
760
|
+
nodes: this.nodeService.getNodes(subscriptionId)
|
|
761
|
+
}).pipe(takeUntil(this.destroy$)).subscribe({
|
|
762
|
+
next: ({ version, nodes }) => {
|
|
763
|
+
this.nodeTypes = Object.fromEntries(toFlowGraph(version.graph).nodes.map((node) => [node.id, node.type]));
|
|
764
|
+
this.nodeIds = Object.keys(this.nodeTypes);
|
|
765
|
+
this.definitions = Object.fromEntries(nodes.map((node) => [node.type, node]));
|
|
766
|
+
this.cdr.markForCheck();
|
|
767
|
+
},
|
|
768
|
+
error: () => void 0
|
|
769
|
+
});
|
|
770
|
+
}
|
|
771
|
+
fail() {
|
|
772
|
+
this.run = void 0;
|
|
773
|
+
this.steps = [];
|
|
774
|
+
this.notFound = true;
|
|
775
|
+
this.settle();
|
|
776
|
+
}
|
|
777
|
+
settle() {
|
|
778
|
+
this.loading = false;
|
|
779
|
+
this.cdr.markForCheck();
|
|
780
|
+
}
|
|
781
|
+
static {
|
|
782
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
783
|
+
minVersion: "12.0.0",
|
|
784
|
+
version: "22.2.0",
|
|
785
|
+
ngImport: i0,
|
|
786
|
+
type: FlowsRunInspectorComponent,
|
|
787
|
+
deps: [
|
|
788
|
+
{ token: i0.Injector },
|
|
789
|
+
{ token: FlowsRunService },
|
|
790
|
+
{ token: FlowsWorkflowService },
|
|
791
|
+
{ token: FlowsNodeService },
|
|
792
|
+
{ token: i0.ChangeDetectorRef }
|
|
793
|
+
],
|
|
794
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
795
|
+
});
|
|
796
|
+
}
|
|
797
|
+
static {
|
|
798
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
799
|
+
minVersion: "17.0.0",
|
|
800
|
+
version: "22.2.0",
|
|
801
|
+
type: FlowsRunInspectorComponent,
|
|
802
|
+
isStandalone: false,
|
|
803
|
+
selector: "pw-flows-run-inspector",
|
|
804
|
+
usesInheritance: true,
|
|
805
|
+
ngImport: i0,
|
|
806
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex align-items-center\">\n <a href=\"javascript:void(0)\"\n class=\"previous\"\n [attr.aria-label]=\"'Flows.Run.Back' | transloco\"\n (click)=\"back()\"><fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon></a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <!-- 🔴 Id only from the resolved run: showing it from the URL confirms a foreign run exists. -->\n <span>{{\n run\n ? ('Flows.Run.Title' | transloco: { id: runId })\n : ('Flows.Run.TitleUnknown' | transloco)\n }}</span>\n </h3>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound || !run) {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Run.NotFound' | transloco\"></pw-no-data>\n} @else {\n<div class=\"row mt-3\">\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Status' | transloco }}</span>\n <span class=\"pw-run-meta__value\">\n <span [class]=\"runBadgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </span>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</span>\n <a class=\"pw-run-meta__value\"\n [routerLink]=\"['../../workflows', run.flow_workflow_id, 'versions']\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Version' | transloco }}</span>\n <a class=\"pw-run-meta__value\"\n [routerLink]=\"['../../workflows', run.flow_workflow_id, 'versions']\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Started' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ run.started_at ? (run.started_at | dateFormat: 'datetime') : '—' }}</span>\n </div>\n </div>\n\n @if (scheduledFor(run); as slot) {\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\"\n data-testid=\"flow-run-scheduled-for\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Run.ScheduledFor' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ slot | dateFormat: 'datetime' }}</span>\n </div>\n </div>\n }\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Finished' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ run.finished_at ? (run.finished_at | dateFormat: 'datetime') : '—' }}</span>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Duration' | transloco }}</span>\n <span class=\"pw-run-meta__value\">\n @if (elapsed(run.started_at, run.finished_at) !== null) {\n {{ elapsed(run.started_at, run.finished_at) / 1000 | number: '1.0-1'\n }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n } @else {\n —\n }\n </span>\n </div>\n </div>\n\n @if (run.error) {\n <div class=\"col-12\">\n <div class=\"pw-run-error\"\n role=\"alert\">\n <span class=\"pw-run-error__label\">{{ 'Flows.Run.Meta.Error' | transloco }}</span>\n <span class=\"pw-run-error__message\">{{ run.error }}</span>\n </div>\n </div>\n }\n\n <div class=\"col-12\">\n <details class=\"pw-run-payload\">\n <summary>{{ 'Flows.Run.Meta.TriggerPayload' | transloco }}</summary>\n <pre class=\"pw-run-payload__json\">{{ asJson(run.trigger_payload) }}</pre>\n </details>\n </div>\n</div>\n\n<div class=\"row mt-4\">\n <div class=\"col-12\">\n <pw-flows-run-progress [run]=\"run\" [steps]=\"steps\" [nodeIds]=\"nodeIds\"></pw-flows-run-progress>\n <h4>{{ 'Flows.Run.Steps.Title' | transloco }}</h4>\n </div>\n</div>\n\n@if (steps.length) {\n<div class=\"primeng-datatable-container table-responsive mt-2\">\n <p-table [value]=\"steps\"\n dataKey=\"id\"\n [rowTrackBy]=\"trackByStep\">\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Run.Steps.Column.Node' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Run.Steps.Column.Attempts' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Started' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Duration' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Run.Steps.Column.Items' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-step>\n <tr>\n <td data-head=\"Node\">\n @let type = nodeTypes[step.node_id];\n @if (type) {\n @let key = labelKey(type);\n @let translated = key | transloco;\n {{ translated === key ? (definitions[type]?.label ?? type) : translated }}\n <small class=\"text-muted ms-1\">{{ step.node_id }}</small>\n } @else {\n {{ step.node_id }}\n }\n </td>\n <td data-head=\"Status\">\n <span [class]=\"stepBadgeClass(step.status)\">\n {{ (step.retry_at ? 'Flows.Status.retrying' : 'Flows.Status.' + step.status) | transloco }}\n </span>\n <pw-flows-step-error [error]=\"step.error\" [retrying]=\"!!step.retry_at\"></pw-flows-step-error>\n @if (step.retry_at) {\n <small class=\"d-block mt-1 text-muted\"\n data-testid=\"flow-step-next-try\">\n {{ 'Flows.Run.Steps.NextTry' | transloco: { time: (step.retry_at | dateFormat: 'datetime') } }}\n </small>\n }\n </td>\n <td data-head=\"Attempts\">{{ step.attempts }}</td>\n <td data-head=\"Started\">{{ step.started_at ? (step.started_at | dateFormat) : '—' }}</td>\n <td data-head=\"Duration\">\n @if (elapsed(step.started_at, step.finished_at) !== null) {\n {{ elapsed(step.started_at, step.finished_at) / 1000 | number: '1.0-1'\n }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n } @else {\n —\n }\n </td>\n <td data-head=\"Items\">\n <button type=\"button\"\n class=\"btn btn-link p-0 pw-step-toggle\"\n [attr.aria-expanded]=\"openSteps.has(step.id)\"\n [attr.aria-controls]=\"'flow-step-items-' + step.id\"\n (click)=\"toggleItems(step.id)\">\n <fa-icon [icon]=\"openSteps.has(step.id) ? icons.expanded : icons.collapsed\" aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Run.Steps.Column.Items' | transloco }}\n </button>\n </td>\n </tr>\n <!-- Its own full-width row, so opening a step never resizes the columns above. -->\n @if (openSteps.has(step.id)) {\n <tr class=\"pw-step-items-row\">\n <td colspan=\"6\"\n [id]=\"'flow-step-items-' + step.id\">\n <div class=\"pw-step-items\">\n <span class=\"pw-step-items__label\">{{ 'Flows.Run.Steps.Input' | transloco }}</span>\n <pre class=\"pw-step-items__json\">{{ asJson(step.input_items) }}</pre>\n <span class=\"pw-step-items__label\">{{ 'Flows.Run.Steps.Output' | transloco }}</span>\n <pre class=\"pw-step-items__json\">{{ asJson(step.output_items) }}</pre>\n </div>\n </td>\n </tr>\n }\n </ng-template>\n </p-table>\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Run.Steps.Empty' | transloco\"></pw-no-data>\n}\n}\n}\n",
|
|
807
|
+
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.pw-run-meta{display:flex;flex-direction:column;margin-bottom:16px}.pw-run-meta__label{height:18px;line-height:18px;margin-bottom:8px;font-size:11px;font-weight:600;letter-spacing:.01em;color:#5a6473}.pw-run-meta__value{line-height:18px;color:#1a1d21;overflow-wrap:anywhere}.pw-run-error{display:flex;flex-direction:column;gap:2px;background-color:#fbeae8;border:1px solid #f3d3cf;border-radius:6px;padding:10px 12px;margin-bottom:12px}.pw-run-error__label{font-size:11px;font-weight:600;letter-spacing:.01em;color:#c0392b}.pw-run-error__message{color:#1a1d21;overflow-wrap:anywhere}.pw-run-payload{margin-bottom:8px}.pw-run-payload__json{max-height:240px;overflow:auto;background-color:#f5f7fa;border:1px solid #e2e5ea;border-radius:6px;padding:8px 10px;margin:6px 0 0}.pw-step-items{display:flex;flex-direction:column;gap:2px}.pw-step-items__label{font-size:11px;font-weight:600;color:#5a6473;letter-spacing:.01em}.pw-step-items__json{max-height:320px;overflow:auto;background-color:#f5f7fa;border:1px solid #e2e5ea;border-radius:6px;padding:6px 8px;margin:0 0 6px}.pw-step-toggle{display:inline-flex;align-items:center;gap:6px;color:inherit;text-decoration:none}.pw-step-items-row td{padding-top:0}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}\n"],
|
|
808
|
+
dependencies: [
|
|
809
|
+
{
|
|
810
|
+
kind: "component",
|
|
811
|
+
type: i4$1.AppLoaderComponent,
|
|
812
|
+
selector: "pw-loader",
|
|
813
|
+
inputs: [
|
|
814
|
+
"isVisible",
|
|
815
|
+
"closeOnOutsideClick",
|
|
816
|
+
"autoCloseTimeOut"
|
|
817
|
+
]
|
|
818
|
+
},
|
|
819
|
+
{
|
|
820
|
+
kind: "component",
|
|
821
|
+
type: i5.Table,
|
|
314
822
|
selector: "p-table",
|
|
315
823
|
inputs: [
|
|
316
824
|
"frozenColumns",
|
|
@@ -423,7 +931,7 @@ var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBas
|
|
|
423
931
|
},
|
|
424
932
|
{
|
|
425
933
|
kind: "component",
|
|
426
|
-
type:
|
|
934
|
+
type: i6.NoDataComponent,
|
|
427
935
|
selector: "pw-no-data",
|
|
428
936
|
inputs: [
|
|
429
937
|
"message",
|
|
@@ -433,7 +941,7 @@ var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBas
|
|
|
433
941
|
},
|
|
434
942
|
{
|
|
435
943
|
kind: "component",
|
|
436
|
-
type:
|
|
944
|
+
type: i2$3.FaIconComponent,
|
|
437
945
|
selector: "fa-icon",
|
|
438
946
|
inputs: [
|
|
439
947
|
"icon",
|
|
@@ -470,7 +978,7 @@ var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBas
|
|
|
470
978
|
},
|
|
471
979
|
{
|
|
472
980
|
kind: "directive",
|
|
473
|
-
type:
|
|
981
|
+
type: i8.RouterLink,
|
|
474
982
|
selector: "[routerLink]",
|
|
475
983
|
inputs: [
|
|
476
984
|
"target",
|
|
@@ -487,20 +995,36 @@ var FlowsRunInspectorComponent = class FlowsRunInspectorComponent extends AppBas
|
|
|
487
995
|
"routerLink"
|
|
488
996
|
]
|
|
489
997
|
},
|
|
998
|
+
{
|
|
999
|
+
kind: "component",
|
|
1000
|
+
type: FlowsRunProgressComponent,
|
|
1001
|
+
selector: "pw-flows-run-progress",
|
|
1002
|
+
inputs: [
|
|
1003
|
+
"run",
|
|
1004
|
+
"steps",
|
|
1005
|
+
"nodeIds"
|
|
1006
|
+
]
|
|
1007
|
+
},
|
|
1008
|
+
{
|
|
1009
|
+
kind: "component",
|
|
1010
|
+
type: FlowsStepErrorComponent,
|
|
1011
|
+
selector: "pw-flows-step-error",
|
|
1012
|
+
inputs: ["error", "retrying"]
|
|
1013
|
+
},
|
|
490
1014
|
{
|
|
491
1015
|
kind: "pipe",
|
|
492
|
-
type:
|
|
1016
|
+
type: i1$2.DecimalPipe,
|
|
493
1017
|
name: "number"
|
|
494
1018
|
},
|
|
495
1019
|
{
|
|
496
1020
|
kind: "pipe",
|
|
497
|
-
type:
|
|
498
|
-
name: "
|
|
1021
|
+
type: i2$4.TranslocoPipe,
|
|
1022
|
+
name: "transloco"
|
|
499
1023
|
},
|
|
500
1024
|
{
|
|
501
1025
|
kind: "pipe",
|
|
502
|
-
type:
|
|
503
|
-
name: "
|
|
1026
|
+
type: i13.DateFormatPipe,
|
|
1027
|
+
name: "dateFormat"
|
|
504
1028
|
}
|
|
505
1029
|
]
|
|
506
1030
|
});
|
|
@@ -516,114 +1040,35 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
516
1040
|
args: [{
|
|
517
1041
|
selector: "pw-flows-run-inspector",
|
|
518
1042
|
standalone: false,
|
|
519
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex align-items-center\">\n <a href=\"javascript:void(0)\"\n class=\"previous\"\n [attr.aria-label]=\"'Flows.Run.Back' | transloco\"\n (click)=\"back()\"><fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon></a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <!-- 🔴 Id only from the resolved run: showing it from the URL confirms a foreign run exists. -->\n <span>{{\n run\n ? ('Flows.Run.Title' | transloco: { id: runId })\n : ('Flows.Run.TitleUnknown' | transloco)\n }}</span>\n </h3>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound || !run) {\n<pw-no-data [message]=\"'Flows.Run.NotFound' | transloco\"></pw-no-data>\n} @else {\n<div class=\"row mt-3\">\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Status' | transloco }}</span>\n <span class=\"pw-run-meta__value\">\n <span [class]=\"runBadgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </span>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</span>\n <a class=\"pw-run-meta__value\"\n [routerLink]=\"['../../workflows', run.flow_workflow_id, 'versions']\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Version' | transloco }}</span>\n <a class=\"pw-run-meta__value\"\n [routerLink]=\"['../../workflows', run.flow_workflow_id, 'versions']\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Started' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ run.started_at ? (run.started_at |
|
|
520
|
-
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.pw-run-meta{display:flex;flex-direction:column;margin-bottom:16px}.pw-run-meta__label{height:18px;line-height:18px;margin-bottom:8px;font-size:11px;font-weight:600;letter-spacing:.01em;color:#5a6473}.pw-run-meta__value{line-height:18px;color:#1a1d21;overflow-wrap:anywhere}.pw-run-error{display:flex;flex-direction:column;gap:2px;background-color:#fbeae8;border:1px solid #f3d3cf;border-radius:6px;padding:10px 12px;margin-bottom:12px}.pw-run-error__label{font-size:11px;font-weight:600;letter-spacing:.01em;color:#c0392b}.pw-run-error__message{color:#1a1d21;overflow-wrap:anywhere}.pw-run-payload{margin-bottom:8px}.pw-run-payload__json{max-height:240px;overflow:auto;background-color:#f5f7fa;border:1px solid #e2e5ea;border-radius:6px;padding:8px 10px;margin:6px 0 0}.pw-step-
|
|
1043
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex align-items-center\">\n <a href=\"javascript:void(0)\"\n class=\"previous\"\n [attr.aria-label]=\"'Flows.Run.Back' | transloco\"\n (click)=\"back()\"><fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon></a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <!-- 🔴 Id only from the resolved run: showing it from the URL confirms a foreign run exists. -->\n <span>{{\n run\n ? ('Flows.Run.Title' | transloco: { id: runId })\n : ('Flows.Run.TitleUnknown' | transloco)\n }}</span>\n </h3>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound || !run) {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Run.NotFound' | transloco\"></pw-no-data>\n} @else {\n<div class=\"row mt-3\">\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Status' | transloco }}</span>\n <span class=\"pw-run-meta__value\">\n <span [class]=\"runBadgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </span>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</span>\n <a class=\"pw-run-meta__value\"\n [routerLink]=\"['../../workflows', run.flow_workflow_id, 'versions']\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Version' | transloco }}</span>\n <a class=\"pw-run-meta__value\"\n [routerLink]=\"['../../workflows', run.flow_workflow_id, 'versions']\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Started' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ run.started_at ? (run.started_at | dateFormat: 'datetime') : '—' }}</span>\n </div>\n </div>\n\n @if (scheduledFor(run); as slot) {\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\"\n data-testid=\"flow-run-scheduled-for\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Run.ScheduledFor' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ slot | dateFormat: 'datetime' }}</span>\n </div>\n </div>\n }\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Finished' | transloco }}</span>\n <span class=\"pw-run-meta__value\">{{ run.finished_at ? (run.finished_at | dateFormat: 'datetime') : '—' }}</span>\n </div>\n </div>\n\n <div class=\"col-12 col-md-4\">\n <div class=\"pw-run-meta\">\n <span class=\"pw-run-meta__label\">{{ 'Flows.Runs.Column.Duration' | transloco }}</span>\n <span class=\"pw-run-meta__value\">\n @if (elapsed(run.started_at, run.finished_at) !== null) {\n {{ elapsed(run.started_at, run.finished_at) / 1000 | number: '1.0-1'\n }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n } @else {\n —\n }\n </span>\n </div>\n </div>\n\n @if (run.error) {\n <div class=\"col-12\">\n <div class=\"pw-run-error\"\n role=\"alert\">\n <span class=\"pw-run-error__label\">{{ 'Flows.Run.Meta.Error' | transloco }}</span>\n <span class=\"pw-run-error__message\">{{ run.error }}</span>\n </div>\n </div>\n }\n\n <div class=\"col-12\">\n <details class=\"pw-run-payload\">\n <summary>{{ 'Flows.Run.Meta.TriggerPayload' | transloco }}</summary>\n <pre class=\"pw-run-payload__json\">{{ asJson(run.trigger_payload) }}</pre>\n </details>\n </div>\n</div>\n\n<div class=\"row mt-4\">\n <div class=\"col-12\">\n <pw-flows-run-progress [run]=\"run\" [steps]=\"steps\" [nodeIds]=\"nodeIds\"></pw-flows-run-progress>\n <h4>{{ 'Flows.Run.Steps.Title' | transloco }}</h4>\n </div>\n</div>\n\n@if (steps.length) {\n<div class=\"primeng-datatable-container table-responsive mt-2\">\n <p-table [value]=\"steps\"\n dataKey=\"id\"\n [rowTrackBy]=\"trackByStep\">\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Run.Steps.Column.Node' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Run.Steps.Column.Attempts' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Started' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Duration' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Run.Steps.Column.Items' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-step>\n <tr>\n <td data-head=\"Node\">\n @let type = nodeTypes[step.node_id];\n @if (type) {\n @let key = labelKey(type);\n @let translated = key | transloco;\n {{ translated === key ? (definitions[type]?.label ?? type) : translated }}\n <small class=\"text-muted ms-1\">{{ step.node_id }}</small>\n } @else {\n {{ step.node_id }}\n }\n </td>\n <td data-head=\"Status\">\n <span [class]=\"stepBadgeClass(step.status)\">\n {{ (step.retry_at ? 'Flows.Status.retrying' : 'Flows.Status.' + step.status) | transloco }}\n </span>\n <pw-flows-step-error [error]=\"step.error\" [retrying]=\"!!step.retry_at\"></pw-flows-step-error>\n @if (step.retry_at) {\n <small class=\"d-block mt-1 text-muted\"\n data-testid=\"flow-step-next-try\">\n {{ 'Flows.Run.Steps.NextTry' | transloco: { time: (step.retry_at | dateFormat: 'datetime') } }}\n </small>\n }\n </td>\n <td data-head=\"Attempts\">{{ step.attempts }}</td>\n <td data-head=\"Started\">{{ step.started_at ? (step.started_at | dateFormat) : '—' }}</td>\n <td data-head=\"Duration\">\n @if (elapsed(step.started_at, step.finished_at) !== null) {\n {{ elapsed(step.started_at, step.finished_at) / 1000 | number: '1.0-1'\n }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n } @else {\n —\n }\n </td>\n <td data-head=\"Items\">\n <button type=\"button\"\n class=\"btn btn-link p-0 pw-step-toggle\"\n [attr.aria-expanded]=\"openSteps.has(step.id)\"\n [attr.aria-controls]=\"'flow-step-items-' + step.id\"\n (click)=\"toggleItems(step.id)\">\n <fa-icon [icon]=\"openSteps.has(step.id) ? icons.expanded : icons.collapsed\" aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Run.Steps.Column.Items' | transloco }}\n </button>\n </td>\n </tr>\n <!-- Its own full-width row, so opening a step never resizes the columns above. -->\n @if (openSteps.has(step.id)) {\n <tr class=\"pw-step-items-row\">\n <td colspan=\"6\"\n [id]=\"'flow-step-items-' + step.id\">\n <div class=\"pw-step-items\">\n <span class=\"pw-step-items__label\">{{ 'Flows.Run.Steps.Input' | transloco }}</span>\n <pre class=\"pw-step-items__json\">{{ asJson(step.input_items) }}</pre>\n <span class=\"pw-step-items__label\">{{ 'Flows.Run.Steps.Output' | transloco }}</span>\n <pre class=\"pw-step-items__json\">{{ asJson(step.output_items) }}</pre>\n </div>\n </td>\n </tr>\n }\n </ng-template>\n </p-table>\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Run.Steps.Empty' | transloco\"></pw-no-data>\n}\n}\n}\n",
|
|
1044
|
+
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.pw-run-meta{display:flex;flex-direction:column;margin-bottom:16px}.pw-run-meta__label{height:18px;line-height:18px;margin-bottom:8px;font-size:11px;font-weight:600;letter-spacing:.01em;color:#5a6473}.pw-run-meta__value{line-height:18px;color:#1a1d21;overflow-wrap:anywhere}.pw-run-error{display:flex;flex-direction:column;gap:2px;background-color:#fbeae8;border:1px solid #f3d3cf;border-radius:6px;padding:10px 12px;margin-bottom:12px}.pw-run-error__label{font-size:11px;font-weight:600;letter-spacing:.01em;color:#c0392b}.pw-run-error__message{color:#1a1d21;overflow-wrap:anywhere}.pw-run-payload{margin-bottom:8px}.pw-run-payload__json{max-height:240px;overflow:auto;background-color:#f5f7fa;border:1px solid #e2e5ea;border-radius:6px;padding:8px 10px;margin:6px 0 0}.pw-step-items{display:flex;flex-direction:column;gap:2px}.pw-step-items__label{font-size:11px;font-weight:600;color:#5a6473;letter-spacing:.01em}.pw-step-items__json{max-height:320px;overflow:auto;background-color:#f5f7fa;border:1px solid #e2e5ea;border-radius:6px;padding:6px 8px;margin:0 0 6px}.pw-step-toggle{display:inline-flex;align-items:center;gap:6px;color:inherit;text-decoration:none}.pw-step-items-row td{padding-top:0}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}\n"]
|
|
521
1045
|
}]
|
|
522
1046
|
}],
|
|
523
1047
|
ctorParameters: () => [
|
|
524
1048
|
{ type: i0.Injector },
|
|
525
1049
|
{ type: FlowsRunService },
|
|
1050
|
+
{ type: FlowsWorkflowService },
|
|
1051
|
+
{ type: FlowsNodeService },
|
|
526
1052
|
{ type: i0.ChangeDetectorRef }
|
|
527
1053
|
]
|
|
528
1054
|
});
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
...attrs
|
|
547
|
-
});
|
|
548
|
-
}
|
|
549
|
-
updateWorkflow(id, subscriptionId, attrs) {
|
|
550
|
-
return this.api.put(`${FLOWS_WORKFLOWS_PATH}/${id}`, {
|
|
551
|
-
subscription_id: subscriptionId,
|
|
552
|
-
...attrs
|
|
553
|
-
});
|
|
554
|
-
}
|
|
555
|
-
deleteWorkflow(id, subscriptionId) {
|
|
556
|
-
return this.api.delete(`${FLOWS_WORKFLOWS_PATH}/${id}`, { params: { subscription_id: String(subscriptionId) } });
|
|
557
|
-
}
|
|
558
|
-
getVersions(workflowId, subscriptionId, paging) {
|
|
559
|
-
return this.api.getWithParams(`${FLOWS_WORKFLOWS_PATH}/${workflowId}/versions`, {
|
|
560
|
-
subscription_id: subscriptionId,
|
|
561
|
-
...HelperService.getPagingParams(paging)
|
|
562
|
-
});
|
|
563
|
-
}
|
|
564
|
-
createVersion(workflowId, subscriptionId, graph) {
|
|
565
|
-
return this.api.post(`${FLOWS_WORKFLOWS_PATH}/${workflowId}/versions`, {
|
|
566
|
-
subscription_id: subscriptionId,
|
|
567
|
-
graph
|
|
568
|
-
});
|
|
569
|
-
}
|
|
570
|
-
updateVersion(id, subscriptionId, graph) {
|
|
571
|
-
return this.api.put(`${FLOWS_VERSIONS_PATH}/${id}`, {
|
|
572
|
-
subscription_id: subscriptionId,
|
|
573
|
-
graph
|
|
574
|
-
});
|
|
575
|
-
}
|
|
576
|
-
publishVersion(id, subscriptionId) {
|
|
577
|
-
return this.api.put(`${FLOWS_VERSIONS_PATH}/${id}/publish`, { subscription_id: subscriptionId });
|
|
578
|
-
}
|
|
579
|
-
static {
|
|
580
|
-
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
581
|
-
minVersion: "12.0.0",
|
|
582
|
-
version: "22.2.0",
|
|
583
|
-
ngImport: i0,
|
|
584
|
-
type: FlowsWorkflowService,
|
|
585
|
-
deps: [{ token: i1$1.ProductsHttpService }],
|
|
586
|
-
target: i0.ɵɵFactoryTarget.Injectable
|
|
587
|
-
});
|
|
588
|
-
}
|
|
589
|
-
static {
|
|
590
|
-
this.ɵprov = i0.ɵɵngDeclareInjectable({
|
|
591
|
-
minVersion: "12.0.0",
|
|
592
|
-
version: "22.2.0",
|
|
593
|
-
ngImport: i0,
|
|
594
|
-
type: FlowsWorkflowService,
|
|
595
|
-
providedIn: "root"
|
|
596
|
-
});
|
|
597
|
-
}
|
|
598
|
-
};
|
|
599
|
-
i0.ɵɵngDeclareClassMetadata({
|
|
600
|
-
minVersion: "12.0.0",
|
|
601
|
-
version: "22.2.0",
|
|
602
|
-
ngImport: i0,
|
|
603
|
-
type: FlowsWorkflowService,
|
|
604
|
-
decorators: [{
|
|
605
|
-
type: Injectable,
|
|
606
|
-
args: [{ providedIn: "root" }]
|
|
607
|
-
}],
|
|
608
|
-
ctorParameters: () => [{ type: i1$1.ProductsHttpService }]
|
|
609
|
-
});
|
|
610
|
-
const OPTIONS_PAGE = {
|
|
611
|
-
page: 1,
|
|
612
|
-
page_size: 200
|
|
613
|
-
};
|
|
614
|
-
var FlowsRunsFiltersComponent = class FlowsRunsFiltersComponent {
|
|
615
|
-
constructor(translation, workflowService, cdr) {
|
|
616
|
-
this.translation = translation;
|
|
617
|
-
this.workflowService = workflowService;
|
|
618
|
-
this.cdr = cdr;
|
|
619
|
-
this.queryChange = new EventEmitter();
|
|
620
|
-
this.destroy$ = new Subject();
|
|
621
|
-
this.status = null;
|
|
622
|
-
this.workflowId = null;
|
|
623
|
-
this.versionId = null;
|
|
624
|
-
this.statusOptions = [];
|
|
625
|
-
this.workflowOptions = [];
|
|
626
|
-
this.versionOptions = [];
|
|
1055
|
+
const OPTIONS_PAGE = {
|
|
1056
|
+
page: 1,
|
|
1057
|
+
page_size: 200
|
|
1058
|
+
};
|
|
1059
|
+
var FlowsRunsFiltersComponent = class FlowsRunsFiltersComponent {
|
|
1060
|
+
constructor(translation, workflowService, cdr) {
|
|
1061
|
+
this.translation = translation;
|
|
1062
|
+
this.workflowService = workflowService;
|
|
1063
|
+
this.cdr = cdr;
|
|
1064
|
+
this.queryChange = new EventEmitter();
|
|
1065
|
+
this.destroy$ = new Subject();
|
|
1066
|
+
this.status = null;
|
|
1067
|
+
this.workflowId = null;
|
|
1068
|
+
this.versionId = null;
|
|
1069
|
+
this.statusOptions = [];
|
|
1070
|
+
this.workflowOptions = [];
|
|
1071
|
+
this.versionOptions = [];
|
|
627
1072
|
}
|
|
628
1073
|
ngOnInit() {
|
|
629
1074
|
this.translation.selectTranslation("flows").pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
@@ -684,7 +1129,7 @@ var FlowsRunsFiltersComponent = class FlowsRunsFiltersComponent {
|
|
|
684
1129
|
ngImport: i0,
|
|
685
1130
|
type: FlowsRunsFiltersComponent,
|
|
686
1131
|
deps: [
|
|
687
|
-
{ token:
|
|
1132
|
+
{ token: i2$4.TranslocoService },
|
|
688
1133
|
{ token: FlowsWorkflowService },
|
|
689
1134
|
{ token: i0.ChangeDetectorRef }
|
|
690
1135
|
],
|
|
@@ -793,7 +1238,7 @@ var FlowsRunsFiltersComponent = class FlowsRunsFiltersComponent {
|
|
|
793
1238
|
},
|
|
794
1239
|
{
|
|
795
1240
|
kind: "pipe",
|
|
796
|
-
type:
|
|
1241
|
+
type: i2$4.TranslocoPipe,
|
|
797
1242
|
name: "transloco"
|
|
798
1243
|
}
|
|
799
1244
|
]
|
|
@@ -814,7 +1259,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
814
1259
|
}]
|
|
815
1260
|
}],
|
|
816
1261
|
ctorParameters: () => [
|
|
817
|
-
{ type:
|
|
1262
|
+
{ type: i2$4.TranslocoService },
|
|
818
1263
|
{ type: FlowsWorkflowService },
|
|
819
1264
|
{ type: i0.ChangeDetectorRef }
|
|
820
1265
|
],
|
|
@@ -932,12 +1377,12 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
932
1377
|
selector: "pw-flows-runs",
|
|
933
1378
|
usesInheritance: true,
|
|
934
1379
|
ngImport: i0,
|
|
935
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Runs.Title' | transloco }}</h2>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"7\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"runs\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template #caption>\n <pw-flows-runs-filters [subscriptionId]=\"subscriptionId\"\n (queryChange)=\"onQuery($event)\" />\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Run' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Version' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Started' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Duration' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-two\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-run>\n <tr>\n <td data-head=\"Run\">#{{ run.id }}</td>\n <td data-head=\"Workflow\">\n <a [routerLink]=\"versionsLink(run)\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </td>\n <td data-head=\"Version\">\n <a [routerLink]=\"versionsLink(run)\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </td>\n <td data-head=\"Started\">{{ run.started_at ? (run.started_at |
|
|
1380
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Runs.Title' | transloco }}</h2>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"7\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"runs\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template #caption>\n <pw-flows-runs-filters [subscriptionId]=\"subscriptionId\"\n (queryChange)=\"onQuery($event)\" />\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Run' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Version' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Started' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Duration' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-two\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-run>\n <tr>\n <td data-head=\"Run\">#{{ run.id }}</td>\n <td data-head=\"Workflow\">\n <a [routerLink]=\"versionsLink(run)\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </td>\n <td data-head=\"Version\">\n <a [routerLink]=\"versionsLink(run)\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </td>\n <td data-head=\"Started\">{{ run.started_at ? (run.started_at | dateFormat) : '—' }}</td>\n <td data-head=\"Duration\">\n @if (duration(run) !== null) {\n {{ duration(run) / 1000 | number: '1.0-1' }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n } @else {\n —\n }\n </td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li [pTooltip]=\"'Flows.Runs.Inspect' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.inspect\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Runs.Inspect' | transloco\"\n (click)=\"inspect(run)\"\n (keydown.enter)=\"inspect(run)\"></fa-icon>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n\n <pw-records-summary [showing]=\"runs.length\"\n [total]=\"totalRecords\" />\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Runs.Empty' | transloco\" [description]=\"'Flows.Runs.EmptyDescription' | transloco\"></pw-no-data>\n}\n}\n",
|
|
936
1381
|
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}\n"],
|
|
937
1382
|
dependencies: [
|
|
938
1383
|
{
|
|
939
1384
|
kind: "component",
|
|
940
|
-
type:
|
|
1385
|
+
type: i4$1.SkeletonTableComponent,
|
|
941
1386
|
selector: "pw-skeleton-table",
|
|
942
1387
|
inputs: [
|
|
943
1388
|
"rows",
|
|
@@ -950,7 +1395,7 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
950
1395
|
},
|
|
951
1396
|
{
|
|
952
1397
|
kind: "directive",
|
|
953
|
-
type:
|
|
1398
|
+
type: i1$1.Tooltip,
|
|
954
1399
|
selector: "[pTooltip]",
|
|
955
1400
|
inputs: [
|
|
956
1401
|
"tooltipPosition",
|
|
@@ -978,7 +1423,7 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
978
1423
|
},
|
|
979
1424
|
{
|
|
980
1425
|
kind: "component",
|
|
981
|
-
type:
|
|
1426
|
+
type: i5.Table,
|
|
982
1427
|
selector: "p-table",
|
|
983
1428
|
inputs: [
|
|
984
1429
|
"frozenColumns",
|
|
@@ -1091,7 +1536,7 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
1091
1536
|
},
|
|
1092
1537
|
{
|
|
1093
1538
|
kind: "component",
|
|
1094
|
-
type:
|
|
1539
|
+
type: i6.NoDataComponent,
|
|
1095
1540
|
selector: "pw-no-data",
|
|
1096
1541
|
inputs: [
|
|
1097
1542
|
"message",
|
|
@@ -1101,13 +1546,13 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
1101
1546
|
},
|
|
1102
1547
|
{
|
|
1103
1548
|
kind: "component",
|
|
1104
|
-
type:
|
|
1549
|
+
type: i6.RecordsSummaryComponent,
|
|
1105
1550
|
selector: "pw-records-summary",
|
|
1106
1551
|
inputs: ["showing", "total"]
|
|
1107
1552
|
},
|
|
1108
1553
|
{
|
|
1109
1554
|
kind: "component",
|
|
1110
|
-
type:
|
|
1555
|
+
type: i2$3.FaIconComponent,
|
|
1111
1556
|
selector: "fa-icon",
|
|
1112
1557
|
inputs: [
|
|
1113
1558
|
"icon",
|
|
@@ -1144,7 +1589,7 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
1144
1589
|
},
|
|
1145
1590
|
{
|
|
1146
1591
|
kind: "directive",
|
|
1147
|
-
type:
|
|
1592
|
+
type: i8.RouterLink,
|
|
1148
1593
|
selector: "[routerLink]",
|
|
1149
1594
|
inputs: [
|
|
1150
1595
|
"target",
|
|
@@ -1170,18 +1615,18 @@ var FlowsRunsComponent = class FlowsRunsComponent extends AppBaseComponent {
|
|
|
1170
1615
|
},
|
|
1171
1616
|
{
|
|
1172
1617
|
kind: "pipe",
|
|
1173
|
-
type:
|
|
1618
|
+
type: i1$2.DecimalPipe,
|
|
1174
1619
|
name: "number"
|
|
1175
1620
|
},
|
|
1176
1621
|
{
|
|
1177
1622
|
kind: "pipe",
|
|
1178
|
-
type:
|
|
1179
|
-
name: "
|
|
1623
|
+
type: i2$4.TranslocoPipe,
|
|
1624
|
+
name: "transloco"
|
|
1180
1625
|
},
|
|
1181
1626
|
{
|
|
1182
1627
|
kind: "pipe",
|
|
1183
|
-
type:
|
|
1184
|
-
name: "
|
|
1628
|
+
type: i13.DateFormatPipe,
|
|
1629
|
+
name: "dateFormat"
|
|
1185
1630
|
}
|
|
1186
1631
|
]
|
|
1187
1632
|
});
|
|
@@ -1197,7 +1642,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
1197
1642
|
args: [{
|
|
1198
1643
|
selector: "pw-flows-runs",
|
|
1199
1644
|
standalone: false,
|
|
1200
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Runs.Title' | transloco }}</h2>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"7\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"runs\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template #caption>\n <pw-flows-runs-filters [subscriptionId]=\"subscriptionId\"\n (queryChange)=\"onQuery($event)\" />\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Run' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Version' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Started' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Duration' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-two\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-run>\n <tr>\n <td data-head=\"Run\">#{{ run.id }}</td>\n <td data-head=\"Workflow\">\n <a [routerLink]=\"versionsLink(run)\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </td>\n <td data-head=\"Version\">\n <a [routerLink]=\"versionsLink(run)\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </td>\n <td data-head=\"Started\">{{ run.started_at ? (run.started_at |
|
|
1645
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Runs.Title' | transloco }}</h2>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"7\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"runs\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template #caption>\n <pw-flows-runs-filters [subscriptionId]=\"subscriptionId\"\n (queryChange)=\"onQuery($event)\" />\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Run' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Workflow' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Version' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Started' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Runs.Column.Duration' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-two\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-run>\n <tr>\n <td data-head=\"Run\">#{{ run.id }}</td>\n <td data-head=\"Workflow\">\n <a [routerLink]=\"versionsLink(run)\">{{ run.flow_workflow_name || '#' + run.flow_workflow_id }}</a>\n </td>\n <td data-head=\"Version\">\n <a [routerLink]=\"versionsLink(run)\"\n [queryParams]=\"{ version: run.flow_version_id }\">{{ 'Flows.Runs.VersionLabel' | transloco: { number: run.flow_version_number } }}</a>\n </td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(run.status)\">\n {{ 'Flows.Status.' + run.status | transloco }}\n </span>\n </td>\n <td data-head=\"Started\">{{ run.started_at ? (run.started_at | dateFormat) : '—' }}</td>\n <td data-head=\"Duration\">\n @if (duration(run) !== null) {\n {{ duration(run) / 1000 | number: '1.0-1' }}{{ 'Flows.Runs.SecondsSuffix' | transloco }}\n } @else {\n —\n }\n </td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li [pTooltip]=\"'Flows.Runs.Inspect' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.inspect\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Runs.Inspect' | transloco\"\n (click)=\"inspect(run)\"\n (keydown.enter)=\"inspect(run)\"></fa-icon>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n\n <pw-records-summary [showing]=\"runs.length\"\n [total]=\"totalRecords\" />\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Runs.Empty' | transloco\" [description]=\"'Flows.Runs.EmptyDescription' | transloco\"></pw-no-data>\n}\n}\n",
|
|
1201
1646
|
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}\n"]
|
|
1202
1647
|
}]
|
|
1203
1648
|
}],
|
|
@@ -1243,7 +1688,7 @@ var FlowsTabsComponent = class FlowsTabsComponent {
|
|
|
1243
1688
|
isInline: true,
|
|
1244
1689
|
dependencies: [{
|
|
1245
1690
|
kind: "component",
|
|
1246
|
-
type:
|
|
1691
|
+
type: i6.PwTabsComponent,
|
|
1247
1692
|
selector: "pw-tabs",
|
|
1248
1693
|
inputs: ["items", "withSubscription"]
|
|
1249
1694
|
}]
|
|
@@ -1412,8 +1857,8 @@ var FlowsWorkflowFormComponent = class FlowsWorkflowFormComponent extends AppBas
|
|
|
1412
1857
|
selector: "pw-flows-workflow-form",
|
|
1413
1858
|
usesInheritance: true,
|
|
1414
1859
|
ngImport: i0,
|
|
1415
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ (isEdit ? 'Flows.WorkflowForm.EditTitle' : 'Flows.WorkflowForm.CreateTitle') | transloco }}\n </h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-secondary\"\n (click)=\"back()\">\n <fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Back' | transloco }}\n </button>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound) {\n<pw-no-data [message]=\"'Flows.WorkflowForm.NotFound' | transloco\"></pw-no-data>\n} @else {\n<form [formGroup]=\"form\"\n (ngSubmit)=\"save()\"\n class=\"mt-3\">\n <h3>{{ 'Flows.WorkflowForm.Section.Details' | transloco }}</h3>\n <div class=\"row\">\n <!-- md-8/md-4 rather than the pattern default so the row fills the page. -->\n <pw-input-container class=\"col-12 col-md-8\"\n [label]=\"'Flows.WorkflowForm.Name' | transloco\"\n name=\"name\"\n controlId=\"flows-workflow-name\"\n [required]=\"true\"\n errorMsg=\"Flows.WorkflowForm.NameError\">\n <input type=\"text\"\n id=\"flows-workflow-name\"\n class=\"form-control\"\n maxlength=\"255\"\n [placeholder]=\"'Flows.WorkflowForm.NamePlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Name' | transloco\"\n formControlName=\"name\" />\n </pw-input-container>\n\n <pw-input-container class=\"col-12 col-md-4\"\n [label]=\"'Flows.WorkflowForm.Status' | transloco\"\n name=\"status\"\n controlId=\"flows-workflow-status\"\n [required]=\"true\"\n [useAriaLabelledbyOnly]=\"true\"\n errorMsg=\"Flows.WorkflowForm.StatusError\">\n <!-- No [showClear]: Grape restricts status to STATUSES, so a blank 400s. -->\n <p-select inputId=\"flows-workflow-status\"\n styleClass=\"w-100\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n formControlName=\"status\"\n [attr.aria-labelledby]=\"'flows-workflow-status-label'\"\n appendTo=\"body\">\n </p-select>\n </pw-input-container>\n\n <pw-input-container class=\"col-12\"\n [label]=\"'Flows.WorkflowForm.Description' | transloco\"\n name=\"description\"\n controlId=\"flows-workflow-description\">\n <textarea id=\"flows-workflow-description\"\n class=\"form-control\"\n rows=\"3\"\n [placeholder]=\"'Flows.WorkflowForm.DescriptionPlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Description' | transloco\"\n formControlName=\"description\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button name=\"submit\"\n type=\"submit\"\n class=\"btn btn-primary\"\n [disabled]=\"saving\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n</form>\n}\n}\n",
|
|
1416
|
-
styles: [":host form>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}:host form>h3:first-child{border-top:0;margin-top:.5rem;padding-top:0}\n"],
|
|
1860
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ (isEdit ? 'Flows.WorkflowForm.EditTitle' : 'Flows.WorkflowForm.CreateTitle') | transloco }}\n </h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-secondary\"\n (click)=\"back()\">\n <fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Back' | transloco }}\n </button>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound) {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.WorkflowForm.NotFound' | transloco\"></pw-no-data>\n} @else {\n<form [formGroup]=\"form\"\n (ngSubmit)=\"save()\"\n class=\"mt-3\">\n <h3>{{ 'Flows.WorkflowForm.Section.Details' | transloco }}</h3>\n <div class=\"row\">\n <!-- md-8/md-4 rather than the pattern default so the row fills the page. -->\n <pw-input-container class=\"col-12 col-md-8\"\n [label]=\"'Flows.WorkflowForm.Name' | transloco\"\n name=\"name\"\n controlId=\"flows-workflow-name\"\n [required]=\"true\"\n errorMsg=\"Flows.WorkflowForm.NameError\">\n <input type=\"text\"\n id=\"flows-workflow-name\"\n class=\"form-control\"\n maxlength=\"255\"\n [placeholder]=\"'Flows.WorkflowForm.NamePlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Name' | transloco\"\n formControlName=\"name\" />\n </pw-input-container>\n\n <pw-input-container class=\"col-12 col-md-4\"\n [label]=\"'Flows.WorkflowForm.Status' | transloco\"\n name=\"status\"\n controlId=\"flows-workflow-status\"\n [required]=\"true\"\n [useAriaLabelledbyOnly]=\"true\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.WorkflowForm.StatusHint' | transloco\"\n errorMsg=\"Flows.WorkflowForm.StatusError\">\n <!-- No [showClear]: Grape restricts status to STATUSES, so a blank 400s. -->\n <p-select inputId=\"flows-workflow-status\"\n styleClass=\"w-100\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n formControlName=\"status\"\n [attr.aria-labelledby]=\"'flows-workflow-status-label'\"\n appendTo=\"body\">\n </p-select>\n </pw-input-container>\n\n <pw-input-container class=\"col-12\"\n [label]=\"'Flows.WorkflowForm.Description' | transloco\"\n name=\"description\"\n controlId=\"flows-workflow-description\">\n <textarea id=\"flows-workflow-description\"\n class=\"form-control\"\n rows=\"3\"\n [placeholder]=\"'Flows.WorkflowForm.DescriptionPlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Description' | transloco\"\n formControlName=\"description\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button name=\"submit\"\n type=\"submit\"\n class=\"btn btn-primary\"\n [disabled]=\"saving\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n</form>\n}\n}\n",
|
|
1861
|
+
styles: [":host ::ng-deep .info-circle{display:inline-block;margin-left:.35em;vertical-align:baseline}:host ::ng-deep .info-circle:after{position:static;font-size:inherit;line-height:inherit}:host form>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}:host form>h3:first-child{border-top:0;margin-top:.5rem;padding-top:0}\n"],
|
|
1417
1862
|
dependencies: [
|
|
1418
1863
|
{
|
|
1419
1864
|
kind: "directive",
|
|
@@ -1467,7 +1912,7 @@ var FlowsWorkflowFormComponent = class FlowsWorkflowFormComponent extends AppBas
|
|
|
1467
1912
|
},
|
|
1468
1913
|
{
|
|
1469
1914
|
kind: "component",
|
|
1470
|
-
type:
|
|
1915
|
+
type: i4$1.AppLoaderComponent,
|
|
1471
1916
|
selector: "pw-loader",
|
|
1472
1917
|
inputs: [
|
|
1473
1918
|
"isVisible",
|
|
@@ -1547,7 +1992,7 @@ var FlowsWorkflowFormComponent = class FlowsWorkflowFormComponent extends AppBas
|
|
|
1547
1992
|
},
|
|
1548
1993
|
{
|
|
1549
1994
|
kind: "component",
|
|
1550
|
-
type:
|
|
1995
|
+
type: i6.InputContainerComponent,
|
|
1551
1996
|
selector: "pw-input-container",
|
|
1552
1997
|
inputs: [
|
|
1553
1998
|
"name",
|
|
@@ -1570,7 +2015,7 @@ var FlowsWorkflowFormComponent = class FlowsWorkflowFormComponent extends AppBas
|
|
|
1570
2015
|
},
|
|
1571
2016
|
{
|
|
1572
2017
|
kind: "component",
|
|
1573
|
-
type:
|
|
2018
|
+
type: i6.NoDataComponent,
|
|
1574
2019
|
selector: "pw-no-data",
|
|
1575
2020
|
inputs: [
|
|
1576
2021
|
"message",
|
|
@@ -1580,7 +2025,7 @@ var FlowsWorkflowFormComponent = class FlowsWorkflowFormComponent extends AppBas
|
|
|
1580
2025
|
},
|
|
1581
2026
|
{
|
|
1582
2027
|
kind: "component",
|
|
1583
|
-
type:
|
|
2028
|
+
type: i2$3.FaIconComponent,
|
|
1584
2029
|
selector: "fa-icon",
|
|
1585
2030
|
inputs: [
|
|
1586
2031
|
"icon",
|
|
@@ -1617,7 +2062,7 @@ var FlowsWorkflowFormComponent = class FlowsWorkflowFormComponent extends AppBas
|
|
|
1617
2062
|
},
|
|
1618
2063
|
{
|
|
1619
2064
|
kind: "pipe",
|
|
1620
|
-
type:
|
|
2065
|
+
type: i2$4.TranslocoPipe,
|
|
1621
2066
|
name: "transloco"
|
|
1622
2067
|
}
|
|
1623
2068
|
]
|
|
@@ -1634,8 +2079,8 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
1634
2079
|
args: [{
|
|
1635
2080
|
selector: "pw-flows-workflow-form",
|
|
1636
2081
|
standalone: false,
|
|
1637
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ (isEdit ? 'Flows.WorkflowForm.EditTitle' : 'Flows.WorkflowForm.CreateTitle') | transloco }}\n </h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-secondary\"\n (click)=\"back()\">\n <fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Back' | transloco }}\n </button>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound) {\n<pw-no-data [message]=\"'Flows.WorkflowForm.NotFound' | transloco\"></pw-no-data>\n} @else {\n<form [formGroup]=\"form\"\n (ngSubmit)=\"save()\"\n class=\"mt-3\">\n <h3>{{ 'Flows.WorkflowForm.Section.Details' | transloco }}</h3>\n <div class=\"row\">\n <!-- md-8/md-4 rather than the pattern default so the row fills the page. -->\n <pw-input-container class=\"col-12 col-md-8\"\n [label]=\"'Flows.WorkflowForm.Name' | transloco\"\n name=\"name\"\n controlId=\"flows-workflow-name\"\n [required]=\"true\"\n errorMsg=\"Flows.WorkflowForm.NameError\">\n <input type=\"text\"\n id=\"flows-workflow-name\"\n class=\"form-control\"\n maxlength=\"255\"\n [placeholder]=\"'Flows.WorkflowForm.NamePlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Name' | transloco\"\n formControlName=\"name\" />\n </pw-input-container>\n\n <pw-input-container class=\"col-12 col-md-4\"\n [label]=\"'Flows.WorkflowForm.Status' | transloco\"\n name=\"status\"\n controlId=\"flows-workflow-status\"\n [required]=\"true\"\n [useAriaLabelledbyOnly]=\"true\"\n errorMsg=\"Flows.WorkflowForm.StatusError\">\n <!-- No [showClear]: Grape restricts status to STATUSES, so a blank 400s. -->\n <p-select inputId=\"flows-workflow-status\"\n styleClass=\"w-100\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n formControlName=\"status\"\n [attr.aria-labelledby]=\"'flows-workflow-status-label'\"\n appendTo=\"body\">\n </p-select>\n </pw-input-container>\n\n <pw-input-container class=\"col-12\"\n [label]=\"'Flows.WorkflowForm.Description' | transloco\"\n name=\"description\"\n controlId=\"flows-workflow-description\">\n <textarea id=\"flows-workflow-description\"\n class=\"form-control\"\n rows=\"3\"\n [placeholder]=\"'Flows.WorkflowForm.DescriptionPlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Description' | transloco\"\n formControlName=\"description\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button name=\"submit\"\n type=\"submit\"\n class=\"btn btn-primary\"\n [disabled]=\"saving\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n</form>\n}\n}\n",
|
|
1638
|
-
styles: [":host form>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}:host form>h3:first-child{border-top:0;margin-top:.5rem;padding-top:0}\n"]
|
|
2082
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ (isEdit ? 'Flows.WorkflowForm.EditTitle' : 'Flows.WorkflowForm.CreateTitle') | transloco }}\n </h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-secondary\"\n (click)=\"back()\">\n <fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Back' | transloco }}\n </button>\n </div>\n</div>\n\n<pw-loader [isVisible]=\"loading\"></pw-loader>\n\n@if (!loading) {\n@if (notFound) {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.WorkflowForm.NotFound' | transloco\"></pw-no-data>\n} @else {\n<form [formGroup]=\"form\"\n (ngSubmit)=\"save()\"\n class=\"mt-3\">\n <h3>{{ 'Flows.WorkflowForm.Section.Details' | transloco }}</h3>\n <div class=\"row\">\n <!-- md-8/md-4 rather than the pattern default so the row fills the page. -->\n <pw-input-container class=\"col-12 col-md-8\"\n [label]=\"'Flows.WorkflowForm.Name' | transloco\"\n name=\"name\"\n controlId=\"flows-workflow-name\"\n [required]=\"true\"\n errorMsg=\"Flows.WorkflowForm.NameError\">\n <input type=\"text\"\n id=\"flows-workflow-name\"\n class=\"form-control\"\n maxlength=\"255\"\n [placeholder]=\"'Flows.WorkflowForm.NamePlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Name' | transloco\"\n formControlName=\"name\" />\n </pw-input-container>\n\n <pw-input-container class=\"col-12 col-md-4\"\n [label]=\"'Flows.WorkflowForm.Status' | transloco\"\n name=\"status\"\n controlId=\"flows-workflow-status\"\n [required]=\"true\"\n [useAriaLabelledbyOnly]=\"true\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.WorkflowForm.StatusHint' | transloco\"\n errorMsg=\"Flows.WorkflowForm.StatusError\">\n <!-- No [showClear]: Grape restricts status to STATUSES, so a blank 400s. -->\n <p-select inputId=\"flows-workflow-status\"\n styleClass=\"w-100\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n formControlName=\"status\"\n [attr.aria-labelledby]=\"'flows-workflow-status-label'\"\n appendTo=\"body\">\n </p-select>\n </pw-input-container>\n\n <pw-input-container class=\"col-12\"\n [label]=\"'Flows.WorkflowForm.Description' | transloco\"\n name=\"description\"\n controlId=\"flows-workflow-description\">\n <textarea id=\"flows-workflow-description\"\n class=\"form-control\"\n rows=\"3\"\n [placeholder]=\"'Flows.WorkflowForm.DescriptionPlaceholder' | transloco\"\n [attr.aria-label]=\"'Flows.WorkflowForm.Description' | transloco\"\n formControlName=\"description\"></textarea>\n </pw-input-container>\n </div>\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button name=\"submit\"\n type=\"submit\"\n class=\"btn btn-primary\"\n [disabled]=\"saving\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n</form>\n}\n}\n",
|
|
2083
|
+
styles: [":host ::ng-deep .info-circle{display:inline-block;margin-left:.35em;vertical-align:baseline}:host ::ng-deep .info-circle:after{position:static;font-size:inherit;line-height:inherit}:host form>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}:host form>h3:first-child{border-top:0;margin-top:.5rem;padding-top:0}\n"]
|
|
1639
2084
|
}]
|
|
1640
2085
|
}],
|
|
1641
2086
|
ctorParameters: () => [
|
|
@@ -1644,102 +2089,30 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
1644
2089
|
{ type: i0.ChangeDetectorRef }
|
|
1645
2090
|
]
|
|
1646
2091
|
});
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
}
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
nodes: nodes.filter((node) => isRecord(node) && typeof node["id"] === "string" && typeof node["type"] === "string"),
|
|
1669
|
-
edges: edges.filter((edge) => isRecord(edge) && typeof edge["from"] === "string" && typeof edge["to"] === "string")
|
|
1670
|
-
};
|
|
1671
|
-
}
|
|
1672
|
-
function nextId(prefix, taken) {
|
|
1673
|
-
const pattern = new RegExp(String.raw`^${prefix}(\d+)$`);
|
|
1674
|
-
return `${prefix}${taken.reduce((max, id) => {
|
|
1675
|
-
const match = pattern.exec(id);
|
|
1676
|
-
return match ? Math.max(max, Number(match[1])) : max;
|
|
1677
|
-
}, 0) + 1}`;
|
|
1678
|
-
}
|
|
1679
|
-
function nextFlowNodeId(nodes) {
|
|
1680
|
-
return nextId("n", nodes.map((node) => node.id));
|
|
1681
|
-
}
|
|
1682
|
-
function nextFlowEdgeId(edges) {
|
|
1683
|
-
return nextId("e", edges.map((edge) => edge.id ?? ""));
|
|
1684
|
-
}
|
|
1685
|
-
function flowNodeLabelKey(type) {
|
|
1686
|
-
return `Flows.Nodes.${type}`;
|
|
1687
|
-
}
|
|
1688
|
-
var FlowsNodeService = class FlowsNodeService {
|
|
1689
|
-
constructor(api) {
|
|
1690
|
-
this.api = api;
|
|
1691
|
-
this.cache = /* @__PURE__ */ new Map();
|
|
1692
|
-
}
|
|
1693
|
-
getNodes(subscriptionId) {
|
|
1694
|
-
let nodes = this.cache.get(subscriptionId);
|
|
1695
|
-
if (!nodes) {
|
|
1696
|
-
nodes = this.api.getWithParams(FLOWS_NODES_PATH, { subscription_id: subscriptionId }).pipe(map((response) => response.flow_nodes), catchError((error) => {
|
|
1697
|
-
this.cache.delete(subscriptionId);
|
|
1698
|
-
return throwError(() => error);
|
|
1699
|
-
}), shareReplay({
|
|
1700
|
-
bufferSize: 1,
|
|
1701
|
-
refCount: false
|
|
1702
|
-
}));
|
|
1703
|
-
this.cache.set(subscriptionId, nodes);
|
|
2092
|
+
var FlowVersionEditorState = class {
|
|
2093
|
+
constructor() {
|
|
2094
|
+
this.open = false;
|
|
2095
|
+
this.version = null;
|
|
2096
|
+
this.duplicateOf = null;
|
|
2097
|
+
this.check = null;
|
|
2098
|
+
}
|
|
2099
|
+
show(version, duplicateOf = null, check = null) {
|
|
2100
|
+
this.open = true;
|
|
2101
|
+
this.version = version;
|
|
2102
|
+
this.duplicateOf = duplicateOf;
|
|
2103
|
+
this.check = check;
|
|
2104
|
+
}
|
|
2105
|
+
close() {
|
|
2106
|
+
this.show(null);
|
|
2107
|
+
this.open = false;
|
|
2108
|
+
}
|
|
2109
|
+
published(version) {
|
|
2110
|
+
if (this.open && this.version?.id === version.id) {
|
|
2111
|
+
this.version = version;
|
|
2112
|
+
this.check = null;
|
|
1704
2113
|
}
|
|
1705
|
-
return nodes;
|
|
1706
|
-
}
|
|
1707
|
-
static {
|
|
1708
|
-
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
1709
|
-
minVersion: "12.0.0",
|
|
1710
|
-
version: "22.2.0",
|
|
1711
|
-
ngImport: i0,
|
|
1712
|
-
type: FlowsNodeService,
|
|
1713
|
-
deps: [{ token: i1$1.ProductsHttpService }],
|
|
1714
|
-
target: i0.ɵɵFactoryTarget.Injectable
|
|
1715
|
-
});
|
|
1716
|
-
}
|
|
1717
|
-
static {
|
|
1718
|
-
this.ɵprov = i0.ɵɵngDeclareInjectable({
|
|
1719
|
-
minVersion: "12.0.0",
|
|
1720
|
-
version: "22.2.0",
|
|
1721
|
-
ngImport: i0,
|
|
1722
|
-
type: FlowsNodeService,
|
|
1723
|
-
providedIn: "root"
|
|
1724
|
-
});
|
|
1725
2114
|
}
|
|
1726
2115
|
};
|
|
1727
|
-
i0.ɵɵngDeclareClassMetadata({
|
|
1728
|
-
minVersion: "12.0.0",
|
|
1729
|
-
version: "22.2.0",
|
|
1730
|
-
ngImport: i0,
|
|
1731
|
-
type: FlowsNodeService,
|
|
1732
|
-
decorators: [{
|
|
1733
|
-
type: Injectable,
|
|
1734
|
-
args: [{ providedIn: "root" }]
|
|
1735
|
-
}],
|
|
1736
|
-
ctorParameters: () => [{ type: i1$1.ProductsHttpService }]
|
|
1737
|
-
});
|
|
1738
|
-
const FLOW_SCHEDULE_PAYLOAD_FIELDS = [
|
|
1739
|
-
"trigger_id",
|
|
1740
|
-
"trigger_type",
|
|
1741
|
-
"scheduled_for"
|
|
1742
|
-
];
|
|
1743
2116
|
function upstreamOf(graph, nodeId) {
|
|
1744
2117
|
const seen = /* @__PURE__ */ new Set();
|
|
1745
2118
|
const queue = [nodeId];
|
|
@@ -1758,21 +2131,28 @@ function conditionFieldSuggestions(graph, nodeId) {
|
|
|
1758
2131
|
const fields = node.params?.["fields"];
|
|
1759
2132
|
return fields && typeof fields === "object" && !Array.isArray(fields) ? Object.keys(fields) : [];
|
|
1760
2133
|
});
|
|
1761
|
-
return [
|
|
2134
|
+
return [...new Set(setKeys)];
|
|
2135
|
+
}
|
|
2136
|
+
function flowIncoming(graph, walk) {
|
|
2137
|
+
const entering = /* @__PURE__ */ new Set();
|
|
2138
|
+
const into = (id) => {
|
|
2139
|
+
if (entering.has(id)) return walk.none();
|
|
2140
|
+
entering.add(id);
|
|
2141
|
+
const found = walk.combine(graph.edges.filter((edge) => edge.to === id).map((edge) => edge.branch === "error" ? walk.failed(edge.from, into(edge.from)) : walk.outOf(edge.from)));
|
|
2142
|
+
entering.delete(id);
|
|
2143
|
+
return found;
|
|
2144
|
+
};
|
|
2145
|
+
return into;
|
|
1762
2146
|
}
|
|
1763
2147
|
const NONE = {
|
|
1764
2148
|
names: [],
|
|
1765
2149
|
lists: {}
|
|
1766
2150
|
};
|
|
1767
|
-
const
|
|
1768
|
-
"
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
"action.in_app_note",
|
|
1773
|
-
"action.push_notification",
|
|
1774
|
-
"action.websocket"
|
|
1775
|
-
];
|
|
2151
|
+
const FLOW_ERROR_FIELDS = {
|
|
2152
|
+
names: ["error"],
|
|
2153
|
+
lists: {}
|
|
2154
|
+
};
|
|
2155
|
+
const NO_FIELDS = ["trigger.schedule", "trigger.manual"];
|
|
1776
2156
|
function unique(names) {
|
|
1777
2157
|
return [...new Set(names)];
|
|
1778
2158
|
}
|
|
@@ -1795,12 +2175,7 @@ function setKeys(node) {
|
|
|
1795
2175
|
return fields && typeof fields === "object" && !Array.isArray(fields) ? Object.keys(fields) : [];
|
|
1796
2176
|
}
|
|
1797
2177
|
function leaving(node, incoming, definition) {
|
|
1798
|
-
if (definition?.item_fields) return definition.item_fields;
|
|
1799
2178
|
switch (node.type) {
|
|
1800
|
-
case "trigger.schedule": return {
|
|
1801
|
-
names: [...FLOW_SCHEDULE_PAYLOAD_FIELDS],
|
|
1802
|
-
lists: {}
|
|
1803
|
-
};
|
|
1804
2179
|
case "data.split_out": return {
|
|
1805
2180
|
names: incoming.lists[text(node, "field")] ?? [],
|
|
1806
2181
|
lists: {}
|
|
@@ -1813,26 +2188,126 @@ function leaving(node, incoming, definition) {
|
|
|
1813
2188
|
names: unique([...incoming.names, ...setKeys(node)]),
|
|
1814
2189
|
lists: incoming.lists
|
|
1815
2190
|
};
|
|
1816
|
-
default:
|
|
2191
|
+
default: {
|
|
2192
|
+
const own = definition?.item_fields ?? NONE;
|
|
2193
|
+
return definition?.passes_items ? union([incoming, own]) : own;
|
|
2194
|
+
}
|
|
1817
2195
|
}
|
|
1818
2196
|
}
|
|
1819
|
-
function
|
|
2197
|
+
function flowFieldWalk(graph, definitions, learned = {}) {
|
|
1820
2198
|
const byType = new Map(definitions.map((definition) => [definition.type, definition]));
|
|
1821
2199
|
const nodes = new Map(graph.nodes.map((node) => [node.id, node]));
|
|
1822
2200
|
const known = /* @__PURE__ */ new Map();
|
|
1823
|
-
const walking = /* @__PURE__ */ new Set(
|
|
1824
|
-
const into = (
|
|
2201
|
+
const walking = /* @__PURE__ */ new Set();
|
|
2202
|
+
const into = flowIncoming(graph, {
|
|
2203
|
+
outOf: (id) => outOf(id),
|
|
2204
|
+
failed: (_, reached) => union([reached, FLOW_ERROR_FIELDS]),
|
|
2205
|
+
combine: union,
|
|
2206
|
+
none: () => NONE
|
|
2207
|
+
});
|
|
1825
2208
|
const outOf = (id) => {
|
|
1826
2209
|
const node = nodes.get(id);
|
|
1827
|
-
if (!node || walking.has(id)) return NONE;
|
|
2210
|
+
if (!node || walking.has(id) || NO_FIELDS.includes(node.type)) return NONE;
|
|
1828
2211
|
if (!known.has(id)) {
|
|
1829
2212
|
walking.add(id);
|
|
1830
|
-
|
|
2213
|
+
const expected = leaving(node, into(id), byType.get(node.type));
|
|
2214
|
+
const seen = learned[flowNodeFieldsKey(id, node.type)];
|
|
2215
|
+
known.set(id, seen ? union([expected, seen]) : expected);
|
|
1831
2216
|
walking.delete(id);
|
|
1832
2217
|
}
|
|
1833
2218
|
return known.get(id);
|
|
1834
2219
|
};
|
|
1835
|
-
return
|
|
2220
|
+
return {
|
|
2221
|
+
into,
|
|
2222
|
+
outOf
|
|
2223
|
+
};
|
|
2224
|
+
}
|
|
2225
|
+
function flowFieldsInto(graph, nodeId, definitions, learned = {}) {
|
|
2226
|
+
return flowFieldWalk(graph, definitions, learned).into(nodeId);
|
|
2227
|
+
}
|
|
2228
|
+
function flowFieldsPossible(graph, nodeId) {
|
|
2229
|
+
const types = new Map(graph.nodes.map((node) => [node.id, node.type]));
|
|
2230
|
+
const before = (id) => graph.edges.filter((e) => e.to === id).map((e) => e.from);
|
|
2231
|
+
const seen = /* @__PURE__ */ new Set();
|
|
2232
|
+
const queue = before(nodeId);
|
|
2233
|
+
while (queue.length) {
|
|
2234
|
+
const id = queue.pop();
|
|
2235
|
+
if (!seen.has(id)) {
|
|
2236
|
+
seen.add(id);
|
|
2237
|
+
if (!NO_FIELDS.includes(types.get(id) ?? "")) return true;
|
|
2238
|
+
queue.push(...before(id));
|
|
2239
|
+
}
|
|
2240
|
+
}
|
|
2241
|
+
return false;
|
|
2242
|
+
}
|
|
2243
|
+
const RESHAPES = ["data.split_out", "data.aggregate"];
|
|
2244
|
+
function merge(groups) {
|
|
2245
|
+
const merged = /* @__PURE__ */ new Map();
|
|
2246
|
+
const seen = /* @__PURE__ */ new Set();
|
|
2247
|
+
groups.forEach((group) => group.forEach((fields, source) => {
|
|
2248
|
+
const names = fields.names.filter((name) => !seen.has(name));
|
|
2249
|
+
names.forEach((name) => seen.add(name));
|
|
2250
|
+
const before = merged.get(source) ?? {
|
|
2251
|
+
names: [],
|
|
2252
|
+
lists: {}
|
|
2253
|
+
};
|
|
2254
|
+
const lists = Object.fromEntries(names.filter((n) => fields.lists[n]).map((n) => [n, fields.lists[n]]));
|
|
2255
|
+
merged.set(source, {
|
|
2256
|
+
names: [...before.names, ...names],
|
|
2257
|
+
lists: {
|
|
2258
|
+
...before.lists,
|
|
2259
|
+
...lists
|
|
2260
|
+
}
|
|
2261
|
+
});
|
|
2262
|
+
}));
|
|
2263
|
+
return merged;
|
|
2264
|
+
}
|
|
2265
|
+
function flowFieldSources(graph, nodeId, definitions, learned = {}) {
|
|
2266
|
+
const walk = flowFieldWalk(graph, definitions, learned);
|
|
2267
|
+
const byType = new Map(definitions.map((definition) => [definition.type, definition]));
|
|
2268
|
+
const nodes = new Map(graph.nodes.map((node) => [node.id, node]));
|
|
2269
|
+
const known = /* @__PURE__ */ new Map();
|
|
2270
|
+
const into = flowIncoming(graph, {
|
|
2271
|
+
outOf: (id) => outOf(id),
|
|
2272
|
+
failed: (id, reached) => merge([/* @__PURE__ */ new Map([[id, FLOW_ERROR_FIELDS]]), reached]),
|
|
2273
|
+
combine: merge,
|
|
2274
|
+
none: () => /* @__PURE__ */ new Map()
|
|
2275
|
+
});
|
|
2276
|
+
const outOf = (id) => {
|
|
2277
|
+
const node = nodes.get(id);
|
|
2278
|
+
if (!node || known.has(id)) return known.get(id) ?? /* @__PURE__ */ new Map();
|
|
2279
|
+
known.set(id, /* @__PURE__ */ new Map());
|
|
2280
|
+
const passes = !RESHAPES.includes(node.type) && !!byType.get(node.type)?.passes_items;
|
|
2281
|
+
const before = node.type === "data.set_fields" || passes ? into(id) : /* @__PURE__ */ new Map();
|
|
2282
|
+
const inherited = new Set([...before.values()].flatMap((fields) => fields.names));
|
|
2283
|
+
const leaving = walk.outOf(id);
|
|
2284
|
+
const made = {
|
|
2285
|
+
...leaving,
|
|
2286
|
+
names: leaving.names.filter((name) => !inherited.has(name))
|
|
2287
|
+
};
|
|
2288
|
+
known.set(id, merge([/* @__PURE__ */ new Map([[id, made]]), before]));
|
|
2289
|
+
return known.get(id);
|
|
2290
|
+
};
|
|
2291
|
+
return [...into(nodeId)].filter(([, fields]) => fields.names.length).map(([source, fields]) => {
|
|
2292
|
+
const type = nodes.get(source)?.type ?? "";
|
|
2293
|
+
return {
|
|
2294
|
+
nodeId: source,
|
|
2295
|
+
type,
|
|
2296
|
+
label: byType.get(type)?.label ?? type,
|
|
2297
|
+
...fields
|
|
2298
|
+
};
|
|
2299
|
+
});
|
|
2300
|
+
}
|
|
2301
|
+
function flowNodeSelection(graph, node, definition, definitions, workflowFields) {
|
|
2302
|
+
const learned = workflowFields?.byNode ?? {};
|
|
2303
|
+
const incoming = flowFieldsInto(graph, node.id, definitions, learned);
|
|
2304
|
+
return {
|
|
2305
|
+
node,
|
|
2306
|
+
definition,
|
|
2307
|
+
fieldSuggestions: [.../* @__PURE__ */ new Set([...conditionFieldSuggestions(graph, node.id), ...incoming.names])],
|
|
2308
|
+
listSuggestions: Object.keys(incoming.lists),
|
|
2309
|
+
fieldSources: flowFieldsPossible(graph, node.id) ? flowFieldSources(graph, node.id, definitions, learned) : null
|
|
2310
|
+
};
|
|
1836
2311
|
}
|
|
1837
2312
|
const FLOW_SOCKET = new ClassicPreset.Socket("flow");
|
|
1838
2313
|
var FlowCanvasNode = class extends ClassicPreset.Node {
|
|
@@ -2064,7 +2539,7 @@ var FlowsCanvasNodeComponent = class FlowsCanvasNodeComponent {
|
|
|
2064
2539
|
dependencies: [
|
|
2065
2540
|
{
|
|
2066
2541
|
kind: "component",
|
|
2067
|
-
type:
|
|
2542
|
+
type: i2$3.FaIconComponent,
|
|
2068
2543
|
selector: "fa-icon",
|
|
2069
2544
|
inputs: [
|
|
2070
2545
|
"icon",
|
|
@@ -2101,13 +2576,13 @@ var FlowsCanvasNodeComponent = class FlowsCanvasNodeComponent {
|
|
|
2101
2576
|
},
|
|
2102
2577
|
{
|
|
2103
2578
|
kind: "directive",
|
|
2104
|
-
type: i2$
|
|
2579
|
+
type: i2$2.RefDirective,
|
|
2105
2580
|
selector: "[refComponent]",
|
|
2106
2581
|
inputs: ["data", "emit"]
|
|
2107
2582
|
},
|
|
2108
2583
|
{
|
|
2109
2584
|
kind: "pipe",
|
|
2110
|
-
type:
|
|
2585
|
+
type: i2$4.TranslocoPipe,
|
|
2111
2586
|
name: "transloco"
|
|
2112
2587
|
}
|
|
2113
2588
|
]
|
|
@@ -2229,11 +2704,12 @@ function setupFlowCanvas(container, injector) {
|
|
|
2229
2704
|
area.use(connection);
|
|
2230
2705
|
area.use(render);
|
|
2231
2706
|
AreaExtensions.simpleNodesOrder(area);
|
|
2232
|
-
AreaExtensions.selectableNodes(area, AreaExtensions.selector(), { accumulating: { active: () => false } });
|
|
2707
|
+
const selectable = AreaExtensions.selectableNodes(area, AreaExtensions.selector(), { accumulating: { active: () => false } });
|
|
2233
2708
|
return {
|
|
2234
2709
|
editor,
|
|
2235
2710
|
area,
|
|
2236
|
-
connection
|
|
2711
|
+
connection,
|
|
2712
|
+
selectNode: (nodeId) => selectable.select(nodeId, false)
|
|
2237
2713
|
};
|
|
2238
2714
|
}
|
|
2239
2715
|
const GRID_GAP = {
|
|
@@ -2292,8 +2768,15 @@ var FlowCanvasEditor = class {
|
|
|
2292
2768
|
async addNode(node) {
|
|
2293
2769
|
await this.rete.editor.addNode(node);
|
|
2294
2770
|
await this.rete.area.translate(node.id, node.flowNode.position ?? placementFor(this.rete, this.container, node));
|
|
2771
|
+
await this.rete.selectNode(node.id);
|
|
2295
2772
|
this.listener.selected(node.id);
|
|
2296
2773
|
}
|
|
2774
|
+
async selectNode(nodeId) {
|
|
2775
|
+
if (this.rete.editor.getNode(nodeId)) {
|
|
2776
|
+
await this.rete.selectNode(nodeId);
|
|
2777
|
+
this.listener.selected(nodeId);
|
|
2778
|
+
}
|
|
2779
|
+
}
|
|
2297
2780
|
async removeNode(nodeId) {
|
|
2298
2781
|
const attached = this.rete.editor.getConnections().filter((c) => c.source === nodeId || c.target === nodeId);
|
|
2299
2782
|
for (const connection of attached) await this.rete.editor.removeConnection(connection.id);
|
|
@@ -2341,17 +2824,23 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2341
2824
|
this.cdr = cdr;
|
|
2342
2825
|
this.graph = emptyFlowGraph();
|
|
2343
2826
|
this.definitions = [];
|
|
2827
|
+
this.workflowFields = null;
|
|
2344
2828
|
this.readOnly = false;
|
|
2345
2829
|
this.selectionChange = new EventEmitter();
|
|
2346
2830
|
this.graphChange = new EventEmitter();
|
|
2347
2831
|
this.dropped = new EventEmitter();
|
|
2348
2832
|
this.drawFailed = false;
|
|
2833
|
+
this.selected = null;
|
|
2349
2834
|
this.pending = Promise.resolve();
|
|
2350
2835
|
}
|
|
2351
2836
|
ngAfterViewInit() {
|
|
2352
2837
|
this.editor = new FlowCanvasEditor(this.host.nativeElement, this.injector, {
|
|
2353
|
-
selected: (nodeId) => this.selectionChange.emit(nodeId),
|
|
2354
|
-
changed: () =>
|
|
2838
|
+
selected: (nodeId) => this.selectionChange.emit(this.selected = nodeId),
|
|
2839
|
+
changed: () => {
|
|
2840
|
+
this.graphChange.emit();
|
|
2841
|
+
clearTimeout(this.reselect);
|
|
2842
|
+
this.reselect = setTimeout(() => this.selected && this.selectionChange.emit(this.selected));
|
|
2843
|
+
}
|
|
2355
2844
|
});
|
|
2356
2845
|
this.editor.setReadOnly(this.readOnly);
|
|
2357
2846
|
this.reload();
|
|
@@ -2360,6 +2849,7 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2360
2849
|
if (!this.editor) return;
|
|
2361
2850
|
if (changes["readOnly"]) this.editor.setReadOnly(this.readOnly);
|
|
2362
2851
|
if (changes["graph"] || changes["definitions"]) this.reload();
|
|
2852
|
+
else if (changes["workflowFields"] && this.selected) this.selectionChange.emit(this.selected);
|
|
2363
2853
|
}
|
|
2364
2854
|
addNode(type) {
|
|
2365
2855
|
const definition = this.definitions.find((d) => d.type === type);
|
|
@@ -2367,11 +2857,15 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2367
2857
|
return this.queue((editor) => {
|
|
2368
2858
|
const node = {
|
|
2369
2859
|
id: nextFlowNodeId(editor.toGraph().nodes),
|
|
2370
|
-
type
|
|
2860
|
+
type,
|
|
2861
|
+
...definition.category === "action" ? { retry: { ...FLOW_RETRY_DEFAULT } } : {}
|
|
2371
2862
|
};
|
|
2372
2863
|
return editor.addNode(createFlowCanvasNode(node, definition, definition.label));
|
|
2373
2864
|
});
|
|
2374
2865
|
}
|
|
2866
|
+
focusNode(nodeId) {
|
|
2867
|
+
return this.queue((editor) => editor.selectNode(nodeId));
|
|
2868
|
+
}
|
|
2375
2869
|
removeNode(nodeId) {
|
|
2376
2870
|
return this.queue((editor) => editor.removeNode(nodeId));
|
|
2377
2871
|
}
|
|
@@ -2381,14 +2875,7 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2381
2875
|
selection(nodeId) {
|
|
2382
2876
|
const node = this.editor?.node(nodeId);
|
|
2383
2877
|
if (!node) return null;
|
|
2384
|
-
|
|
2385
|
-
const incoming = flowFieldsInto(graph, nodeId, this.definitions);
|
|
2386
|
-
return {
|
|
2387
|
-
node: node.flowNode,
|
|
2388
|
-
definition: node.definition,
|
|
2389
|
-
fieldSuggestions: [.../* @__PURE__ */ new Set([...conditionFieldSuggestions(graph, nodeId), ...incoming.names])],
|
|
2390
|
-
listSuggestions: Object.keys(incoming.lists)
|
|
2391
|
-
};
|
|
2878
|
+
return flowNodeSelection(this.toGraph(), node.flowNode, node.definition, this.definitions, this.workflowFields);
|
|
2392
2879
|
}
|
|
2393
2880
|
toGraph() {
|
|
2394
2881
|
return this.editor?.toGraph() ?? emptyFlowGraph();
|
|
@@ -2397,6 +2884,7 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2397
2884
|
return this.queue((editor) => editor.zoomToFit());
|
|
2398
2885
|
}
|
|
2399
2886
|
ngOnDestroy() {
|
|
2887
|
+
clearTimeout(this.reselect);
|
|
2400
2888
|
this.editor?.destroy();
|
|
2401
2889
|
this.editor = void 0;
|
|
2402
2890
|
}
|
|
@@ -2432,6 +2920,7 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2432
2920
|
inputs: {
|
|
2433
2921
|
graph: "graph",
|
|
2434
2922
|
definitions: "definitions",
|
|
2923
|
+
workflowFields: "workflowFields",
|
|
2435
2924
|
readOnly: "readOnly"
|
|
2436
2925
|
},
|
|
2437
2926
|
outputs: {
|
|
@@ -2461,7 +2950,7 @@ var FlowsGraphCanvasComponent = class FlowsGraphCanvasComponent {
|
|
|
2461
2950
|
styles: [":host{display:block;position:relative;height:100%;overflow:hidden;background-color:#f7f8fa;background-image:radial-gradient(#cfd4dc 1px,transparent 1px);background-size:16px 16px}.pw-graph-canvas{width:100%;height:100%}.pw-graph-canvas__error{position:absolute;top:12px;left:12px;right:12px;margin:0;padding:8px 12px;border:1px solid #c0392b;border-radius:4px;background:#fff;color:#c0392b}\n"],
|
|
2462
2951
|
dependencies: [{
|
|
2463
2952
|
kind: "pipe",
|
|
2464
|
-
type:
|
|
2953
|
+
type: i2$4.TranslocoPipe,
|
|
2465
2954
|
name: "transloco"
|
|
2466
2955
|
}]
|
|
2467
2956
|
});
|
|
@@ -2492,6 +2981,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
2492
2981
|
propDecorators: {
|
|
2493
2982
|
graph: [{ type: Input }],
|
|
2494
2983
|
definitions: [{ type: Input }],
|
|
2984
|
+
workflowFields: [{ type: Input }],
|
|
2495
2985
|
readOnly: [{
|
|
2496
2986
|
type: HostBinding,
|
|
2497
2987
|
args: ["class.is-read-only"]
|
|
@@ -2505,32 +2995,217 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
2505
2995
|
}]
|
|
2506
2996
|
}
|
|
2507
2997
|
});
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
}
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
}
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2998
|
+
const FIELD_KINDS = {
|
|
2999
|
+
"trigger.schedule": {
|
|
3000
|
+
cron: "cron",
|
|
3001
|
+
timezone: "timezone"
|
|
3002
|
+
},
|
|
3003
|
+
"trigger.webhook": { path: "text" },
|
|
3004
|
+
"data.set_fields": { fields: "pairs" },
|
|
3005
|
+
"data.merge": { mode: "mode" },
|
|
3006
|
+
"data.split_out": { field: "list" },
|
|
3007
|
+
"action.email": {
|
|
3008
|
+
to: "email",
|
|
3009
|
+
subject: "text",
|
|
3010
|
+
body: "textarea"
|
|
3011
|
+
},
|
|
3012
|
+
"action.in_app_note": {
|
|
3013
|
+
user_id: "member",
|
|
3014
|
+
message: "textarea"
|
|
3015
|
+
},
|
|
3016
|
+
"action.push_notification": {
|
|
3017
|
+
user_id: "member",
|
|
3018
|
+
title: "text",
|
|
3019
|
+
message: "textarea"
|
|
3020
|
+
},
|
|
3021
|
+
"action.websocket": {
|
|
3022
|
+
user_ids: "members",
|
|
3023
|
+
payload: "json"
|
|
3024
|
+
}
|
|
3025
|
+
};
|
|
3026
|
+
function flowNodeFields(definition) {
|
|
3027
|
+
const kinds = FIELD_KINDS[definition.type] ?? {};
|
|
3028
|
+
return definition.params.map((key) => {
|
|
3029
|
+
const details = definition.param_details?.[key] ?? {};
|
|
3030
|
+
return {
|
|
3031
|
+
...details,
|
|
3032
|
+
key,
|
|
3033
|
+
kind: details.kind ?? kinds[key] ?? "text"
|
|
3034
|
+
};
|
|
3035
|
+
});
|
|
3036
|
+
}
|
|
3037
|
+
function flowNumberValue(value) {
|
|
3038
|
+
const text = typeof value === "string" ? value.trim() : value;
|
|
3039
|
+
return typeof text === "string" && /^-?\d+(\.\d+)?$/.test(text) ? Number(text) : text;
|
|
3040
|
+
}
|
|
3041
|
+
const FLOW_MERGE_MODES = ["append"];
|
|
3042
|
+
function flowParamLabelKey(key) {
|
|
3043
|
+
return `Flows.Params.${key}`;
|
|
3044
|
+
}
|
|
3045
|
+
function flowParamHelpKey(type, key) {
|
|
3046
|
+
return `Flows.ParamHelp.${type}.${key}`;
|
|
3047
|
+
}
|
|
3048
|
+
var FlowsGraphCheckComponent = class FlowsGraphCheckComponent {
|
|
3049
|
+
constructor(translation) {
|
|
3050
|
+
this.translation = translation;
|
|
3051
|
+
this.definitions = [];
|
|
3052
|
+
this.graph = null;
|
|
3053
|
+
this.result = null;
|
|
3054
|
+
this.icons = FLOWS_ICONS;
|
|
3055
|
+
this.rows = [];
|
|
3056
|
+
}
|
|
3057
|
+
ngOnChanges() {
|
|
3058
|
+
const nodes = this.graph?.nodes ?? [];
|
|
3059
|
+
const row = (issue, severity) => ({
|
|
3060
|
+
issue,
|
|
3061
|
+
severity,
|
|
3062
|
+
place: this.place(nodes.find((node) => node.id === issue.node_id)),
|
|
3063
|
+
text: this.describe(issue)
|
|
3064
|
+
});
|
|
3065
|
+
this.rows = this.result ? [...this.result.errors.map((i) => row(i, "error")), ...this.result.warnings.map((i) => row(i, "warning"))] : [];
|
|
3066
|
+
}
|
|
3067
|
+
goTo(issue) {
|
|
3068
|
+
if (!issue.node_id) return;
|
|
3069
|
+
const fieldId = issue.field ? `flow-node-${issue.node_id}-${issue.field}` : null;
|
|
3070
|
+
this.canvas.focusNode(issue.node_id).then(() => {
|
|
3071
|
+
setTimeout(() => fieldId ? document.getElementById(fieldId)?.focus() : void 0);
|
|
3072
|
+
});
|
|
3073
|
+
}
|
|
3074
|
+
place(node) {
|
|
3075
|
+
if (!node) return "";
|
|
3076
|
+
const key = flowNodeLabelKey(node.type);
|
|
3077
|
+
const label = this.translation.translate(key);
|
|
3078
|
+
return `${label === key ? this.definitions.find((d) => d.type === node.type)?.label ?? node.type : label} (${node.id})`;
|
|
3079
|
+
}
|
|
3080
|
+
describe(issue) {
|
|
3081
|
+
const fieldKey = issue.field ? flowParamLabelKey(issue.field) : "";
|
|
3082
|
+
const fieldLabel = fieldKey ? this.translation.translate(fieldKey) : "";
|
|
3083
|
+
const key = `Flows.Check.Codes.${issue.code}`;
|
|
3084
|
+
const text = this.translation.translate(key, { field: fieldLabel === fieldKey ? issue.field : fieldLabel });
|
|
3085
|
+
return text === key ? issue.message : text;
|
|
3086
|
+
}
|
|
3087
|
+
static {
|
|
3088
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
3089
|
+
minVersion: "12.0.0",
|
|
3090
|
+
version: "22.2.0",
|
|
3091
|
+
ngImport: i0,
|
|
3092
|
+
type: FlowsGraphCheckComponent,
|
|
3093
|
+
deps: [{ token: i2$4.TranslocoService }],
|
|
3094
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
3095
|
+
});
|
|
3096
|
+
}
|
|
3097
|
+
static {
|
|
3098
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
3099
|
+
minVersion: "17.0.0",
|
|
3100
|
+
version: "22.2.0",
|
|
3101
|
+
type: FlowsGraphCheckComponent,
|
|
3102
|
+
isStandalone: false,
|
|
3103
|
+
selector: "pw-flows-graph-check",
|
|
3104
|
+
inputs: {
|
|
3105
|
+
canvas: "canvas",
|
|
3106
|
+
definitions: "definitions",
|
|
3107
|
+
graph: "graph",
|
|
3108
|
+
result: "result"
|
|
3109
|
+
},
|
|
3110
|
+
usesOnChanges: true,
|
|
3111
|
+
ngImport: i0,
|
|
3112
|
+
template: "@if (rows.length) {\n<div class=\"pw-graph-check\"\n role=\"alert\"\n data-testid=\"flow-check-result\">\n <p class=\"pw-graph-check__summary is-blocking\">\n {{ 'Flows.Check.Blocking' | transloco: { count: result?.errors?.length } }}\n </p>\n <ul class=\"pw-graph-check__list\">\n @for (row of rows; track $index) {\n <li [class]=\"'pw-graph-check__item is-' + row.severity\">\n <fa-icon [icon]=\"row.severity === 'error' ? icons.error : icons.warning\"\n aria-hidden=\"true\"></fa-icon>\n @if (row.issue.node_id) {\n <button type=\"button\"\n class=\"btn btn-link p-0 pw-graph-check__place\"\n data-testid=\"flow-check-go-to\"\n (click)=\"goTo(row.issue)\">{{ row.place || row.issue.node_id }}</button>\n }\n <span>{{ row.text }}</span>\n </li>\n }\n </ul>\n</div>\n}\n",
|
|
3113
|
+
styles: [":host{display:block}.pw-graph-check{border:1px solid #e2e5ea;border-radius:6px;padding:10px 12px;margin-bottom:8px}.pw-graph-check__summary{margin:0 0 6px;font-weight:600;color:#8a6d00}.pw-graph-check__summary.is-blocking{color:#c0392b}.pw-graph-check__list{list-style:none;padding:0;margin:0}.pw-graph-check__item{display:flex;align-items:baseline;gap:6px;padding:2px 0}.pw-graph-check__item.is-error fa-icon{color:#c0392b}.pw-graph-check__item.is-warning fa-icon{color:#b8860b}.pw-graph-check__place{white-space:nowrap}\n"],
|
|
3114
|
+
dependencies: [{
|
|
3115
|
+
kind: "component",
|
|
3116
|
+
type: i2$3.FaIconComponent,
|
|
3117
|
+
selector: "fa-icon",
|
|
3118
|
+
inputs: [
|
|
3119
|
+
"icon",
|
|
3120
|
+
"title",
|
|
3121
|
+
"animation",
|
|
3122
|
+
"mask",
|
|
3123
|
+
"flip",
|
|
3124
|
+
"size",
|
|
3125
|
+
"pull",
|
|
3126
|
+
"border",
|
|
3127
|
+
"inverse",
|
|
3128
|
+
"symbol",
|
|
3129
|
+
"rotate",
|
|
3130
|
+
"fixedWidth",
|
|
3131
|
+
"transform",
|
|
3132
|
+
"a11yRole"
|
|
3133
|
+
],
|
|
3134
|
+
outputs: [
|
|
3135
|
+
"iconChange",
|
|
3136
|
+
"titleChange",
|
|
3137
|
+
"animationChange",
|
|
3138
|
+
"maskChange",
|
|
3139
|
+
"flipChange",
|
|
3140
|
+
"sizeChange",
|
|
3141
|
+
"pullChange",
|
|
3142
|
+
"borderChange",
|
|
3143
|
+
"inverseChange",
|
|
3144
|
+
"symbolChange",
|
|
3145
|
+
"rotateChange",
|
|
3146
|
+
"fixedWidthChange",
|
|
3147
|
+
"transformChange",
|
|
3148
|
+
"a11yRoleChange"
|
|
3149
|
+
]
|
|
3150
|
+
}, {
|
|
3151
|
+
kind: "pipe",
|
|
3152
|
+
type: i2$4.TranslocoPipe,
|
|
3153
|
+
name: "transloco"
|
|
3154
|
+
}]
|
|
3155
|
+
});
|
|
3156
|
+
}
|
|
3157
|
+
};
|
|
3158
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
3159
|
+
minVersion: "12.0.0",
|
|
3160
|
+
version: "22.2.0",
|
|
3161
|
+
ngImport: i0,
|
|
3162
|
+
type: FlowsGraphCheckComponent,
|
|
3163
|
+
decorators: [{
|
|
3164
|
+
type: Component,
|
|
3165
|
+
args: [{
|
|
3166
|
+
selector: "pw-flows-graph-check",
|
|
3167
|
+
standalone: false,
|
|
3168
|
+
template: "@if (rows.length) {\n<div class=\"pw-graph-check\"\n role=\"alert\"\n data-testid=\"flow-check-result\">\n <p class=\"pw-graph-check__summary is-blocking\">\n {{ 'Flows.Check.Blocking' | transloco: { count: result?.errors?.length } }}\n </p>\n <ul class=\"pw-graph-check__list\">\n @for (row of rows; track $index) {\n <li [class]=\"'pw-graph-check__item is-' + row.severity\">\n <fa-icon [icon]=\"row.severity === 'error' ? icons.error : icons.warning\"\n aria-hidden=\"true\"></fa-icon>\n @if (row.issue.node_id) {\n <button type=\"button\"\n class=\"btn btn-link p-0 pw-graph-check__place\"\n data-testid=\"flow-check-go-to\"\n (click)=\"goTo(row.issue)\">{{ row.place || row.issue.node_id }}</button>\n }\n <span>{{ row.text }}</span>\n </li>\n }\n </ul>\n</div>\n}\n",
|
|
3169
|
+
styles: [":host{display:block}.pw-graph-check{border:1px solid #e2e5ea;border-radius:6px;padding:10px 12px;margin-bottom:8px}.pw-graph-check__summary{margin:0 0 6px;font-weight:600;color:#8a6d00}.pw-graph-check__summary.is-blocking{color:#c0392b}.pw-graph-check__list{list-style:none;padding:0;margin:0}.pw-graph-check__item{display:flex;align-items:baseline;gap:6px;padding:2px 0}.pw-graph-check__item.is-error fa-icon{color:#c0392b}.pw-graph-check__item.is-warning fa-icon{color:#b8860b}.pw-graph-check__place{white-space:nowrap}\n"]
|
|
3170
|
+
}]
|
|
3171
|
+
}],
|
|
3172
|
+
ctorParameters: () => [{ type: i2$4.TranslocoService }],
|
|
3173
|
+
propDecorators: {
|
|
3174
|
+
canvas: [{
|
|
3175
|
+
type: Input,
|
|
3176
|
+
args: [{ required: true }]
|
|
3177
|
+
}],
|
|
3178
|
+
definitions: [{ type: Input }],
|
|
3179
|
+
graph: [{ type: Input }],
|
|
3180
|
+
result: [{ type: Input }]
|
|
3181
|
+
}
|
|
3182
|
+
});
|
|
3183
|
+
var FlowsNodePaletteComponent = class FlowsNodePaletteComponent {
|
|
3184
|
+
constructor() {
|
|
3185
|
+
this.definitions = [];
|
|
3186
|
+
this.add = new EventEmitter();
|
|
3187
|
+
this.icons = FLOW_CATEGORY_ICONS;
|
|
3188
|
+
this.labelKey = flowNodeLabelKey;
|
|
3189
|
+
this.groups = [];
|
|
3190
|
+
}
|
|
3191
|
+
ngOnChanges() {
|
|
3192
|
+
this.groups = FLOW_NODE_CATEGORIES.map((category) => ({
|
|
3193
|
+
category,
|
|
3194
|
+
nodes: this.definitions.filter((d) => d.category === category && !d.retired)
|
|
3195
|
+
})).filter((group) => group.nodes.length);
|
|
3196
|
+
}
|
|
3197
|
+
static {
|
|
3198
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
3199
|
+
minVersion: "12.0.0",
|
|
3200
|
+
version: "22.2.0",
|
|
3201
|
+
ngImport: i0,
|
|
3202
|
+
type: FlowsNodePaletteComponent,
|
|
3203
|
+
deps: [],
|
|
3204
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
3205
|
+
});
|
|
3206
|
+
}
|
|
3207
|
+
static {
|
|
3208
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
2534
3209
|
minVersion: "17.0.0",
|
|
2535
3210
|
version: "22.2.0",
|
|
2536
3211
|
type: FlowsNodePaletteComponent,
|
|
@@ -2544,7 +3219,7 @@ var FlowsNodePaletteComponent = class FlowsNodePaletteComponent {
|
|
|
2544
3219
|
styles: [".pw-node-palette{display:flex;flex-direction:column;gap:2px;padding:12px}.pw-node-palette__heading{margin:12px 0 4px;color:#7c8696;font-size:12px;font-weight:500;letter-spacing:.04em;text-transform:uppercase}.pw-node-palette__heading:first-child{margin-top:0}.pw-node-palette__item{display:flex;align-items:center;gap:8px;width:100%;padding:6px 8px;border:1px solid transparent;border-radius:4px;background:none;color:#1a1d21;text-align:left;transition:background-color .15s ease-out,border-color .15s ease-out}.pw-node-palette__item:hover{background:#eef0f3}.pw-node-palette__item:focus-visible{border-color:var(--first);outline:none}.pw-node-palette__icon{width:16px;color:#5a6473}\n"],
|
|
2545
3220
|
dependencies: [{
|
|
2546
3221
|
kind: "component",
|
|
2547
|
-
type:
|
|
3222
|
+
type: i2$3.FaIconComponent,
|
|
2548
3223
|
selector: "fa-icon",
|
|
2549
3224
|
inputs: [
|
|
2550
3225
|
"icon",
|
|
@@ -2580,7 +3255,7 @@ var FlowsNodePaletteComponent = class FlowsNodePaletteComponent {
|
|
|
2580
3255
|
]
|
|
2581
3256
|
}, {
|
|
2582
3257
|
kind: "pipe",
|
|
2583
|
-
type:
|
|
3258
|
+
type: i2$4.TranslocoPipe,
|
|
2584
3259
|
name: "transloco"
|
|
2585
3260
|
}]
|
|
2586
3261
|
});
|
|
@@ -2605,53 +3280,6 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
2605
3280
|
add: [{ type: Output }]
|
|
2606
3281
|
}
|
|
2607
3282
|
});
|
|
2608
|
-
const FIELD_KINDS = {
|
|
2609
|
-
"trigger.schedule": {
|
|
2610
|
-
cron: "cron",
|
|
2611
|
-
timezone: "timezone"
|
|
2612
|
-
},
|
|
2613
|
-
"trigger.webhook": { path: "text" },
|
|
2614
|
-
"data.set_fields": { fields: "pairs" },
|
|
2615
|
-
"data.merge": { mode: "mode" },
|
|
2616
|
-
"data.split_out": { field: "list" },
|
|
2617
|
-
"action.email": {
|
|
2618
|
-
to: "email",
|
|
2619
|
-
subject: "text",
|
|
2620
|
-
body: "textarea"
|
|
2621
|
-
},
|
|
2622
|
-
"action.in_app_note": {
|
|
2623
|
-
user_id: "member",
|
|
2624
|
-
message: "textarea"
|
|
2625
|
-
},
|
|
2626
|
-
"action.push_notification": {
|
|
2627
|
-
user_id: "member",
|
|
2628
|
-
title: "text",
|
|
2629
|
-
message: "textarea"
|
|
2630
|
-
},
|
|
2631
|
-
"action.websocket": {
|
|
2632
|
-
user_ids: "members",
|
|
2633
|
-
payload: "json"
|
|
2634
|
-
}
|
|
2635
|
-
};
|
|
2636
|
-
function flowNodeFields(definition) {
|
|
2637
|
-
const kinds = FIELD_KINDS[definition.type] ?? {};
|
|
2638
|
-
return definition.params.map((key) => {
|
|
2639
|
-
const details = definition.param_details?.[key] ?? {};
|
|
2640
|
-
return {
|
|
2641
|
-
...details,
|
|
2642
|
-
key,
|
|
2643
|
-
kind: details.kind ?? kinds[key] ?? "text"
|
|
2644
|
-
};
|
|
2645
|
-
});
|
|
2646
|
-
}
|
|
2647
|
-
function flowNumberValue(value) {
|
|
2648
|
-
const text = typeof value === "string" ? value.trim() : value;
|
|
2649
|
-
return typeof text === "string" && /^-?\d+(\.\d+)?$/.test(text) ? Number(text) : text;
|
|
2650
|
-
}
|
|
2651
|
-
const FLOW_MERGE_MODES = ["append"];
|
|
2652
|
-
function flowParamLabelKey(key) {
|
|
2653
|
-
return `Flows.Params.${key}`;
|
|
2654
|
-
}
|
|
2655
3283
|
const FLOW_CRON_MODES = [
|
|
2656
3284
|
"minutes",
|
|
2657
3285
|
"hourly",
|
|
@@ -2821,7 +3449,7 @@ var FlowsCronFieldComponent = class FlowsCronFieldComponent {
|
|
|
2821
3449
|
version: "22.2.0",
|
|
2822
3450
|
ngImport: i0,
|
|
2823
3451
|
type: FlowsCronFieldComponent,
|
|
2824
|
-
deps: [{ token:
|
|
3452
|
+
deps: [{ token: i2$4.TranslocoService }],
|
|
2825
3453
|
target: i0.ɵɵFactoryTarget.Component
|
|
2826
3454
|
});
|
|
2827
3455
|
}
|
|
@@ -2902,7 +3530,7 @@ var FlowsCronFieldComponent = class FlowsCronFieldComponent {
|
|
|
2902
3530
|
},
|
|
2903
3531
|
{
|
|
2904
3532
|
kind: "pipe",
|
|
2905
|
-
type:
|
|
3533
|
+
type: i2$4.TranslocoPipe,
|
|
2906
3534
|
name: "transloco"
|
|
2907
3535
|
}
|
|
2908
3536
|
]
|
|
@@ -2922,7 +3550,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
2922
3550
|
template: "<div class=\"d-flex flex-column gap-2\">\n <select class=\"form-select\"\n [id]=\"inputId\"\n [disabled]=\"readOnly\"\n [ngModel]=\"schedule.mode\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setMode($event)\">\n @for (mode of modes; track mode) {\n <option [ngValue]=\"mode\">{{ 'Flows.Schedule.Mode.' + mode | transloco }}</option>\n }\n </select>\n\n @switch (schedule.mode) {\n @case ('minutes') {\n <select class=\"form-select\"\n [attr.aria-label]=\"'Flows.Schedule.Every' | transloco\"\n [disabled]=\"readOnly\"\n [ngModel]=\"schedule.every\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"update({ every: $event })\">\n @for (every of everyOptions; track every) {\n <option [ngValue]=\"every\">{{ 'Flows.Schedule.EveryMinutes' | transloco: { count: every } }}</option>\n }\n </select>\n }\n @case ('hourly') {\n <input class=\"form-control\"\n type=\"number\"\n min=\"0\"\n max=\"59\"\n [attr.aria-label]=\"'Flows.Schedule.Minute' | transloco\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"schedule.minute\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"update({ minute: +$event })\" />\n }\n @case ('custom') {\n <input class=\"form-control\"\n type=\"text\"\n placeholder=\"0 9 * * 1-5\"\n [attr.aria-label]=\"'Flows.Schedule.Mode.custom' | transloco\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"schedule.custom\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"update({ custom: $event })\" />\n }\n @default {\n <div class=\"d-flex gap-2\">\n @if (schedule.mode === 'weekly') {\n <select class=\"form-select\"\n [attr.aria-label]=\"'Flows.Schedule.Weekday' | transloco\"\n [disabled]=\"readOnly\"\n [ngModel]=\"schedule.weekday\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"update({ weekday: $event })\">\n @for (day of weekdays; track day.value) {\n <option [ngValue]=\"day.value\">{{ day.label }}</option>\n }\n </select>\n }\n @if (schedule.mode === 'monthly') {\n <select class=\"form-select\"\n [attr.aria-label]=\"'Flows.Schedule.Monthday' | transloco\"\n [disabled]=\"readOnly\"\n [ngModel]=\"schedule.monthday\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"update({ monthday: $event })\">\n @for (day of monthdays; track day) {\n <option [ngValue]=\"day\">{{ day }}</option>\n }\n </select>\n }\n <input class=\"form-control\"\n type=\"time\"\n [attr.aria-label]=\"'Flows.Schedule.Time' | transloco\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"time\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setTime($event)\" />\n </div>\n }\n }\n\n @if (schedule.mode !== 'custom') {\n <small class=\"text-muted\">\n {{ 'Flows.Schedule.Summary.' + schedule.mode | transloco: { count: schedule.every, minute: schedule.minute, time: time, weekday: weekdayLabel, day: schedule.monthday } }}\n </small>\n }\n</div>\n"
|
|
2923
3551
|
}]
|
|
2924
3552
|
}],
|
|
2925
|
-
ctorParameters: () => [{ type:
|
|
3553
|
+
ctorParameters: () => [{ type: i2$4.TranslocoService }],
|
|
2926
3554
|
propDecorators: {
|
|
2927
3555
|
value: [{ type: Input }],
|
|
2928
3556
|
inputId: [{ type: Input }],
|
|
@@ -3072,7 +3700,7 @@ var FlowsTimezoneFieldComponent = class FlowsTimezoneFieldComponent {
|
|
|
3072
3700
|
},
|
|
3073
3701
|
{
|
|
3074
3702
|
kind: "pipe",
|
|
3075
|
-
type:
|
|
3703
|
+
type: i2$4.TranslocoPipe,
|
|
3076
3704
|
name: "transloco"
|
|
3077
3705
|
}
|
|
3078
3706
|
]
|
|
@@ -3212,13 +3840,13 @@ var FlowsJsonFieldComponent = class FlowsJsonFieldComponent {
|
|
|
3212
3840
|
},
|
|
3213
3841
|
{
|
|
3214
3842
|
kind: "component",
|
|
3215
|
-
type: i2.FieldErrorDisplayComponent,
|
|
3843
|
+
type: i2$1.FieldErrorDisplayComponent,
|
|
3216
3844
|
selector: "pw-field-error-display",
|
|
3217
3845
|
inputs: ["errorMsg", "displayError"]
|
|
3218
3846
|
},
|
|
3219
3847
|
{
|
|
3220
3848
|
kind: "pipe",
|
|
3221
|
-
type:
|
|
3849
|
+
type: i2$4.TranslocoPipe,
|
|
3222
3850
|
name: "transloco"
|
|
3223
3851
|
}
|
|
3224
3852
|
]
|
|
@@ -3478,7 +4106,7 @@ var FlowsConditionFieldComponent = class FlowsConditionFieldComponent {
|
|
|
3478
4106
|
ngImport: i0,
|
|
3479
4107
|
type: FlowsConditionFieldComponent,
|
|
3480
4108
|
deps: [
|
|
3481
|
-
{ token:
|
|
4109
|
+
{ token: i2$4.TranslocoService },
|
|
3482
4110
|
{ token: i0.ChangeDetectorRef },
|
|
3483
4111
|
{ token: i0.DestroyRef }
|
|
3484
4112
|
],
|
|
@@ -3541,7 +4169,7 @@ var FlowsConditionFieldComponent = class FlowsConditionFieldComponent {
|
|
|
3541
4169
|
},
|
|
3542
4170
|
{
|
|
3543
4171
|
kind: "directive",
|
|
3544
|
-
type:
|
|
4172
|
+
type: i1$1.Tooltip,
|
|
3545
4173
|
selector: "[pTooltip]",
|
|
3546
4174
|
inputs: [
|
|
3547
4175
|
"tooltipPosition",
|
|
@@ -3639,7 +4267,7 @@ var FlowsConditionFieldComponent = class FlowsConditionFieldComponent {
|
|
|
3639
4267
|
},
|
|
3640
4268
|
{
|
|
3641
4269
|
kind: "component",
|
|
3642
|
-
type:
|
|
4270
|
+
type: i2$3.FaIconComponent,
|
|
3643
4271
|
selector: "fa-icon",
|
|
3644
4272
|
inputs: [
|
|
3645
4273
|
"icon",
|
|
@@ -3687,7 +4315,7 @@ var FlowsConditionFieldComponent = class FlowsConditionFieldComponent {
|
|
|
3687
4315
|
},
|
|
3688
4316
|
{
|
|
3689
4317
|
kind: "pipe",
|
|
3690
|
-
type:
|
|
4318
|
+
type: i2$4.TranslocoPipe,
|
|
3691
4319
|
name: "transloco"
|
|
3692
4320
|
}
|
|
3693
4321
|
]
|
|
@@ -3709,7 +4337,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
3709
4337
|
}]
|
|
3710
4338
|
}],
|
|
3711
4339
|
ctorParameters: () => [
|
|
3712
|
-
{ type:
|
|
4340
|
+
{ type: i2$4.TranslocoService },
|
|
3713
4341
|
{ type: i0.ChangeDetectorRef },
|
|
3714
4342
|
{ type: i0.DestroyRef }
|
|
3715
4343
|
],
|
|
@@ -3810,7 +4438,7 @@ var FlowsPairsFieldComponent = class FlowsPairsFieldComponent {
|
|
|
3810
4438
|
},
|
|
3811
4439
|
{
|
|
3812
4440
|
kind: "directive",
|
|
3813
|
-
type:
|
|
4441
|
+
type: i1$1.Tooltip,
|
|
3814
4442
|
selector: "[pTooltip]",
|
|
3815
4443
|
inputs: [
|
|
3816
4444
|
"tooltipPosition",
|
|
@@ -3838,7 +4466,7 @@ var FlowsPairsFieldComponent = class FlowsPairsFieldComponent {
|
|
|
3838
4466
|
},
|
|
3839
4467
|
{
|
|
3840
4468
|
kind: "component",
|
|
3841
|
-
type:
|
|
4469
|
+
type: i2$3.FaIconComponent,
|
|
3842
4470
|
selector: "fa-icon",
|
|
3843
4471
|
inputs: [
|
|
3844
4472
|
"icon",
|
|
@@ -3875,7 +4503,7 @@ var FlowsPairsFieldComponent = class FlowsPairsFieldComponent {
|
|
|
3875
4503
|
},
|
|
3876
4504
|
{
|
|
3877
4505
|
kind: "pipe",
|
|
3878
|
-
type:
|
|
4506
|
+
type: i2$4.TranslocoPipe,
|
|
3879
4507
|
name: "transloco"
|
|
3880
4508
|
}
|
|
3881
4509
|
]
|
|
@@ -3950,62 +4578,465 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
3950
4578
|
}],
|
|
3951
4579
|
ctorParameters: () => [{ type: i1.SubscriptionService }]
|
|
3952
4580
|
});
|
|
3953
|
-
function toFlowMember(row) {
|
|
3954
|
-
const name = [row.first_name, row.last_name].filter(Boolean).join(" ").trim();
|
|
3955
|
-
return {
|
|
3956
|
-
id: row.id,
|
|
3957
|
-
name: name || row.email || `#${row.id}`,
|
|
3958
|
-
email: row.email ?? ""
|
|
3959
|
-
};
|
|
4581
|
+
function toFlowMember(row) {
|
|
4582
|
+
const name = [row.first_name, row.last_name].filter(Boolean).join(" ").trim();
|
|
4583
|
+
return {
|
|
4584
|
+
id: row.id,
|
|
4585
|
+
name: name || row.email || `#${row.id}`,
|
|
4586
|
+
email: row.email ?? ""
|
|
4587
|
+
};
|
|
4588
|
+
}
|
|
4589
|
+
var FlowsMemberFieldComponent = class FlowsMemberFieldComponent {
|
|
4590
|
+
constructor(members, cdr) {
|
|
4591
|
+
this.members = members;
|
|
4592
|
+
this.cdr = cdr;
|
|
4593
|
+
this.multiple = false;
|
|
4594
|
+
this.readOnly = false;
|
|
4595
|
+
this.valueChange = new EventEmitter();
|
|
4596
|
+
this.selection = null;
|
|
4597
|
+
this.suggestions = [];
|
|
4598
|
+
this.failed = false;
|
|
4599
|
+
}
|
|
4600
|
+
ngOnChanges() {
|
|
4601
|
+
const chosen = toIds(this.value).map((id) => this.members.knownMember(id) ?? {
|
|
4602
|
+
id,
|
|
4603
|
+
name: `#${id}`,
|
|
4604
|
+
email: ""
|
|
4605
|
+
});
|
|
4606
|
+
this.selection = this.multiple ? chosen : chosen[0] ?? null;
|
|
4607
|
+
}
|
|
4608
|
+
complete(query) {
|
|
4609
|
+
this.search?.unsubscribe();
|
|
4610
|
+
this.search = this.members.search(this.subscriptionId, query).subscribe({
|
|
4611
|
+
next: (members) => {
|
|
4612
|
+
this.failed = false;
|
|
4613
|
+
this.suggestions = members;
|
|
4614
|
+
this.cdr.markForCheck();
|
|
4615
|
+
},
|
|
4616
|
+
error: () => {
|
|
4617
|
+
this.failed = true;
|
|
4618
|
+
this.suggestions = [];
|
|
4619
|
+
this.cdr.markForCheck();
|
|
4620
|
+
}
|
|
4621
|
+
});
|
|
4622
|
+
}
|
|
4623
|
+
changed(selection) {
|
|
4624
|
+
if (Array.isArray(selection)) this.valueChange.emit(selection.map((member) => member.id));
|
|
4625
|
+
else this.valueChange.emit(selection?.id);
|
|
4626
|
+
}
|
|
4627
|
+
ngOnDestroy() {
|
|
4628
|
+
this.search?.unsubscribe();
|
|
4629
|
+
}
|
|
4630
|
+
static {
|
|
4631
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
4632
|
+
minVersion: "12.0.0",
|
|
4633
|
+
version: "22.2.0",
|
|
4634
|
+
ngImport: i0,
|
|
4635
|
+
type: FlowsMemberFieldComponent,
|
|
4636
|
+
deps: [{ token: FlowsMemberService }, { token: i0.ChangeDetectorRef }],
|
|
4637
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
4638
|
+
});
|
|
4639
|
+
}
|
|
4640
|
+
static {
|
|
4641
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
4642
|
+
minVersion: "17.0.0",
|
|
4643
|
+
version: "22.2.0",
|
|
4644
|
+
type: FlowsMemberFieldComponent,
|
|
4645
|
+
isStandalone: false,
|
|
4646
|
+
selector: "pw-flows-member-field",
|
|
4647
|
+
inputs: {
|
|
4648
|
+
value: "value",
|
|
4649
|
+
multiple: "multiple",
|
|
4650
|
+
subscriptionId: "subscriptionId",
|
|
4651
|
+
inputId: "inputId",
|
|
4652
|
+
readOnly: "readOnly"
|
|
4653
|
+
},
|
|
4654
|
+
outputs: { valueChange: "valueChange" },
|
|
4655
|
+
usesOnChanges: true,
|
|
4656
|
+
ngImport: i0,
|
|
4657
|
+
template: "<p-auto-complete class=\"w-100\"\n [inputId]=\"inputId\"\n [ngModel]=\"selection\"\n [ngModelOptions]=\"{ standalone: true }\"\n [suggestions]=\"suggestions\"\n [multiple]=\"multiple\"\n [forceSelection]=\"true\"\n [disabled]=\"readOnly\"\n [minQueryLength]=\"1\"\n [delay]=\"250\"\n [showEmptyMessage]=\"true\"\n [emptyMessage]=\"'Flows.Inspector.NoMembers' | transloco\"\n optionLabel=\"name\"\n dataKey=\"id\"\n appendTo=\"body\"\n (completeMethod)=\"complete($event.query)\"\n (ngModelChange)=\"changed($event)\">\n <ng-template let-member\n #item>\n <div class=\"d-flex flex-column\">\n <span>{{ member.name }}</span>\n <small class=\"text-muted\">{{ member.email }}</small>\n </div>\n </ng-template>\n</p-auto-complete>\n@if (failed) {\n<pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Inspector.MembersUnavailable' | transloco\">\n</pw-field-error-display>\n}\n",
|
|
4658
|
+
dependencies: [
|
|
4659
|
+
{
|
|
4660
|
+
kind: "directive",
|
|
4661
|
+
type: i3$2.NgControlStatus,
|
|
4662
|
+
selector: "[formControlName],[ngModel],[formControl]"
|
|
4663
|
+
},
|
|
4664
|
+
{
|
|
4665
|
+
kind: "directive",
|
|
4666
|
+
type: i3$2.NgModel,
|
|
4667
|
+
selector: "[ngModel]:not([formControlName]):not([formControl])",
|
|
4668
|
+
inputs: [
|
|
4669
|
+
"name",
|
|
4670
|
+
"disabled",
|
|
4671
|
+
"ngModel",
|
|
4672
|
+
"ngModelOptions"
|
|
4673
|
+
],
|
|
4674
|
+
outputs: ["ngModelChange"],
|
|
4675
|
+
exportAs: ["ngModel"]
|
|
4676
|
+
},
|
|
4677
|
+
{
|
|
4678
|
+
kind: "component",
|
|
4679
|
+
type: i3.AutoComplete,
|
|
4680
|
+
selector: "p-autocomplete, p-auto-complete",
|
|
4681
|
+
inputs: [
|
|
4682
|
+
"minQueryLength",
|
|
4683
|
+
"delay",
|
|
4684
|
+
"panelStyle",
|
|
4685
|
+
"panelStyleClass",
|
|
4686
|
+
"inputStyle",
|
|
4687
|
+
"inputId",
|
|
4688
|
+
"inputStyleClass",
|
|
4689
|
+
"placeholder",
|
|
4690
|
+
"readonly",
|
|
4691
|
+
"scrollHeight",
|
|
4692
|
+
"lazy",
|
|
4693
|
+
"virtualScroll",
|
|
4694
|
+
"virtualScrollItemSize",
|
|
4695
|
+
"virtualScrollOptions",
|
|
4696
|
+
"autoHighlight",
|
|
4697
|
+
"forceSelection",
|
|
4698
|
+
"type",
|
|
4699
|
+
"autoZIndex",
|
|
4700
|
+
"baseZIndex",
|
|
4701
|
+
"ariaLabel",
|
|
4702
|
+
"dropdownAriaLabel",
|
|
4703
|
+
"ariaLabelledBy",
|
|
4704
|
+
"dropdownIcon",
|
|
4705
|
+
"unique",
|
|
4706
|
+
"group",
|
|
4707
|
+
"completeOnFocus",
|
|
4708
|
+
"showClear",
|
|
4709
|
+
"dropdown",
|
|
4710
|
+
"showEmptyMessage",
|
|
4711
|
+
"dropdownMode",
|
|
4712
|
+
"multiple",
|
|
4713
|
+
"addOnTab",
|
|
4714
|
+
"tabindex",
|
|
4715
|
+
"dataKey",
|
|
4716
|
+
"emptyMessage",
|
|
4717
|
+
"autofocus",
|
|
4718
|
+
"autocomplete",
|
|
4719
|
+
"optionGroupChildren",
|
|
4720
|
+
"optionGroupLabel",
|
|
4721
|
+
"overlayOptions",
|
|
4722
|
+
"suggestions",
|
|
4723
|
+
"optionLabel",
|
|
4724
|
+
"optionValue",
|
|
4725
|
+
"id",
|
|
4726
|
+
"searchMessage",
|
|
4727
|
+
"emptySelectionMessage",
|
|
4728
|
+
"selectionMessage",
|
|
4729
|
+
"autoOptionFocus",
|
|
4730
|
+
"selectOnFocus",
|
|
4731
|
+
"searchLocale",
|
|
4732
|
+
"optionDisabled",
|
|
4733
|
+
"focusOnHover",
|
|
4734
|
+
"typeahead",
|
|
4735
|
+
"addOnBlur",
|
|
4736
|
+
"separator",
|
|
4737
|
+
"appendTo",
|
|
4738
|
+
"motionOptions"
|
|
4739
|
+
],
|
|
4740
|
+
outputs: [
|
|
4741
|
+
"completeMethod",
|
|
4742
|
+
"onSelect",
|
|
4743
|
+
"onUnselect",
|
|
4744
|
+
"onAdd",
|
|
4745
|
+
"onFocus",
|
|
4746
|
+
"onBlur",
|
|
4747
|
+
"onDropdownClick",
|
|
4748
|
+
"onClear",
|
|
4749
|
+
"onInputKeydown",
|
|
4750
|
+
"onKeyUp",
|
|
4751
|
+
"onShow",
|
|
4752
|
+
"onHide",
|
|
4753
|
+
"onLazyLoad"
|
|
4754
|
+
]
|
|
4755
|
+
},
|
|
4756
|
+
{
|
|
4757
|
+
kind: "component",
|
|
4758
|
+
type: i2$1.FieldErrorDisplayComponent,
|
|
4759
|
+
selector: "pw-field-error-display",
|
|
4760
|
+
inputs: ["errorMsg", "displayError"]
|
|
4761
|
+
},
|
|
4762
|
+
{
|
|
4763
|
+
kind: "pipe",
|
|
4764
|
+
type: i2$4.TranslocoPipe,
|
|
4765
|
+
name: "transloco"
|
|
4766
|
+
}
|
|
4767
|
+
]
|
|
4768
|
+
});
|
|
4769
|
+
}
|
|
4770
|
+
};
|
|
4771
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
4772
|
+
minVersion: "12.0.0",
|
|
4773
|
+
version: "22.2.0",
|
|
4774
|
+
ngImport: i0,
|
|
4775
|
+
type: FlowsMemberFieldComponent,
|
|
4776
|
+
decorators: [{
|
|
4777
|
+
type: Component,
|
|
4778
|
+
args: [{
|
|
4779
|
+
selector: "pw-flows-member-field",
|
|
4780
|
+
standalone: false,
|
|
4781
|
+
template: "<p-auto-complete class=\"w-100\"\n [inputId]=\"inputId\"\n [ngModel]=\"selection\"\n [ngModelOptions]=\"{ standalone: true }\"\n [suggestions]=\"suggestions\"\n [multiple]=\"multiple\"\n [forceSelection]=\"true\"\n [disabled]=\"readOnly\"\n [minQueryLength]=\"1\"\n [delay]=\"250\"\n [showEmptyMessage]=\"true\"\n [emptyMessage]=\"'Flows.Inspector.NoMembers' | transloco\"\n optionLabel=\"name\"\n dataKey=\"id\"\n appendTo=\"body\"\n (completeMethod)=\"complete($event.query)\"\n (ngModelChange)=\"changed($event)\">\n <ng-template let-member\n #item>\n <div class=\"d-flex flex-column\">\n <span>{{ member.name }}</span>\n <small class=\"text-muted\">{{ member.email }}</small>\n </div>\n </ng-template>\n</p-auto-complete>\n@if (failed) {\n<pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Inspector.MembersUnavailable' | transloco\">\n</pw-field-error-display>\n}\n"
|
|
4782
|
+
}]
|
|
4783
|
+
}],
|
|
4784
|
+
ctorParameters: () => [{ type: FlowsMemberService }, { type: i0.ChangeDetectorRef }],
|
|
4785
|
+
propDecorators: {
|
|
4786
|
+
value: [{ type: Input }],
|
|
4787
|
+
multiple: [{ type: Input }],
|
|
4788
|
+
subscriptionId: [{ type: Input }],
|
|
4789
|
+
inputId: [{ type: Input }],
|
|
4790
|
+
readOnly: [{ type: Input }],
|
|
4791
|
+
valueChange: [{ type: Output }]
|
|
4792
|
+
}
|
|
4793
|
+
});
|
|
4794
|
+
function toIds(value) {
|
|
4795
|
+
return (Array.isArray(value) ? value : [value]).map(Number).filter((id) => Number.isInteger(id) && id > 0);
|
|
4796
|
+
}
|
|
4797
|
+
var FlowsRetryFieldComponent = class FlowsRetryFieldComponent {
|
|
4798
|
+
constructor() {
|
|
4799
|
+
this.readOnly = false;
|
|
4800
|
+
this.valueChange = new EventEmitter();
|
|
4801
|
+
}
|
|
4802
|
+
toggle(on) {
|
|
4803
|
+
this.valueChange.emit(on ? { ...FLOW_RETRY_DEFAULT } : void 0);
|
|
4804
|
+
}
|
|
4805
|
+
set(key, text, max) {
|
|
4806
|
+
const number = Math.min(Math.max(Math.round(Number(text)) || 1, 1), max);
|
|
4807
|
+
this.valueChange.emit({
|
|
4808
|
+
...this.value ?? FLOW_RETRY_DEFAULT,
|
|
4809
|
+
[key]: number
|
|
4810
|
+
});
|
|
4811
|
+
}
|
|
4812
|
+
static {
|
|
4813
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
4814
|
+
minVersion: "12.0.0",
|
|
4815
|
+
version: "22.2.0",
|
|
4816
|
+
ngImport: i0,
|
|
4817
|
+
type: FlowsRetryFieldComponent,
|
|
4818
|
+
deps: [],
|
|
4819
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
4820
|
+
});
|
|
4821
|
+
}
|
|
4822
|
+
static {
|
|
4823
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
4824
|
+
minVersion: "17.0.0",
|
|
4825
|
+
version: "22.2.0",
|
|
4826
|
+
type: FlowsRetryFieldComponent,
|
|
4827
|
+
isStandalone: false,
|
|
4828
|
+
selector: "pw-flows-retry-field",
|
|
4829
|
+
inputs: {
|
|
4830
|
+
value: "value",
|
|
4831
|
+
inputId: "inputId",
|
|
4832
|
+
readOnly: "readOnly"
|
|
4833
|
+
},
|
|
4834
|
+
outputs: { valueChange: "valueChange" },
|
|
4835
|
+
ngImport: i0,
|
|
4836
|
+
template: "<pw-input-container [label]=\"'Flows.Inspector.Retry' | transloco\"\n name=\"retry\"\n [controlId]=\"inputId\"\n [useAriaLabelledbyOnly]=\"true\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.RetryHint' | transloco\">\n <ui-switch size=\"small\"\n [id]=\"inputId\"\n [checked]=\"!!value\"\n [disabled]=\"readOnly\"\n [attr.aria-labelledby]=\"inputId + '-label'\"\n (change)=\"toggle($event)\"></ui-switch>\n</pw-input-container>\n\n@if (value) {\n<pw-input-container [label]=\"'Flows.Inspector.RetryTimes' | transloco\"\n name=\"retry_times\"\n [controlId]=\"inputId + '-times'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.RetryTimesHint' | transloco\">\n <input class=\"form-control\"\n type=\"number\"\n min=\"1\"\n max=\"5\"\n [id]=\"inputId + '-times'\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"value.times\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"set('times', $event, 5)\" />\n</pw-input-container>\n\n<pw-input-container [label]=\"'Flows.Inspector.RetryWait' | transloco\"\n name=\"retry_wait_seconds\"\n [controlId]=\"inputId + '-wait'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.RetryWaitHint' | transloco\">\n <input class=\"form-control\"\n type=\"number\"\n min=\"1\"\n max=\"300\"\n [id]=\"inputId + '-wait'\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"value.wait_seconds\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"set('wait_seconds', $event, 300)\" />\n</pw-input-container>\n}\n",
|
|
4837
|
+
dependencies: [
|
|
4838
|
+
{
|
|
4839
|
+
kind: "directive",
|
|
4840
|
+
type: i3$2.DefaultValueAccessor,
|
|
4841
|
+
selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]"
|
|
4842
|
+
},
|
|
4843
|
+
{
|
|
4844
|
+
kind: "directive",
|
|
4845
|
+
type: i3$2.NumberValueAccessor,
|
|
4846
|
+
selector: "input[type=number]:not([ngNoCva])[formControlName],input[type=number]:not([ngNoCva])[formControl],input[type=number]:not([ngNoCva])[ngModel]"
|
|
4847
|
+
},
|
|
4848
|
+
{
|
|
4849
|
+
kind: "directive",
|
|
4850
|
+
type: i3$2.NgControlStatus,
|
|
4851
|
+
selector: "[formControlName],[ngModel],[formControl]"
|
|
4852
|
+
},
|
|
4853
|
+
{
|
|
4854
|
+
kind: "directive",
|
|
4855
|
+
type: i3$2.MinValidator,
|
|
4856
|
+
selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]",
|
|
4857
|
+
inputs: ["min"]
|
|
4858
|
+
},
|
|
4859
|
+
{
|
|
4860
|
+
kind: "directive",
|
|
4861
|
+
type: i3$2.MaxValidator,
|
|
4862
|
+
selector: "input[type=number][max][formControlName],input[type=number][max][formControl],input[type=number][max][ngModel]",
|
|
4863
|
+
inputs: ["max"]
|
|
4864
|
+
},
|
|
4865
|
+
{
|
|
4866
|
+
kind: "directive",
|
|
4867
|
+
type: i3$2.NgModel,
|
|
4868
|
+
selector: "[ngModel]:not([formControlName]):not([formControl])",
|
|
4869
|
+
inputs: [
|
|
4870
|
+
"name",
|
|
4871
|
+
"disabled",
|
|
4872
|
+
"ngModel",
|
|
4873
|
+
"ngModelOptions"
|
|
4874
|
+
],
|
|
4875
|
+
outputs: ["ngModelChange"],
|
|
4876
|
+
exportAs: ["ngModel"]
|
|
4877
|
+
},
|
|
4878
|
+
{
|
|
4879
|
+
kind: "component",
|
|
4880
|
+
type: i2.UiSwitchComponent,
|
|
4881
|
+
selector: "ui-switch",
|
|
4882
|
+
inputs: [
|
|
4883
|
+
"size",
|
|
4884
|
+
"color",
|
|
4885
|
+
"switchOffColor",
|
|
4886
|
+
"switchColor",
|
|
4887
|
+
"defaultBgColor",
|
|
4888
|
+
"defaultBoColor",
|
|
4889
|
+
"checkedLabel",
|
|
4890
|
+
"uncheckedLabel",
|
|
4891
|
+
"checkedTextColor",
|
|
4892
|
+
"uncheckedTextColor",
|
|
4893
|
+
"beforeChange",
|
|
4894
|
+
"ariaLabel",
|
|
4895
|
+
"checked",
|
|
4896
|
+
"disabled",
|
|
4897
|
+
"reverse",
|
|
4898
|
+
"loading"
|
|
4899
|
+
],
|
|
4900
|
+
outputs: [
|
|
4901
|
+
"change",
|
|
4902
|
+
"changeEvent",
|
|
4903
|
+
"valueChange"
|
|
4904
|
+
]
|
|
4905
|
+
},
|
|
4906
|
+
{
|
|
4907
|
+
kind: "component",
|
|
4908
|
+
type: i6.InputContainerComponent,
|
|
4909
|
+
selector: "pw-input-container",
|
|
4910
|
+
inputs: [
|
|
4911
|
+
"name",
|
|
4912
|
+
"controlId",
|
|
4913
|
+
"useAriaLabelledbyOnly",
|
|
4914
|
+
"label",
|
|
4915
|
+
"labelClass",
|
|
4916
|
+
"tooltipPosition",
|
|
4917
|
+
"required",
|
|
4918
|
+
"errorMsg",
|
|
4919
|
+
"isReadOnly",
|
|
4920
|
+
"showTooltip",
|
|
4921
|
+
"tooltipText",
|
|
4922
|
+
"showTriangle",
|
|
4923
|
+
"afterLabel",
|
|
4924
|
+
"showAfterLabel",
|
|
4925
|
+
"showTriangleText",
|
|
4926
|
+
"isLeftTooltip"
|
|
4927
|
+
]
|
|
4928
|
+
},
|
|
4929
|
+
{
|
|
4930
|
+
kind: "pipe",
|
|
4931
|
+
type: i2$4.TranslocoPipe,
|
|
4932
|
+
name: "transloco"
|
|
4933
|
+
}
|
|
4934
|
+
]
|
|
4935
|
+
});
|
|
4936
|
+
}
|
|
4937
|
+
};
|
|
4938
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
4939
|
+
minVersion: "12.0.0",
|
|
4940
|
+
version: "22.2.0",
|
|
4941
|
+
ngImport: i0,
|
|
4942
|
+
type: FlowsRetryFieldComponent,
|
|
4943
|
+
decorators: [{
|
|
4944
|
+
type: Component,
|
|
4945
|
+
args: [{
|
|
4946
|
+
selector: "pw-flows-retry-field",
|
|
4947
|
+
standalone: false,
|
|
4948
|
+
template: "<pw-input-container [label]=\"'Flows.Inspector.Retry' | transloco\"\n name=\"retry\"\n [controlId]=\"inputId\"\n [useAriaLabelledbyOnly]=\"true\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.RetryHint' | transloco\">\n <ui-switch size=\"small\"\n [id]=\"inputId\"\n [checked]=\"!!value\"\n [disabled]=\"readOnly\"\n [attr.aria-labelledby]=\"inputId + '-label'\"\n (change)=\"toggle($event)\"></ui-switch>\n</pw-input-container>\n\n@if (value) {\n<pw-input-container [label]=\"'Flows.Inspector.RetryTimes' | transloco\"\n name=\"retry_times\"\n [controlId]=\"inputId + '-times'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.RetryTimesHint' | transloco\">\n <input class=\"form-control\"\n type=\"number\"\n min=\"1\"\n max=\"5\"\n [id]=\"inputId + '-times'\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"value.times\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"set('times', $event, 5)\" />\n</pw-input-container>\n\n<pw-input-container [label]=\"'Flows.Inspector.RetryWait' | transloco\"\n name=\"retry_wait_seconds\"\n [controlId]=\"inputId + '-wait'\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.RetryWaitHint' | transloco\">\n <input class=\"form-control\"\n type=\"number\"\n min=\"1\"\n max=\"300\"\n [id]=\"inputId + '-wait'\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"value.wait_seconds\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"set('wait_seconds', $event, 300)\" />\n</pw-input-container>\n}\n"
|
|
4949
|
+
}]
|
|
4950
|
+
}],
|
|
4951
|
+
propDecorators: {
|
|
4952
|
+
value: [{ type: Input }],
|
|
4953
|
+
inputId: [{ type: Input }],
|
|
4954
|
+
readOnly: [{ type: Input }],
|
|
4955
|
+
valueChange: [{ type: Output }]
|
|
4956
|
+
}
|
|
4957
|
+
});
|
|
4958
|
+
const TEXT_TYPES = [
|
|
4959
|
+
"text",
|
|
4960
|
+
"search",
|
|
4961
|
+
"url"
|
|
4962
|
+
];
|
|
4963
|
+
const FIELD_NAME_BOX = "-field";
|
|
4964
|
+
const SEARCH_FROM = 12;
|
|
4965
|
+
function isTextBox(element) {
|
|
4966
|
+
return element instanceof HTMLTextAreaElement || element instanceof HTMLInputElement && TEXT_TYPES.includes(element.type);
|
|
3960
4967
|
}
|
|
3961
|
-
var
|
|
3962
|
-
constructor(
|
|
3963
|
-
this.
|
|
3964
|
-
this.
|
|
3965
|
-
this.multiple = false;
|
|
4968
|
+
var FlowsAvailableFieldsComponent = class FlowsAvailableFieldsComponent {
|
|
4969
|
+
constructor(host, cdr) {
|
|
4970
|
+
this.host = host;
|
|
4971
|
+
this.sources = [];
|
|
3966
4972
|
this.readOnly = false;
|
|
3967
|
-
this.
|
|
3968
|
-
this.
|
|
3969
|
-
this.
|
|
3970
|
-
this.
|
|
3971
|
-
|
|
3972
|
-
|
|
3973
|
-
|
|
3974
|
-
|
|
3975
|
-
|
|
3976
|
-
|
|
3977
|
-
});
|
|
3978
|
-
this.selection = this.multiple ? chosen : chosen[0] ?? null;
|
|
3979
|
-
}
|
|
3980
|
-
complete(query) {
|
|
3981
|
-
this.search?.unsubscribe();
|
|
3982
|
-
this.search = this.members.search(this.subscriptionId, query).subscribe({
|
|
3983
|
-
next: (members) => {
|
|
3984
|
-
this.failed = false;
|
|
3985
|
-
this.suggestions = members;
|
|
3986
|
-
this.cdr.markForCheck();
|
|
3987
|
-
},
|
|
3988
|
-
error: () => {
|
|
3989
|
-
this.failed = true;
|
|
3990
|
-
this.suggestions = [];
|
|
3991
|
-
this.cdr.markForCheck();
|
|
4973
|
+
this.firstRun = false;
|
|
4974
|
+
this.nodeType = "";
|
|
4975
|
+
this.labelKey = flowNodeLabelKey;
|
|
4976
|
+
this.query = "";
|
|
4977
|
+
this.names = false;
|
|
4978
|
+
afterEveryRender(() => {
|
|
4979
|
+
const names = this.takesNames();
|
|
4980
|
+
if (names !== this.names) {
|
|
4981
|
+
this.names = names;
|
|
4982
|
+
cdr.markForCheck();
|
|
3992
4983
|
}
|
|
3993
4984
|
});
|
|
3994
4985
|
}
|
|
3995
|
-
|
|
3996
|
-
|
|
3997
|
-
|
|
4986
|
+
get searchable() {
|
|
4987
|
+
const count = (source) => source.names.filter((name) => this.fits(source.lists[name] ? "list" : "value", this.names)).length + (this.fits("entry", this.names) ? Object.values(source.lists).flat().length : 0);
|
|
4988
|
+
return this.sources.reduce((total, source) => total + count(source), 0) > SEARCH_FROM;
|
|
3998
4989
|
}
|
|
3999
|
-
|
|
4000
|
-
this.
|
|
4990
|
+
remember(target) {
|
|
4991
|
+
const panel = this.host.nativeElement.closest(".pw-node-inspector");
|
|
4992
|
+
if (isTextBox(target) && panel?.contains(target) && !target.closest("pw-flows-condition-field") && !this.host.nativeElement.contains(target)) {
|
|
4993
|
+
this.box = target;
|
|
4994
|
+
this.names = this.takesNames();
|
|
4995
|
+
}
|
|
4996
|
+
}
|
|
4997
|
+
takesNames() {
|
|
4998
|
+
return !!this.target()?.id.endsWith(FIELD_NAME_BOX);
|
|
4999
|
+
}
|
|
5000
|
+
offers(source, names) {
|
|
5001
|
+
const lists = Object.keys(source.lists);
|
|
5002
|
+
return source.names.some((name) => this.fits(lists.includes(name) ? "list" : "value", names)) || lists.length > 0 && this.fits("entry", names);
|
|
5003
|
+
}
|
|
5004
|
+
matches(name) {
|
|
5005
|
+
return !this.query || name.toLowerCase().includes(this.query.trim().toLowerCase());
|
|
5006
|
+
}
|
|
5007
|
+
fits(kind, names) {
|
|
5008
|
+
if (!names) return true;
|
|
5009
|
+
return this.nodeType === "data.split_out" ? kind === "list" : kind !== "entry";
|
|
5010
|
+
}
|
|
5011
|
+
placeholder(field, names) {
|
|
5012
|
+
return names ? field : `{{${field}}}`;
|
|
5013
|
+
}
|
|
5014
|
+
entry(list, key) {
|
|
5015
|
+
return `${list}.*.${key}`;
|
|
5016
|
+
}
|
|
5017
|
+
insert(field) {
|
|
5018
|
+
const box = this.target();
|
|
5019
|
+
const names = this.takesNames();
|
|
5020
|
+
if (this.readOnly || !box?.isConnected || box.readOnly) return;
|
|
5021
|
+
box.focus();
|
|
5022
|
+
if (names) box.value = field;
|
|
5023
|
+
else box.setRangeText(this.placeholder(field, names), box.selectionStart ?? box.value.length, box.selectionEnd ?? box.value.length, "end");
|
|
5024
|
+
box.dispatchEvent(new Event("input", { bubbles: true }));
|
|
5025
|
+
}
|
|
5026
|
+
target() {
|
|
5027
|
+
return this.box?.isConnected ? this.box : this.onlyBox();
|
|
5028
|
+
}
|
|
5029
|
+
onlyBox() {
|
|
5030
|
+
const boxes = [...this.host.nativeElement.closest(".pw-node-inspector")?.querySelectorAll("input, textarea") ?? []].filter((element) => isTextBox(element) && !element.closest("pw-flows-condition-field") && !this.host.nativeElement.contains(element));
|
|
5031
|
+
return boxes.length === 1 ? boxes[0] : void 0;
|
|
4001
5032
|
}
|
|
4002
5033
|
static {
|
|
4003
5034
|
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
4004
5035
|
minVersion: "12.0.0",
|
|
4005
5036
|
version: "22.2.0",
|
|
4006
5037
|
ngImport: i0,
|
|
4007
|
-
type:
|
|
4008
|
-
deps: [{ token:
|
|
5038
|
+
type: FlowsAvailableFieldsComponent,
|
|
5039
|
+
deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }],
|
|
4009
5040
|
target: i0.ɵɵFactoryTarget.Component
|
|
4010
5041
|
});
|
|
4011
5042
|
}
|
|
@@ -4013,127 +5044,80 @@ var FlowsMemberFieldComponent = class FlowsMemberFieldComponent {
|
|
|
4013
5044
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
4014
5045
|
minVersion: "17.0.0",
|
|
4015
5046
|
version: "22.2.0",
|
|
4016
|
-
type:
|
|
5047
|
+
type: FlowsAvailableFieldsComponent,
|
|
4017
5048
|
isStandalone: false,
|
|
4018
|
-
selector: "pw-flows-
|
|
5049
|
+
selector: "pw-flows-available-fields",
|
|
4019
5050
|
inputs: {
|
|
4020
|
-
|
|
4021
|
-
multiple: "multiple",
|
|
4022
|
-
subscriptionId: "subscriptionId",
|
|
5051
|
+
sources: "sources",
|
|
4023
5052
|
inputId: "inputId",
|
|
4024
|
-
readOnly: "readOnly"
|
|
5053
|
+
readOnly: "readOnly",
|
|
5054
|
+
firstRun: "firstRun",
|
|
5055
|
+
nodeType: "nodeType"
|
|
4025
5056
|
},
|
|
4026
|
-
|
|
4027
|
-
usesOnChanges: true,
|
|
5057
|
+
host: { listeners: { "document:focusin": "remember($event.target)" } },
|
|
4028
5058
|
ngImport: i0,
|
|
4029
|
-
template: "<
|
|
5059
|
+
template: "<pw-input-container [label]=\"'Flows.Inspector.AvailableFields' | transloco\"\n name=\"available_fields\"\n [controlId]=\"inputId\"\n [useAriaLabelledbyOnly]=\"true\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.AvailableFieldsHint' | transloco\">\n @if (sources.length) {\n <div [id]=\"inputId\"\n class=\"pw-available-fields\"\n role=\"group\"\n [attr.aria-labelledby]=\"inputId + '-label'\">\n @if (searchable) {\n <input type=\"search\"\n class=\"form-control form-control-sm pw-available-fields__search\"\n data-testid=\"flow-available-fields-search\"\n [placeholder]=\"'Flows.Inspector.SearchFields' | transloco\"\n [attr.aria-label]=\"'Flows.Inspector.SearchFields' | transloco\"\n [value]=\"query\"\n (input)=\"query = $any($event.target).value\">\n }\n <div class=\"pw-available-fields__groups\"\n data-testid=\"flow-available-fields-groups\">\n @for (source of sources; track source.nodeId) {\n @if (offers(source, names)) {\n @let key = labelKey(source.type);\n @let translated = key | transloco;\n <section class=\"pw-available-fields__group\">\n <p class=\"pw-available-fields__from\"\n [attr.data-testid]=\"'flow-available-fields-from-' + source.nodeId\">\n {{ translated === key ? source.label : translated }}\n <span class=\"pw-available-fields__id\">{{ source.nodeId }}</span>\n </p>\n <div class=\"pw-available-fields__chips\">\n @for (field of source.names; track field) {\n @let kind = source.lists[field] ? 'list' : 'value';\n @if (matches(field) && fits(kind, names)) {\n <button type=\"button\"\n class=\"pw-available-fields__chip\"\n [disabled]=\"readOnly\"\n [attr.data-testid]=\"'flow-available-field-' + field\"\n [pTooltip]=\"placeholder(field, names)\"\n tooltipPosition=\"top\"\n appendTo=\"body\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"insert(field)\">{{ field }}</button>\n }\n }\n </div>\n @if (fits('entry', names)) {\n @for (list of source.lists | keyvalue; track list.key) {\n <details class=\"pw-available-fields__list\"\n [open]=\"!!query\">\n <summary>{{ 'Flows.Inspector.FieldsIn' | transloco: { list: list.key, count: list.value.length } }}</summary>\n <div class=\"pw-available-fields__chips\">\n @for (field of list.value; track field) {\n @if (matches(field)) {\n <button type=\"button\"\n class=\"pw-available-fields__chip\"\n [disabled]=\"readOnly\"\n [attr.data-testid]=\"'flow-available-field-' + entry(list.key, field)\"\n [pTooltip]=\"placeholder(entry(list.key, field), names)\"\n tooltipPosition=\"top\"\n appendTo=\"body\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"insert(entry(list.key, field))\">{{ field }}</button>\n }\n }\n </div>\n </details>\n }\n }\n </section>\n }\n }\n </div>\n </div>\n } @else {\n <p class=\"pw-available-fields__none\"\n data-testid=\"flow-available-fields-none\">{{ (firstRun ? 'Flows.Inspector.FirstRunFields' : 'Flows.Inspector.NoAvailableFields') | transloco }}</p>\n }\n</pw-input-container>\n",
|
|
5060
|
+
styles: [".pw-available-fields{display:flex;flex-direction:column;gap:10px}.pw-available-fields__search{max-width:100%}.pw-available-fields__groups{display:flex;flex-direction:column;gap:10px;max-height:220px;overflow-y:auto;padding-right:4px}.pw-available-fields__group+.pw-available-fields__group{border-top:1px solid #e2e5ea;padding-top:10px}.pw-available-fields__from{margin:0 0 6px;font-size:12px;font-weight:600;color:#1a1d21}.pw-available-fields__id{margin-left:4px;font-weight:400;color:#7c8696}.pw-available-fields__chips{display:flex;flex-wrap:wrap;gap:4px}.pw-available-fields__chip{border:1px solid #d5dae1;border-radius:4px;background-color:#f5f7fa;color:#1a1d21;padding:1px 8px;font-size:12px;line-height:20px;cursor:pointer}.pw-available-fields__chip:hover:not(:disabled){border-color:var(--first);background-color:#fff}.pw-available-fields__chip:disabled{cursor:not-allowed;opacity:.4}.pw-available-fields__list{margin-top:6px}.pw-available-fields__list summary{cursor:pointer;margin-bottom:4px;font-size:12px;color:#5a6473}.pw-available-fields__none{margin:0;color:#5a6473;font-size:12px}\n"],
|
|
4030
5061
|
dependencies: [
|
|
4031
5062
|
{
|
|
4032
5063
|
kind: "directive",
|
|
4033
|
-
type:
|
|
4034
|
-
selector: "[
|
|
4035
|
-
},
|
|
4036
|
-
{
|
|
4037
|
-
kind: "directive",
|
|
4038
|
-
type: i3$2.NgModel,
|
|
4039
|
-
selector: "[ngModel]:not([formControlName]):not([formControl])",
|
|
5064
|
+
type: i1$1.Tooltip,
|
|
5065
|
+
selector: "[pTooltip]",
|
|
4040
5066
|
inputs: [
|
|
4041
|
-
"
|
|
4042
|
-
"
|
|
4043
|
-
"
|
|
4044
|
-
"
|
|
4045
|
-
|
|
4046
|
-
|
|
4047
|
-
|
|
5067
|
+
"tooltipPosition",
|
|
5068
|
+
"tooltipEvent",
|
|
5069
|
+
"positionStyle",
|
|
5070
|
+
"tooltipStyleClass",
|
|
5071
|
+
"tooltipZIndex",
|
|
5072
|
+
"escape",
|
|
5073
|
+
"showDelay",
|
|
5074
|
+
"hideDelay",
|
|
5075
|
+
"life",
|
|
5076
|
+
"positionTop",
|
|
5077
|
+
"positionLeft",
|
|
5078
|
+
"autoHide",
|
|
5079
|
+
"fitContent",
|
|
5080
|
+
"hideOnEscape",
|
|
5081
|
+
"showOnEllipsis",
|
|
5082
|
+
"pTooltip",
|
|
5083
|
+
"tooltipDisabled",
|
|
5084
|
+
"tooltipOptions",
|
|
5085
|
+
"appendTo",
|
|
5086
|
+
"pTooltipPT",
|
|
5087
|
+
"pTooltipUnstyled"
|
|
5088
|
+
]
|
|
4048
5089
|
},
|
|
4049
5090
|
{
|
|
4050
5091
|
kind: "component",
|
|
4051
|
-
type:
|
|
4052
|
-
selector: "
|
|
5092
|
+
type: i6.InputContainerComponent,
|
|
5093
|
+
selector: "pw-input-container",
|
|
4053
5094
|
inputs: [
|
|
4054
|
-
"
|
|
4055
|
-
"
|
|
4056
|
-
"
|
|
4057
|
-
"
|
|
4058
|
-
"
|
|
4059
|
-
"
|
|
4060
|
-
"
|
|
4061
|
-
"
|
|
4062
|
-
"
|
|
4063
|
-
"
|
|
4064
|
-
"
|
|
4065
|
-
"
|
|
4066
|
-
"
|
|
4067
|
-
"
|
|
4068
|
-
"
|
|
4069
|
-
"
|
|
4070
|
-
"type",
|
|
4071
|
-
"autoZIndex",
|
|
4072
|
-
"baseZIndex",
|
|
4073
|
-
"ariaLabel",
|
|
4074
|
-
"dropdownAriaLabel",
|
|
4075
|
-
"ariaLabelledBy",
|
|
4076
|
-
"dropdownIcon",
|
|
4077
|
-
"unique",
|
|
4078
|
-
"group",
|
|
4079
|
-
"completeOnFocus",
|
|
4080
|
-
"showClear",
|
|
4081
|
-
"dropdown",
|
|
4082
|
-
"showEmptyMessage",
|
|
4083
|
-
"dropdownMode",
|
|
4084
|
-
"multiple",
|
|
4085
|
-
"addOnTab",
|
|
4086
|
-
"tabindex",
|
|
4087
|
-
"dataKey",
|
|
4088
|
-
"emptyMessage",
|
|
4089
|
-
"autofocus",
|
|
4090
|
-
"autocomplete",
|
|
4091
|
-
"optionGroupChildren",
|
|
4092
|
-
"optionGroupLabel",
|
|
4093
|
-
"overlayOptions",
|
|
4094
|
-
"suggestions",
|
|
4095
|
-
"optionLabel",
|
|
4096
|
-
"optionValue",
|
|
4097
|
-
"id",
|
|
4098
|
-
"searchMessage",
|
|
4099
|
-
"emptySelectionMessage",
|
|
4100
|
-
"selectionMessage",
|
|
4101
|
-
"autoOptionFocus",
|
|
4102
|
-
"selectOnFocus",
|
|
4103
|
-
"searchLocale",
|
|
4104
|
-
"optionDisabled",
|
|
4105
|
-
"focusOnHover",
|
|
4106
|
-
"typeahead",
|
|
4107
|
-
"addOnBlur",
|
|
4108
|
-
"separator",
|
|
4109
|
-
"appendTo",
|
|
4110
|
-
"motionOptions"
|
|
4111
|
-
],
|
|
4112
|
-
outputs: [
|
|
4113
|
-
"completeMethod",
|
|
4114
|
-
"onSelect",
|
|
4115
|
-
"onUnselect",
|
|
4116
|
-
"onAdd",
|
|
4117
|
-
"onFocus",
|
|
4118
|
-
"onBlur",
|
|
4119
|
-
"onDropdownClick",
|
|
4120
|
-
"onClear",
|
|
4121
|
-
"onInputKeydown",
|
|
4122
|
-
"onKeyUp",
|
|
4123
|
-
"onShow",
|
|
4124
|
-
"onHide",
|
|
4125
|
-
"onLazyLoad"
|
|
5095
|
+
"name",
|
|
5096
|
+
"controlId",
|
|
5097
|
+
"useAriaLabelledbyOnly",
|
|
5098
|
+
"label",
|
|
5099
|
+
"labelClass",
|
|
5100
|
+
"tooltipPosition",
|
|
5101
|
+
"required",
|
|
5102
|
+
"errorMsg",
|
|
5103
|
+
"isReadOnly",
|
|
5104
|
+
"showTooltip",
|
|
5105
|
+
"tooltipText",
|
|
5106
|
+
"showTriangle",
|
|
5107
|
+
"afterLabel",
|
|
5108
|
+
"showAfterLabel",
|
|
5109
|
+
"showTriangleText",
|
|
5110
|
+
"isLeftTooltip"
|
|
4126
5111
|
]
|
|
4127
5112
|
},
|
|
4128
5113
|
{
|
|
4129
|
-
kind: "
|
|
4130
|
-
type:
|
|
4131
|
-
|
|
4132
|
-
inputs: ["errorMsg", "displayError"]
|
|
5114
|
+
kind: "pipe",
|
|
5115
|
+
type: i1$2.KeyValuePipe,
|
|
5116
|
+
name: "keyvalue"
|
|
4133
5117
|
},
|
|
4134
5118
|
{
|
|
4135
5119
|
kind: "pipe",
|
|
4136
|
-
type:
|
|
5120
|
+
type: i2$4.TranslocoPipe,
|
|
4137
5121
|
name: "transloco"
|
|
4138
5122
|
}
|
|
4139
5123
|
]
|
|
@@ -4144,28 +5128,29 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4144
5128
|
minVersion: "12.0.0",
|
|
4145
5129
|
version: "22.2.0",
|
|
4146
5130
|
ngImport: i0,
|
|
4147
|
-
type:
|
|
5131
|
+
type: FlowsAvailableFieldsComponent,
|
|
4148
5132
|
decorators: [{
|
|
4149
5133
|
type: Component,
|
|
4150
5134
|
args: [{
|
|
4151
|
-
selector: "pw-flows-
|
|
5135
|
+
selector: "pw-flows-available-fields",
|
|
4152
5136
|
standalone: false,
|
|
4153
|
-
template: "<
|
|
5137
|
+
template: "<pw-input-container [label]=\"'Flows.Inspector.AvailableFields' | transloco\"\n name=\"available_fields\"\n [controlId]=\"inputId\"\n [useAriaLabelledbyOnly]=\"true\"\n [showTooltip]=\"true\"\n [tooltipText]=\"'Flows.Inspector.AvailableFieldsHint' | transloco\">\n @if (sources.length) {\n <div [id]=\"inputId\"\n class=\"pw-available-fields\"\n role=\"group\"\n [attr.aria-labelledby]=\"inputId + '-label'\">\n @if (searchable) {\n <input type=\"search\"\n class=\"form-control form-control-sm pw-available-fields__search\"\n data-testid=\"flow-available-fields-search\"\n [placeholder]=\"'Flows.Inspector.SearchFields' | transloco\"\n [attr.aria-label]=\"'Flows.Inspector.SearchFields' | transloco\"\n [value]=\"query\"\n (input)=\"query = $any($event.target).value\">\n }\n <div class=\"pw-available-fields__groups\"\n data-testid=\"flow-available-fields-groups\">\n @for (source of sources; track source.nodeId) {\n @if (offers(source, names)) {\n @let key = labelKey(source.type);\n @let translated = key | transloco;\n <section class=\"pw-available-fields__group\">\n <p class=\"pw-available-fields__from\"\n [attr.data-testid]=\"'flow-available-fields-from-' + source.nodeId\">\n {{ translated === key ? source.label : translated }}\n <span class=\"pw-available-fields__id\">{{ source.nodeId }}</span>\n </p>\n <div class=\"pw-available-fields__chips\">\n @for (field of source.names; track field) {\n @let kind = source.lists[field] ? 'list' : 'value';\n @if (matches(field) && fits(kind, names)) {\n <button type=\"button\"\n class=\"pw-available-fields__chip\"\n [disabled]=\"readOnly\"\n [attr.data-testid]=\"'flow-available-field-' + field\"\n [pTooltip]=\"placeholder(field, names)\"\n tooltipPosition=\"top\"\n appendTo=\"body\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"insert(field)\">{{ field }}</button>\n }\n }\n </div>\n @if (fits('entry', names)) {\n @for (list of source.lists | keyvalue; track list.key) {\n <details class=\"pw-available-fields__list\"\n [open]=\"!!query\">\n <summary>{{ 'Flows.Inspector.FieldsIn' | transloco: { list: list.key, count: list.value.length } }}</summary>\n <div class=\"pw-available-fields__chips\">\n @for (field of list.value; track field) {\n @if (matches(field)) {\n <button type=\"button\"\n class=\"pw-available-fields__chip\"\n [disabled]=\"readOnly\"\n [attr.data-testid]=\"'flow-available-field-' + entry(list.key, field)\"\n [pTooltip]=\"placeholder(entry(list.key, field), names)\"\n tooltipPosition=\"top\"\n appendTo=\"body\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"insert(entry(list.key, field))\">{{ field }}</button>\n }\n }\n </div>\n </details>\n }\n }\n </section>\n }\n }\n </div>\n </div>\n } @else {\n <p class=\"pw-available-fields__none\"\n data-testid=\"flow-available-fields-none\">{{ (firstRun ? 'Flows.Inspector.FirstRunFields' : 'Flows.Inspector.NoAvailableFields') | transloco }}</p>\n }\n</pw-input-container>\n",
|
|
5138
|
+
styles: [".pw-available-fields{display:flex;flex-direction:column;gap:10px}.pw-available-fields__search{max-width:100%}.pw-available-fields__groups{display:flex;flex-direction:column;gap:10px;max-height:220px;overflow-y:auto;padding-right:4px}.pw-available-fields__group+.pw-available-fields__group{border-top:1px solid #e2e5ea;padding-top:10px}.pw-available-fields__from{margin:0 0 6px;font-size:12px;font-weight:600;color:#1a1d21}.pw-available-fields__id{margin-left:4px;font-weight:400;color:#7c8696}.pw-available-fields__chips{display:flex;flex-wrap:wrap;gap:4px}.pw-available-fields__chip{border:1px solid #d5dae1;border-radius:4px;background-color:#f5f7fa;color:#1a1d21;padding:1px 8px;font-size:12px;line-height:20px;cursor:pointer}.pw-available-fields__chip:hover:not(:disabled){border-color:var(--first);background-color:#fff}.pw-available-fields__chip:disabled{cursor:not-allowed;opacity:.4}.pw-available-fields__list{margin-top:6px}.pw-available-fields__list summary{cursor:pointer;margin-bottom:4px;font-size:12px;color:#5a6473}.pw-available-fields__none{margin:0;color:#5a6473;font-size:12px}\n"]
|
|
4154
5139
|
}]
|
|
4155
5140
|
}],
|
|
4156
|
-
ctorParameters: () => [{ type:
|
|
5141
|
+
ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }],
|
|
4157
5142
|
propDecorators: {
|
|
4158
|
-
|
|
4159
|
-
multiple: [{ type: Input }],
|
|
4160
|
-
subscriptionId: [{ type: Input }],
|
|
5143
|
+
sources: [{ type: Input }],
|
|
4161
5144
|
inputId: [{ type: Input }],
|
|
4162
5145
|
readOnly: [{ type: Input }],
|
|
4163
|
-
|
|
5146
|
+
firstRun: [{ type: Input }],
|
|
5147
|
+
nodeType: [{ type: Input }],
|
|
5148
|
+
remember: [{
|
|
5149
|
+
type: HostListener,
|
|
5150
|
+
args: ["document:focusin", ["$event.target"]]
|
|
5151
|
+
}]
|
|
4164
5152
|
}
|
|
4165
5153
|
});
|
|
4166
|
-
function toIds(value) {
|
|
4167
|
-
return (Array.isArray(value) ? value : [value]).map(Number).filter((id) => Number.isInteger(id) && id > 0);
|
|
4168
|
-
}
|
|
4169
5154
|
var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
4170
5155
|
constructor(translation, cdr, destroyRef, host) {
|
|
4171
5156
|
this.host = host;
|
|
@@ -4173,6 +5158,8 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4173
5158
|
this.readOnly = false;
|
|
4174
5159
|
this.fieldSuggestions = [];
|
|
4175
5160
|
this.listSuggestions = [];
|
|
5161
|
+
this.fieldSources = [];
|
|
5162
|
+
this.firstRun = false;
|
|
4176
5163
|
this.nodeChange = new EventEmitter();
|
|
4177
5164
|
this.remove = new EventEmitter();
|
|
4178
5165
|
this.icons = FLOWS_ICONS;
|
|
@@ -4180,6 +5167,7 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4180
5167
|
this.defaultMergeMode = FLOW_MERGE_MODES[0];
|
|
4181
5168
|
this.labelKey = flowNodeLabelKey;
|
|
4182
5169
|
this.paramLabelKey = flowParamLabelKey;
|
|
5170
|
+
this.paramHelpKey = flowParamHelpKey;
|
|
4183
5171
|
this.numberValue = flowNumberValue;
|
|
4184
5172
|
this.fields = [];
|
|
4185
5173
|
this.conditionNotAnObject = false;
|
|
@@ -4229,6 +5217,9 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4229
5217
|
params
|
|
4230
5218
|
});
|
|
4231
5219
|
}
|
|
5220
|
+
setRetry(retry) {
|
|
5221
|
+
this.emit(flowNodeWithRetry(this.leaving ?? this.node, retry));
|
|
5222
|
+
}
|
|
4232
5223
|
setCondition(condition) {
|
|
4233
5224
|
const next = { ...this.leaving ?? this.node };
|
|
4234
5225
|
this.conditionNotAnObject = false;
|
|
@@ -4252,7 +5243,7 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4252
5243
|
ngImport: i0,
|
|
4253
5244
|
type: FlowsNodeInspectorComponent,
|
|
4254
5245
|
deps: [
|
|
4255
|
-
{ token:
|
|
5246
|
+
{ token: i2$4.TranslocoService },
|
|
4256
5247
|
{ token: i0.ChangeDetectorRef },
|
|
4257
5248
|
{ token: i0.DestroyRef },
|
|
4258
5249
|
{ token: i0.ElementRef }
|
|
@@ -4273,7 +5264,9 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4273
5264
|
subscriptionId: "subscriptionId",
|
|
4274
5265
|
readOnly: "readOnly",
|
|
4275
5266
|
fieldSuggestions: "fieldSuggestions",
|
|
4276
|
-
listSuggestions: "listSuggestions"
|
|
5267
|
+
listSuggestions: "listSuggestions",
|
|
5268
|
+
fieldSources: "fieldSources",
|
|
5269
|
+
firstRun: "firstRun"
|
|
4277
5270
|
},
|
|
4278
5271
|
outputs: {
|
|
4279
5272
|
nodeChange: "nodeChange",
|
|
@@ -4281,8 +5274,8 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4281
5274
|
},
|
|
4282
5275
|
usesOnChanges: true,
|
|
4283
5276
|
ngImport: i0,
|
|
4284
|
-
template: "<aside class=\"pw-node-inspector\"\n data-testid=\"flow-inspector\">\n @let key = labelKey(node.type);\n @let translated = key | transloco;\n <header class=\"pw-node-inspector__head\">\n <div>\n <h4 class=\"pw-node-inspector__title\">{{ translated === key ? (definition?.label ?? node.type) : translated }}</h4>\n <span class=\"pw-node-inspector__id\">{{ node.id }} · {{ node.type }}</span>\n </div>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-link pw-node-inspector__remove\"\n data-testid=\"flow-node-remove\"\n [attr.aria-label]=\"'Flows.Inspector.RemoveNode' | transloco\"\n [pTooltip]=\"'Flows.Inspector.RemoveNode' | transloco\"\n appendTo=\"body\"\n (click)=\"remove.emit()\">\n <fa-icon [icon]=\"icons.delete\"></fa-icon>\n </button>\n }\n </header>\n\n @if (!definition) {\n <p class=\"pw-node-inspector__note\"\n data-testid=\"flow-node-unknown\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Inspector.UnknownType' | transloco }}\n </p>\n }\n\n @for (field of fields; track field.id) {\n @let id = field.id;\n @let paramKey = paramLabelKey(field.key);\n @let paramLabel = paramKey | transloco;\n <pw-input-container class=\"pw-node-inspector__field\"\n [label]=\"field.label || (paramLabel === paramKey ? field.key : paramLabel)\"\n [required]=\"!!field.required\"\n [name]=\"field.key\"\n [controlId]=\"id\">\n @switch (kindOf(field)) {\n @case ('textarea') {\n <textarea class=\"form-control\"\n rows=\"4\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></textarea>\n }\n @case ('cron') {\n <pw-flows-cron-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-cron-field>\n }\n @case ('timezone') {\n <pw-flows-timezone-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-timezone-field>\n }\n @case ('pairs') {\n <pw-flows-pairs-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-pairs-field>\n }\n @case ('json') {\n <pw-flows-json-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-json-field>\n }\n @case ('member') {\n <pw-flows-member-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('members') {\n <pw-flows-member-field [inputId]=\"id\"\n [multiple]=\"true\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('mode') {\n <p-select [inputId]=\"id\"\n [options]=\"mergeModes\"\n optionLabel=\"label\"\n optionValue=\"value\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key) ?? defaultMergeMode\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></p-select>\n }\n @case ('list') {\n <p-select [inputId]=\"id\"\n [options]=\"listSuggestions\"\n [editable]=\"true\"\n [placeholder]=\"'Flows.Inspector.SelectList' | transloco\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('select') {\n <p-select [inputId]=\"id\"\n [options]=\"field.options ?? []\"\n [placeholder]=\"field.placeholder ?? ''\"\n [showClear]=\"!field.required\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('number') {\n <input class=\"form-control\"\n type=\"text\"\n inputmode=\"decimal\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, numberValue($event))\" />\n }\n @default {\n <input class=\"form-control\"\n [
|
|
4285
|
-
styles: [".pw-node-inspector{display:flex;flex-direction:column;gap:16px;padding:16px}.pw-node-inspector__head{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;padding-bottom:12px;border-bottom:1px solid #e2e5ea}.pw-node-inspector__title{margin:0}.pw-node-inspector__id{color:#7c8696;font-size:12px;font-variant-numeric:tabular-nums}.pw-node-inspector__remove{color:#5a6473}.pw-node-inspector__field{display:block}.pw-node-inspector__note
|
|
5277
|
+
template: "<aside class=\"pw-node-inspector\"\n data-testid=\"flow-inspector\">\n @let key = labelKey(node.type);\n @let translated = key | transloco;\n <header class=\"pw-node-inspector__head\">\n <div>\n <h4 class=\"pw-node-inspector__title\">{{ translated === key ? (definition?.label ?? node.type) : translated }}</h4>\n <span class=\"pw-node-inspector__id\">{{ node.id }} · {{ node.type }}</span>\n </div>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-link pw-node-inspector__remove\"\n data-testid=\"flow-node-remove\"\n [attr.aria-label]=\"'Flows.Inspector.RemoveNode' | transloco\"\n [pTooltip]=\"'Flows.Inspector.RemoveNode' | transloco\"\n appendTo=\"body\"\n (click)=\"remove.emit()\">\n <fa-icon [icon]=\"icons.delete\"></fa-icon>\n </button>\n }\n </header>\n\n @if (!definition) {\n <p class=\"pw-node-inspector__note\"\n data-testid=\"flow-node-unknown\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Inspector.UnknownType' | transloco }}\n </p>\n }\n\n @if (definition && definition.category !== 'trigger' && fieldSources) {\n <pw-flows-available-fields class=\"pw-node-inspector__field\"\n data-testid=\"flow-available-fields\"\n [inputId]=\"fieldId('available-fields')\"\n [sources]=\"fieldSources\" [firstRun]=\"firstRun\" [nodeType]=\"node.type\"\n [readOnly]=\"readOnly\"></pw-flows-available-fields>\n }\n\n @for (field of fields; track field.id) {\n @let id = field.id;\n @let paramKey = paramLabelKey(field.key);\n @let paramLabel = paramKey | transloco;\n @let helpKey = paramHelpKey(node.type, field.key);\n @let helpText = helpKey | transloco;\n @let help = field.description || (helpText === helpKey ? '' : helpText);\n <pw-input-container class=\"pw-node-inspector__field\"\n [label]=\"field.label || (paramLabel === paramKey ? field.key : paramLabel)\"\n [required]=\"!!field.required\"\n [name]=\"field.key\"\n [controlId]=\"id\"\n [showTooltip]=\"!!help\"\n [tooltipText]=\"help\">\n @switch (kindOf(field)) {\n @case ('textarea') {\n <textarea class=\"form-control\"\n rows=\"4\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></textarea>\n }\n @case ('cron') {\n <pw-flows-cron-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-cron-field>\n }\n @case ('timezone') {\n <pw-flows-timezone-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-timezone-field>\n }\n @case ('pairs') {\n <pw-flows-pairs-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-pairs-field>\n }\n @case ('json') {\n <pw-flows-json-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-json-field>\n }\n @case ('member') {\n <pw-flows-member-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('members') {\n <pw-flows-member-field [inputId]=\"id\"\n [multiple]=\"true\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('mode') {\n <p-select [inputId]=\"id\"\n [options]=\"mergeModes\"\n optionLabel=\"label\"\n optionValue=\"value\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key) ?? defaultMergeMode\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></p-select>\n }\n @case ('list') {\n <p-select [inputId]=\"id\"\n [options]=\"listSuggestions\"\n [editable]=\"true\"\n [placeholder]=\"'Flows.Inspector.SelectList' | transloco\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('select') {\n <p-select [inputId]=\"id\"\n [options]=\"field.options ?? []\"\n [placeholder]=\"field.placeholder ?? ''\"\n [showClear]=\"!field.required\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('number') {\n <input class=\"form-control\"\n type=\"text\"\n inputmode=\"decimal\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, numberValue($event))\" />\n }\n @default {\n <input class=\"form-control\" type=\"text\" autocomplete=\"off\"\n [attr.inputmode]=\"field.kind === 'email' ? 'email' : null\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, $event)\" />\n }\n }\n </pw-input-container>\n }\n\n @if (definition?.condition) {\n @let conditionKey = paramHelpKey(node.type, 'condition');\n @let conditionText = conditionKey | transloco;\n @let conditionHelp = conditionText === conditionKey ? '' : conditionText;\n <pw-input-container class=\"pw-node-inspector__field\"\n [label]=\"'Flows.Inspector.Condition' | transloco\"\n name=\"condition\"\n [controlId]=\"fieldId('condition')\"\n [showTooltip]=\"!!conditionHelp\"\n [tooltipText]=\"conditionHelp\">\n <pw-flows-condition-field [inputId]=\"fieldId('condition')\"\n [value]=\"node.condition\"\n [suggestions]=\"fieldSuggestions\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setCondition($event)\"></pw-flows-condition-field>\n @if (conditionNotAnObject) {\n <pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Inspector.ConditionNotAnObject' | transloco\">\n </pw-field-error-display>\n }\n </pw-input-container>\n }\n\n @if (definition?.category === 'action') {\n <div class=\"pw-node-inspector__field\"\n data-testid=\"flow-node-retry\">\n <pw-flows-retry-field [inputId]=\"fieldId('retry')\"\n [value]=\"node.retry\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setRetry($event)\"></pw-flows-retry-field>\n </div>\n }\n\n @if (definition && !fields.length && !definition.condition) {\n <p class=\"pw-node-inspector__note\">{{ 'Flows.Inspector.NoSettings' | transloco }}</p>\n }\n</aside>\n",
|
|
5278
|
+
styles: [".pw-node-inspector ::ng-deep .info-circle{display:inline-block;margin-left:.35em;vertical-align:baseline}.pw-node-inspector ::ng-deep .info-circle:after{position:static;font-size:inherit;line-height:inherit}.pw-node-inspector{display:flex;flex-direction:column;gap:16px;padding:16px}.pw-node-inspector__head{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;padding-bottom:12px;border-bottom:1px solid #e2e5ea}.pw-node-inspector__title{margin:0}.pw-node-inspector__id{color:#7c8696;font-size:12px;font-variant-numeric:tabular-nums}.pw-node-inspector__remove{color:#5a6473}.pw-node-inspector__field{display:block}.pw-node-inspector__note{margin:0;color:#5a6473;font-size:12px}\n"],
|
|
4286
5279
|
dependencies: [
|
|
4287
5280
|
{
|
|
4288
5281
|
kind: "directive",
|
|
@@ -4309,7 +5302,7 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4309
5302
|
},
|
|
4310
5303
|
{
|
|
4311
5304
|
kind: "directive",
|
|
4312
|
-
type:
|
|
5305
|
+
type: i1$1.Tooltip,
|
|
4313
5306
|
selector: "[pTooltip]",
|
|
4314
5307
|
inputs: [
|
|
4315
5308
|
"tooltipPosition",
|
|
@@ -4407,13 +5400,13 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4407
5400
|
},
|
|
4408
5401
|
{
|
|
4409
5402
|
kind: "component",
|
|
4410
|
-
type: i2.FieldErrorDisplayComponent,
|
|
5403
|
+
type: i2$1.FieldErrorDisplayComponent,
|
|
4411
5404
|
selector: "pw-field-error-display",
|
|
4412
5405
|
inputs: ["errorMsg", "displayError"]
|
|
4413
5406
|
},
|
|
4414
5407
|
{
|
|
4415
5408
|
kind: "component",
|
|
4416
|
-
type:
|
|
5409
|
+
type: i6.InputContainerComponent,
|
|
4417
5410
|
selector: "pw-input-container",
|
|
4418
5411
|
inputs: [
|
|
4419
5412
|
"name",
|
|
@@ -4436,7 +5429,7 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4436
5429
|
},
|
|
4437
5430
|
{
|
|
4438
5431
|
kind: "component",
|
|
4439
|
-
type:
|
|
5432
|
+
type: i2$3.FaIconComponent,
|
|
4440
5433
|
selector: "fa-icon",
|
|
4441
5434
|
inputs: [
|
|
4442
5435
|
"icon",
|
|
@@ -4540,9 +5533,32 @@ var FlowsNodeInspectorComponent = class FlowsNodeInspectorComponent {
|
|
|
4540
5533
|
],
|
|
4541
5534
|
outputs: ["valueChange"]
|
|
4542
5535
|
},
|
|
5536
|
+
{
|
|
5537
|
+
kind: "component",
|
|
5538
|
+
type: FlowsRetryFieldComponent,
|
|
5539
|
+
selector: "pw-flows-retry-field",
|
|
5540
|
+
inputs: [
|
|
5541
|
+
"value",
|
|
5542
|
+
"inputId",
|
|
5543
|
+
"readOnly"
|
|
5544
|
+
],
|
|
5545
|
+
outputs: ["valueChange"]
|
|
5546
|
+
},
|
|
5547
|
+
{
|
|
5548
|
+
kind: "component",
|
|
5549
|
+
type: FlowsAvailableFieldsComponent,
|
|
5550
|
+
selector: "pw-flows-available-fields",
|
|
5551
|
+
inputs: [
|
|
5552
|
+
"sources",
|
|
5553
|
+
"inputId",
|
|
5554
|
+
"readOnly",
|
|
5555
|
+
"firstRun",
|
|
5556
|
+
"nodeType"
|
|
5557
|
+
]
|
|
5558
|
+
},
|
|
4543
5559
|
{
|
|
4544
5560
|
kind: "pipe",
|
|
4545
|
-
type:
|
|
5561
|
+
type: i2$4.TranslocoPipe,
|
|
4546
5562
|
name: "transloco"
|
|
4547
5563
|
}
|
|
4548
5564
|
]
|
|
@@ -4559,12 +5575,12 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4559
5575
|
args: [{
|
|
4560
5576
|
selector: "pw-flows-node-inspector",
|
|
4561
5577
|
standalone: false,
|
|
4562
|
-
template: "<aside class=\"pw-node-inspector\"\n data-testid=\"flow-inspector\">\n @let key = labelKey(node.type);\n @let translated = key | transloco;\n <header class=\"pw-node-inspector__head\">\n <div>\n <h4 class=\"pw-node-inspector__title\">{{ translated === key ? (definition?.label ?? node.type) : translated }}</h4>\n <span class=\"pw-node-inspector__id\">{{ node.id }} · {{ node.type }}</span>\n </div>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-link pw-node-inspector__remove\"\n data-testid=\"flow-node-remove\"\n [attr.aria-label]=\"'Flows.Inspector.RemoveNode' | transloco\"\n [pTooltip]=\"'Flows.Inspector.RemoveNode' | transloco\"\n appendTo=\"body\"\n (click)=\"remove.emit()\">\n <fa-icon [icon]=\"icons.delete\"></fa-icon>\n </button>\n }\n </header>\n\n @if (!definition) {\n <p class=\"pw-node-inspector__note\"\n data-testid=\"flow-node-unknown\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Inspector.UnknownType' | transloco }}\n </p>\n }\n\n @for (field of fields; track field.id) {\n @let id = field.id;\n @let paramKey = paramLabelKey(field.key);\n @let paramLabel = paramKey | transloco;\n <pw-input-container class=\"pw-node-inspector__field\"\n [label]=\"field.label || (paramLabel === paramKey ? field.key : paramLabel)\"\n [required]=\"!!field.required\"\n [name]=\"field.key\"\n [controlId]=\"id\">\n @switch (kindOf(field)) {\n @case ('textarea') {\n <textarea class=\"form-control\"\n rows=\"4\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></textarea>\n }\n @case ('cron') {\n <pw-flows-cron-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-cron-field>\n }\n @case ('timezone') {\n <pw-flows-timezone-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-timezone-field>\n }\n @case ('pairs') {\n <pw-flows-pairs-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-pairs-field>\n }\n @case ('json') {\n <pw-flows-json-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-json-field>\n }\n @case ('member') {\n <pw-flows-member-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('members') {\n <pw-flows-member-field [inputId]=\"id\"\n [multiple]=\"true\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('mode') {\n <p-select [inputId]=\"id\"\n [options]=\"mergeModes\"\n optionLabel=\"label\"\n optionValue=\"value\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key) ?? defaultMergeMode\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></p-select>\n }\n @case ('list') {\n <p-select [inputId]=\"id\"\n [options]=\"listSuggestions\"\n [editable]=\"true\"\n [placeholder]=\"'Flows.Inspector.SelectList' | transloco\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('select') {\n <p-select [inputId]=\"id\"\n [options]=\"field.options ?? []\"\n [placeholder]=\"field.placeholder ?? ''\"\n [showClear]=\"!field.required\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('number') {\n <input class=\"form-control\"\n type=\"text\"\n inputmode=\"decimal\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, numberValue($event))\" />\n }\n @default {\n <input class=\"form-control\"\n [
|
|
4563
|
-
styles: [".pw-node-inspector{display:flex;flex-direction:column;gap:16px;padding:16px}.pw-node-inspector__head{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;padding-bottom:12px;border-bottom:1px solid #e2e5ea}.pw-node-inspector__title{margin:0}.pw-node-inspector__id{color:#7c8696;font-size:12px;font-variant-numeric:tabular-nums}.pw-node-inspector__remove{color:#5a6473}.pw-node-inspector__field{display:block}.pw-node-inspector__note
|
|
5578
|
+
template: "<aside class=\"pw-node-inspector\"\n data-testid=\"flow-inspector\">\n @let key = labelKey(node.type);\n @let translated = key | transloco;\n <header class=\"pw-node-inspector__head\">\n <div>\n <h4 class=\"pw-node-inspector__title\">{{ translated === key ? (definition?.label ?? node.type) : translated }}</h4>\n <span class=\"pw-node-inspector__id\">{{ node.id }} · {{ node.type }}</span>\n </div>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-link pw-node-inspector__remove\"\n data-testid=\"flow-node-remove\"\n [attr.aria-label]=\"'Flows.Inspector.RemoveNode' | transloco\"\n [pTooltip]=\"'Flows.Inspector.RemoveNode' | transloco\"\n appendTo=\"body\"\n (click)=\"remove.emit()\">\n <fa-icon [icon]=\"icons.delete\"></fa-icon>\n </button>\n }\n </header>\n\n @if (!definition) {\n <p class=\"pw-node-inspector__note\"\n data-testid=\"flow-node-unknown\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Inspector.UnknownType' | transloco }}\n </p>\n }\n\n @if (definition && definition.category !== 'trigger' && fieldSources) {\n <pw-flows-available-fields class=\"pw-node-inspector__field\"\n data-testid=\"flow-available-fields\"\n [inputId]=\"fieldId('available-fields')\"\n [sources]=\"fieldSources\" [firstRun]=\"firstRun\" [nodeType]=\"node.type\"\n [readOnly]=\"readOnly\"></pw-flows-available-fields>\n }\n\n @for (field of fields; track field.id) {\n @let id = field.id;\n @let paramKey = paramLabelKey(field.key);\n @let paramLabel = paramKey | transloco;\n @let helpKey = paramHelpKey(node.type, field.key);\n @let helpText = helpKey | transloco;\n @let help = field.description || (helpText === helpKey ? '' : helpText);\n <pw-input-container class=\"pw-node-inspector__field\"\n [label]=\"field.label || (paramLabel === paramKey ? field.key : paramLabel)\"\n [required]=\"!!field.required\"\n [name]=\"field.key\"\n [controlId]=\"id\"\n [showTooltip]=\"!!help\"\n [tooltipText]=\"help\">\n @switch (kindOf(field)) {\n @case ('textarea') {\n <textarea class=\"form-control\"\n rows=\"4\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></textarea>\n }\n @case ('cron') {\n <pw-flows-cron-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-cron-field>\n }\n @case ('timezone') {\n <pw-flows-timezone-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-timezone-field>\n }\n @case ('pairs') {\n <pw-flows-pairs-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-pairs-field>\n }\n @case ('json') {\n <pw-flows-json-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-json-field>\n }\n @case ('member') {\n <pw-flows-member-field [inputId]=\"id\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('members') {\n <pw-flows-member-field [inputId]=\"id\"\n [multiple]=\"true\"\n [value]=\"param(field.key)\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setParam(field.key, $event)\"></pw-flows-member-field>\n }\n @case ('mode') {\n <p-select [inputId]=\"id\"\n [options]=\"mergeModes\"\n optionLabel=\"label\"\n optionValue=\"value\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key) ?? defaultMergeMode\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event)\"></p-select>\n }\n @case ('list') {\n <p-select [inputId]=\"id\"\n [options]=\"listSuggestions\"\n [editable]=\"true\"\n [placeholder]=\"'Flows.Inspector.SelectList' | transloco\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('select') {\n <p-select [inputId]=\"id\"\n [options]=\"field.options ?? []\"\n [placeholder]=\"field.placeholder ?? ''\"\n [showClear]=\"!field.required\"\n appendTo=\"body\"\n styleClass=\"w-100\"\n [disabled]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setParam(field.key, $event ?? undefined)\"></p-select>\n }\n @case ('number') {\n <input class=\"form-control\"\n type=\"text\"\n inputmode=\"decimal\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, numberValue($event))\" />\n }\n @default {\n <input class=\"form-control\" type=\"text\" autocomplete=\"off\"\n [attr.inputmode]=\"field.kind === 'email' ? 'email' : null\"\n [id]=\"id\"\n [placeholder]=\"field.placeholder ?? ''\"\n [readOnly]=\"readOnly\"\n [ngModel]=\"param(field.key)\"\n [ngModelOptions]=\"{ standalone: true, updateOn: 'blur' }\"\n (ngModelChange)=\"setParam(field.key, $event)\" />\n }\n }\n </pw-input-container>\n }\n\n @if (definition?.condition) {\n @let conditionKey = paramHelpKey(node.type, 'condition');\n @let conditionText = conditionKey | transloco;\n @let conditionHelp = conditionText === conditionKey ? '' : conditionText;\n <pw-input-container class=\"pw-node-inspector__field\"\n [label]=\"'Flows.Inspector.Condition' | transloco\"\n name=\"condition\"\n [controlId]=\"fieldId('condition')\"\n [showTooltip]=\"!!conditionHelp\"\n [tooltipText]=\"conditionHelp\">\n <pw-flows-condition-field [inputId]=\"fieldId('condition')\"\n [value]=\"node.condition\"\n [suggestions]=\"fieldSuggestions\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setCondition($event)\"></pw-flows-condition-field>\n @if (conditionNotAnObject) {\n <pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Inspector.ConditionNotAnObject' | transloco\">\n </pw-field-error-display>\n }\n </pw-input-container>\n }\n\n @if (definition?.category === 'action') {\n <div class=\"pw-node-inspector__field\"\n data-testid=\"flow-node-retry\">\n <pw-flows-retry-field [inputId]=\"fieldId('retry')\"\n [value]=\"node.retry\"\n [readOnly]=\"readOnly\"\n (valueChange)=\"setRetry($event)\"></pw-flows-retry-field>\n </div>\n }\n\n @if (definition && !fields.length && !definition.condition) {\n <p class=\"pw-node-inspector__note\">{{ 'Flows.Inspector.NoSettings' | transloco }}</p>\n }\n</aside>\n",
|
|
5579
|
+
styles: [".pw-node-inspector ::ng-deep .info-circle{display:inline-block;margin-left:.35em;vertical-align:baseline}.pw-node-inspector ::ng-deep .info-circle:after{position:static;font-size:inherit;line-height:inherit}.pw-node-inspector{display:flex;flex-direction:column;gap:16px;padding:16px}.pw-node-inspector__head{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;padding-bottom:12px;border-bottom:1px solid #e2e5ea}.pw-node-inspector__title{margin:0}.pw-node-inspector__id{color:#7c8696;font-size:12px;font-variant-numeric:tabular-nums}.pw-node-inspector__remove{color:#5a6473}.pw-node-inspector__field{display:block}.pw-node-inspector__note{margin:0;color:#5a6473;font-size:12px}\n"]
|
|
4564
5580
|
}]
|
|
4565
5581
|
}],
|
|
4566
5582
|
ctorParameters: () => [
|
|
4567
|
-
{ type:
|
|
5583
|
+
{ type: i2$4.TranslocoService },
|
|
4568
5584
|
{ type: i0.ChangeDetectorRef },
|
|
4569
5585
|
{ type: i0.DestroyRef },
|
|
4570
5586
|
{ type: i0.ElementRef }
|
|
@@ -4576,18 +5592,22 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4576
5592
|
readOnly: [{ type: Input }],
|
|
4577
5593
|
fieldSuggestions: [{ type: Input }],
|
|
4578
5594
|
listSuggestions: [{ type: Input }],
|
|
5595
|
+
fieldSources: [{ type: Input }],
|
|
5596
|
+
firstRun: [{ type: Input }],
|
|
4579
5597
|
nodeChange: [{ type: Output }],
|
|
4580
5598
|
remove: [{ type: Output }]
|
|
4581
5599
|
}
|
|
4582
5600
|
});
|
|
4583
5601
|
var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
4584
|
-
constructor(workflowService, nodeService, cdr) {
|
|
5602
|
+
constructor(workflowService, nodeService, runService, cdr) {
|
|
4585
5603
|
this.workflowService = workflowService;
|
|
4586
5604
|
this.nodeService = nodeService;
|
|
5605
|
+
this.runService = runService;
|
|
4587
5606
|
this.cdr = cdr;
|
|
4588
5607
|
this.destroy$ = new Subject();
|
|
4589
5608
|
this.version = null;
|
|
4590
5609
|
this.duplicateOf = null;
|
|
5610
|
+
this.check = null;
|
|
4591
5611
|
this.saved = new EventEmitter();
|
|
4592
5612
|
this.cancelled = new EventEmitter();
|
|
4593
5613
|
this.icons = FLOWS_ICONS;
|
|
@@ -4608,6 +5628,7 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4608
5628
|
return flowVersionEditorTitleKey(this.version, this.duplicateOf);
|
|
4609
5629
|
}
|
|
4610
5630
|
ngOnInit() {
|
|
5631
|
+
this.workflowFields$ = this.runService.getWorkflowFields(this.workflowId, this.subscriptionId).pipe(shareReplay(1));
|
|
4611
5632
|
this.nodeService.getNodes(this.subscriptionId).pipe(finalize(() => {
|
|
4612
5633
|
this.loading = false;
|
|
4613
5634
|
this.cdr.markForCheck();
|
|
@@ -4670,6 +5691,7 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4670
5691
|
deps: [
|
|
4671
5692
|
{ token: FlowsWorkflowService },
|
|
4672
5693
|
{ token: FlowsNodeService },
|
|
5694
|
+
{ token: FlowsRunService },
|
|
4673
5695
|
{ token: i0.ChangeDetectorRef }
|
|
4674
5696
|
],
|
|
4675
5697
|
target: i0.ɵɵFactoryTarget.Component
|
|
@@ -4686,7 +5708,8 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4686
5708
|
version: "version",
|
|
4687
5709
|
duplicateOf: "duplicateOf",
|
|
4688
5710
|
workflowId: "workflowId",
|
|
4689
|
-
subscriptionId: "subscriptionId"
|
|
5711
|
+
subscriptionId: "subscriptionId",
|
|
5712
|
+
check: "check"
|
|
4690
5713
|
},
|
|
4691
5714
|
outputs: {
|
|
4692
5715
|
saved: "saved",
|
|
@@ -4700,12 +5723,12 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4700
5723
|
}],
|
|
4701
5724
|
usesOnChanges: true,
|
|
4702
5725
|
ngImport: i0,
|
|
4703
|
-
template: "<div class=\"pw-version-editor mt-3\">\n <h3>{{ headingKey | transloco: { number: duplicateOf?.version } }}</h3>\n\n <pw-loader [isVisible]=\"loading\"></pw-loader>\n\n @if (!loading) {\n @if (loadFailed) {\n <pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Canvas.LoadFailed' | transloco\">\n </pw-field-error-display>\n } @else {\n <div class=\"pw-version-editor__toolbar\">\n <div class=\"btn-group\"\n role=\"tablist\">\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-canvas\"\n [class.active]=\"view === 'canvas'\"\n [attr.aria-selected]=\"view === 'canvas'\"\n (click)=\"show('canvas')\">\n <fa-icon [icon]=\"icons.diagram\"></fa-icon>\n {{ 'Flows.Canvas.Diagram' | transloco }}\n </button>\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-json\"\n [class.active]=\"view === 'json'\"\n [attr.aria-selected]=\"view === 'json'\"\n (click)=\"show('json')\">\n <fa-icon [icon]=\"icons.json\"></fa-icon>\n {{ 'Flows.Canvas.Json' | transloco }}\n </button>\n </div>\n @if (view === 'canvas') {\n <button type=\"button\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-fit\"\n (click)=\"canvas.zoomToFit()\">\n <fa-icon [icon]=\"icons.fit\"></fa-icon>\n {{ 'Flows.Canvas.Fit' | transloco }}\n </button>\n }\n </div>\n\n @if (dropped.length) {\n <p class=\"pw-version-editor__warning\"\n role=\"alert\"\n data-testid=\"flow-dropped-edges\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Canvas.Dropped' | transloco: { count: dropped.length } }}\n </p>\n }\n\n <div class=\"pw-version-editor__workspace\"\n [class.is-read-only]=\"readOnly\"\n [hidden]=\"view !== 'canvas'\">\n @if (!readOnly) {\n <pw-flows-node-palette class=\"pw-version-editor__palette\"\n [definitions]=\"definitions\"\n (add)=\"canvas.addNode($event)\"></pw-flows-node-palette>\n }\n <pw-flows-graph-canvas #canvas\n class=\"pw-version-editor__canvas\"\n [graph]=\"graph\"\n [definitions]=\"definitions\"\n [readOnly]=\"readOnly\"\n (selectionChange)=\"select($event)\"\n (dropped)=\"dropped = $event\"></pw-flows-graph-canvas>\n <div class=\"pw-version-editor__side\">\n @if (selection) {\n <pw-flows-node-inspector [node]=\"selection.node\"\n [definition]=\"selection.definition\"\n [fieldSuggestions]=\"selection.fieldSuggestions\"\n [listSuggestions]=\"selection.listSuggestions\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (nodeChange)=\"updateSelected($event)\"\n (remove)=\"removeSelected()\"></pw-flows-node-inspector>\n } @else {\n <p class=\"pw-version-editor__hint\">{{ (readOnly ? 'Flows.Canvas.SelectToView' : 'Flows.Canvas.SelectToEdit') | transloco }}</p>\n }\n </div>\n </div>\n\n @if (view === 'json') {\n <pre class=\"pw-version-editor__json\"\n data-testid=\"flow-json\">{{ json }}</pre>\n }\n }\n }\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"cancel()\">\n {{ (readOnly ? 'Flows.Versions.Editor.Close' : 'Button.Cancel') | transloco }}\n </button>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"saving || loading || loadFailed\"\n (click)=\"save()\">\n {{ 'Button.Submit' | transloco }}\n </button>\n }\n </div>\n</div>\n",
|
|
4704
|
-
styles: [":host .pw-version-editor>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}.pw-version-editor__toolbar{display:flex;align-items:center;
|
|
5726
|
+
template: "<div class=\"pw-version-editor mt-3\">\n <h3>{{ headingKey | transloco: { number: duplicateOf?.version } }}</h3>\n\n <pw-loader [isVisible]=\"loading\"></pw-loader>\n\n @if (!loading) {\n @if (loadFailed) {\n <pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Canvas.LoadFailed' | transloco\">\n </pw-field-error-display>\n } @else {\n <div class=\"pw-version-editor__toolbar\">\n <div class=\"btn-group me-auto\"\n role=\"tablist\">\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-canvas\"\n [class.active]=\"view === 'canvas'\"\n [attr.aria-selected]=\"view === 'canvas'\"\n (click)=\"show('canvas')\">\n <fa-icon [icon]=\"icons.diagram\"></fa-icon>\n {{ 'Flows.Canvas.Diagram' | transloco }}\n </button>\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-json\"\n [class.active]=\"view === 'json'\"\n [attr.aria-selected]=\"view === 'json'\"\n (click)=\"show('json')\">\n <fa-icon [icon]=\"icons.json\"></fa-icon>\n {{ 'Flows.Canvas.Json' | transloco }}\n </button>\n </div>\n @if (view === 'canvas') {\n <button type=\"button\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-fit\"\n (click)=\"canvas.zoomToFit()\">\n <fa-icon [icon]=\"icons.fit\"></fa-icon>\n {{ 'Flows.Canvas.Fit' | transloco }}\n </button>\n }\n </div>\n\n @if (check && !readOnly) {\n <pw-flows-graph-check [canvas]=\"canvas\"\n [definitions]=\"definitions\"\n [graph]=\"graph\"\n [result]=\"check\"></pw-flows-graph-check>\n }\n\n @if (dropped.length) {\n <p class=\"pw-version-editor__warning\"\n role=\"alert\"\n data-testid=\"flow-dropped-edges\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Canvas.Dropped' | transloco: { count: dropped.length } }}\n </p>\n }\n\n @let fields = workflowFields$ | async;\n <div class=\"pw-version-editor__workspace\"\n [class.is-read-only]=\"readOnly\"\n [hidden]=\"view !== 'canvas'\">\n @if (!readOnly) {\n <pw-flows-node-palette class=\"pw-version-editor__palette\"\n [definitions]=\"definitions\"\n (add)=\"canvas.addNode($event)\"></pw-flows-node-palette>\n }\n <pw-flows-graph-canvas #canvas\n class=\"pw-version-editor__canvas\"\n [graph]=\"graph\"\n [definitions]=\"definitions\"\n [workflowFields]=\"fields\"\n [readOnly]=\"readOnly\"\n (selectionChange)=\"select($event)\"\n (dropped)=\"dropped = $event\"></pw-flows-graph-canvas>\n <div class=\"pw-version-editor__side\">\n @if (selection) {\n <pw-flows-node-inspector [node]=\"selection.node\"\n [definition]=\"selection.definition\"\n [fieldSuggestions]=\"selection.fieldSuggestions\"\n [fieldSources]=\"selection.fieldSources\"\n [listSuggestions]=\"selection.listSuggestions\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n [firstRun]=\"!!fields && !fields.ran\"\n (nodeChange)=\"updateSelected($event)\"\n (remove)=\"removeSelected()\"></pw-flows-node-inspector>\n } @else {\n <p class=\"pw-version-editor__hint\">{{ (readOnly ? 'Flows.Canvas.SelectToView' : 'Flows.Canvas.SelectToEdit') | transloco }}</p>\n }\n </div>\n </div>\n\n @if (view === 'json') {\n <pre class=\"pw-version-editor__json\"\n data-testid=\"flow-json\">{{ json }}</pre>\n }\n }\n }\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"cancel()\">\n {{ (readOnly ? 'Flows.Versions.Editor.Close' : 'Button.Cancel') | transloco }}\n </button>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"saving || loading || loadFailed\"\n (click)=\"save()\">\n {{ 'Button.Submit' | transloco }}\n </button>\n }\n </div>\n</div>\n",
|
|
5727
|
+
styles: [":host .pw-version-editor>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}.pw-version-editor__toolbar{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin-bottom:8px}.pw-version-editor__warning{display:flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid #b7791f;border-radius:4px;color:#b7791f}.pw-version-editor__workspace{display:grid;grid-template-columns:200px minmax(0,1fr) 300px;height:560px;border:1px solid #e2e5ea;border-radius:8px;overflow:hidden}.pw-version-editor__workspace.is-read-only{grid-template-columns:minmax(0,1fr) 300px}.pw-version-editor__palette,.pw-version-editor__side{overflow-y:auto;background:#fff}.pw-version-editor__palette{border-right:1px solid #e2e5ea}.pw-version-editor__side{border-left:1px solid #e2e5ea}.pw-version-editor__hint{margin:0;padding:16px;color:#7c8696}.pw-version-editor__json{max-height:560px;margin:0;padding:12px;overflow:auto;border:1px solid #e2e5ea;border-radius:8px;background:#f7f8fa}@media(max-width:991px){.pw-version-editor__workspace{grid-template-columns:minmax(0,1fr);grid-template-rows:auto 420px auto;height:auto}.pw-version-editor__workspace.is-read-only{grid-template-columns:minmax(0,1fr);grid-template-rows:420px auto}.pw-version-editor__palette{max-height:200px;border-right:0;border-bottom:1px solid #e2e5ea}.pw-version-editor__side{border-left:0;border-top:1px solid #e2e5ea}}\n"],
|
|
4705
5728
|
dependencies: [
|
|
4706
5729
|
{
|
|
4707
5730
|
kind: "component",
|
|
4708
|
-
type:
|
|
5731
|
+
type: i4$1.AppLoaderComponent,
|
|
4709
5732
|
selector: "pw-loader",
|
|
4710
5733
|
inputs: [
|
|
4711
5734
|
"isVisible",
|
|
@@ -4715,13 +5738,13 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4715
5738
|
},
|
|
4716
5739
|
{
|
|
4717
5740
|
kind: "component",
|
|
4718
|
-
type: i2.FieldErrorDisplayComponent,
|
|
5741
|
+
type: i2$1.FieldErrorDisplayComponent,
|
|
4719
5742
|
selector: "pw-field-error-display",
|
|
4720
5743
|
inputs: ["errorMsg", "displayError"]
|
|
4721
5744
|
},
|
|
4722
5745
|
{
|
|
4723
5746
|
kind: "component",
|
|
4724
|
-
type:
|
|
5747
|
+
type: i2$3.FaIconComponent,
|
|
4725
5748
|
selector: "fa-icon",
|
|
4726
5749
|
inputs: [
|
|
4727
5750
|
"icon",
|
|
@@ -4756,6 +5779,17 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4756
5779
|
"a11yRoleChange"
|
|
4757
5780
|
]
|
|
4758
5781
|
},
|
|
5782
|
+
{
|
|
5783
|
+
kind: "component",
|
|
5784
|
+
type: FlowsGraphCheckComponent,
|
|
5785
|
+
selector: "pw-flows-graph-check",
|
|
5786
|
+
inputs: [
|
|
5787
|
+
"canvas",
|
|
5788
|
+
"definitions",
|
|
5789
|
+
"graph",
|
|
5790
|
+
"result"
|
|
5791
|
+
]
|
|
5792
|
+
},
|
|
4759
5793
|
{
|
|
4760
5794
|
kind: "component",
|
|
4761
5795
|
type: FlowsGraphCanvasComponent,
|
|
@@ -4763,6 +5797,7 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4763
5797
|
inputs: [
|
|
4764
5798
|
"graph",
|
|
4765
5799
|
"definitions",
|
|
5800
|
+
"workflowFields",
|
|
4766
5801
|
"readOnly"
|
|
4767
5802
|
],
|
|
4768
5803
|
outputs: [
|
|
@@ -4788,13 +5823,20 @@ var FlowsVersionEditorComponent = class FlowsVersionEditorComponent {
|
|
|
4788
5823
|
"subscriptionId",
|
|
4789
5824
|
"readOnly",
|
|
4790
5825
|
"fieldSuggestions",
|
|
4791
|
-
"listSuggestions"
|
|
5826
|
+
"listSuggestions",
|
|
5827
|
+
"fieldSources",
|
|
5828
|
+
"firstRun"
|
|
4792
5829
|
],
|
|
4793
5830
|
outputs: ["nodeChange", "remove"]
|
|
4794
5831
|
},
|
|
4795
5832
|
{
|
|
4796
5833
|
kind: "pipe",
|
|
4797
|
-
type:
|
|
5834
|
+
type: i1$2.AsyncPipe,
|
|
5835
|
+
name: "async"
|
|
5836
|
+
},
|
|
5837
|
+
{
|
|
5838
|
+
kind: "pipe",
|
|
5839
|
+
type: i2$4.TranslocoPipe,
|
|
4798
5840
|
name: "transloco"
|
|
4799
5841
|
}
|
|
4800
5842
|
]
|
|
@@ -4811,13 +5853,14 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4811
5853
|
args: [{
|
|
4812
5854
|
selector: "pw-flows-version-editor",
|
|
4813
5855
|
standalone: false,
|
|
4814
|
-
template: "<div class=\"pw-version-editor mt-3\">\n <h3>{{ headingKey | transloco: { number: duplicateOf?.version } }}</h3>\n\n <pw-loader [isVisible]=\"loading\"></pw-loader>\n\n @if (!loading) {\n @if (loadFailed) {\n <pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Canvas.LoadFailed' | transloco\">\n </pw-field-error-display>\n } @else {\n <div class=\"pw-version-editor__toolbar\">\n <div class=\"btn-group\"\n role=\"tablist\">\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-canvas\"\n [class.active]=\"view === 'canvas'\"\n [attr.aria-selected]=\"view === 'canvas'\"\n (click)=\"show('canvas')\">\n <fa-icon [icon]=\"icons.diagram\"></fa-icon>\n {{ 'Flows.Canvas.Diagram' | transloco }}\n </button>\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-json\"\n [class.active]=\"view === 'json'\"\n [attr.aria-selected]=\"view === 'json'\"\n (click)=\"show('json')\">\n <fa-icon [icon]=\"icons.json\"></fa-icon>\n {{ 'Flows.Canvas.Json' | transloco }}\n </button>\n </div>\n @if (view === 'canvas') {\n <button type=\"button\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-fit\"\n (click)=\"canvas.zoomToFit()\">\n <fa-icon [icon]=\"icons.fit\"></fa-icon>\n {{ 'Flows.Canvas.Fit' | transloco }}\n </button>\n }\n </div>\n\n @if (dropped.length) {\n <p class=\"pw-version-editor__warning\"\n role=\"alert\"\n data-testid=\"flow-dropped-edges\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Canvas.Dropped' | transloco: { count: dropped.length } }}\n </p>\n }\n\n <div class=\"pw-version-editor__workspace\"\n [class.is-read-only]=\"readOnly\"\n [hidden]=\"view !== 'canvas'\">\n @if (!readOnly) {\n <pw-flows-node-palette class=\"pw-version-editor__palette\"\n [definitions]=\"definitions\"\n (add)=\"canvas.addNode($event)\"></pw-flows-node-palette>\n }\n <pw-flows-graph-canvas #canvas\n class=\"pw-version-editor__canvas\"\n [graph]=\"graph\"\n [definitions]=\"definitions\"\n [readOnly]=\"readOnly\"\n (selectionChange)=\"select($event)\"\n (dropped)=\"dropped = $event\"></pw-flows-graph-canvas>\n <div class=\"pw-version-editor__side\">\n @if (selection) {\n <pw-flows-node-inspector [node]=\"selection.node\"\n [definition]=\"selection.definition\"\n [fieldSuggestions]=\"selection.fieldSuggestions\"\n [listSuggestions]=\"selection.listSuggestions\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n (nodeChange)=\"updateSelected($event)\"\n (remove)=\"removeSelected()\"></pw-flows-node-inspector>\n } @else {\n <p class=\"pw-version-editor__hint\">{{ (readOnly ? 'Flows.Canvas.SelectToView' : 'Flows.Canvas.SelectToEdit') | transloco }}</p>\n }\n </div>\n </div>\n\n @if (view === 'json') {\n <pre class=\"pw-version-editor__json\"\n data-testid=\"flow-json\">{{ json }}</pre>\n }\n }\n }\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"cancel()\">\n {{ (readOnly ? 'Flows.Versions.Editor.Close' : 'Button.Cancel') | transloco }}\n </button>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"saving || loading || loadFailed\"\n (click)=\"save()\">\n {{ 'Button.Submit' | transloco }}\n </button>\n }\n </div>\n</div>\n",
|
|
4815
|
-
styles: [":host .pw-version-editor>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}.pw-version-editor__toolbar{display:flex;align-items:center;
|
|
5856
|
+
template: "<div class=\"pw-version-editor mt-3\">\n <h3>{{ headingKey | transloco: { number: duplicateOf?.version } }}</h3>\n\n <pw-loader [isVisible]=\"loading\"></pw-loader>\n\n @if (!loading) {\n @if (loadFailed) {\n <pw-field-error-display [displayError]=\"true\"\n [errorMsg]=\"'Flows.Canvas.LoadFailed' | transloco\">\n </pw-field-error-display>\n } @else {\n <div class=\"pw-version-editor__toolbar\">\n <div class=\"btn-group me-auto\"\n role=\"tablist\">\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-canvas\"\n [class.active]=\"view === 'canvas'\"\n [attr.aria-selected]=\"view === 'canvas'\"\n (click)=\"show('canvas')\">\n <fa-icon [icon]=\"icons.diagram\"></fa-icon>\n {{ 'Flows.Canvas.Diagram' | transloco }}\n </button>\n <button type=\"button\"\n role=\"tab\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-view-json\"\n [class.active]=\"view === 'json'\"\n [attr.aria-selected]=\"view === 'json'\"\n (click)=\"show('json')\">\n <fa-icon [icon]=\"icons.json\"></fa-icon>\n {{ 'Flows.Canvas.Json' | transloco }}\n </button>\n </div>\n @if (view === 'canvas') {\n <button type=\"button\"\n class=\"btn btn-outline-default btn-sm\"\n data-testid=\"flow-fit\"\n (click)=\"canvas.zoomToFit()\">\n <fa-icon [icon]=\"icons.fit\"></fa-icon>\n {{ 'Flows.Canvas.Fit' | transloco }}\n </button>\n }\n </div>\n\n @if (check && !readOnly) {\n <pw-flows-graph-check [canvas]=\"canvas\"\n [definitions]=\"definitions\"\n [graph]=\"graph\"\n [result]=\"check\"></pw-flows-graph-check>\n }\n\n @if (dropped.length) {\n <p class=\"pw-version-editor__warning\"\n role=\"alert\"\n data-testid=\"flow-dropped-edges\">\n <fa-icon [icon]=\"icons.warning\"></fa-icon>\n {{ 'Flows.Canvas.Dropped' | transloco: { count: dropped.length } }}\n </p>\n }\n\n @let fields = workflowFields$ | async;\n <div class=\"pw-version-editor__workspace\"\n [class.is-read-only]=\"readOnly\"\n [hidden]=\"view !== 'canvas'\">\n @if (!readOnly) {\n <pw-flows-node-palette class=\"pw-version-editor__palette\"\n [definitions]=\"definitions\"\n (add)=\"canvas.addNode($event)\"></pw-flows-node-palette>\n }\n <pw-flows-graph-canvas #canvas\n class=\"pw-version-editor__canvas\"\n [graph]=\"graph\"\n [definitions]=\"definitions\"\n [workflowFields]=\"fields\"\n [readOnly]=\"readOnly\"\n (selectionChange)=\"select($event)\"\n (dropped)=\"dropped = $event\"></pw-flows-graph-canvas>\n <div class=\"pw-version-editor__side\">\n @if (selection) {\n <pw-flows-node-inspector [node]=\"selection.node\"\n [definition]=\"selection.definition\"\n [fieldSuggestions]=\"selection.fieldSuggestions\"\n [fieldSources]=\"selection.fieldSources\"\n [listSuggestions]=\"selection.listSuggestions\"\n [subscriptionId]=\"subscriptionId\"\n [readOnly]=\"readOnly\"\n [firstRun]=\"!!fields && !fields.ran\"\n (nodeChange)=\"updateSelected($event)\"\n (remove)=\"removeSelected()\"></pw-flows-node-inspector>\n } @else {\n <p class=\"pw-version-editor__hint\">{{ (readOnly ? 'Flows.Canvas.SelectToView' : 'Flows.Canvas.SelectToEdit') | transloco }}</p>\n }\n </div>\n </div>\n\n @if (view === 'json') {\n <pre class=\"pw-version-editor__json\"\n data-testid=\"flow-json\">{{ json }}</pre>\n }\n }\n }\n\n <div class=\"mb-3 col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"cancel()\">\n {{ (readOnly ? 'Flows.Versions.Editor.Close' : 'Button.Cancel') | transloco }}\n </button>\n @if (!readOnly) {\n <button type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"saving || loading || loadFailed\"\n (click)=\"save()\">\n {{ 'Button.Submit' | transloco }}\n </button>\n }\n </div>\n</div>\n",
|
|
5857
|
+
styles: [":host .pw-version-editor>h3{display:block;border-top:1px solid #e2e5ea;margin-top:2rem;padding-top:1.25rem}.pw-version-editor__toolbar{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin-bottom:8px}.pw-version-editor__warning{display:flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid #b7791f;border-radius:4px;color:#b7791f}.pw-version-editor__workspace{display:grid;grid-template-columns:200px minmax(0,1fr) 300px;height:560px;border:1px solid #e2e5ea;border-radius:8px;overflow:hidden}.pw-version-editor__workspace.is-read-only{grid-template-columns:minmax(0,1fr) 300px}.pw-version-editor__palette,.pw-version-editor__side{overflow-y:auto;background:#fff}.pw-version-editor__palette{border-right:1px solid #e2e5ea}.pw-version-editor__side{border-left:1px solid #e2e5ea}.pw-version-editor__hint{margin:0;padding:16px;color:#7c8696}.pw-version-editor__json{max-height:560px;margin:0;padding:12px;overflow:auto;border:1px solid #e2e5ea;border-radius:8px;background:#f7f8fa}@media(max-width:991px){.pw-version-editor__workspace{grid-template-columns:minmax(0,1fr);grid-template-rows:auto 420px auto;height:auto}.pw-version-editor__workspace.is-read-only{grid-template-columns:minmax(0,1fr);grid-template-rows:420px auto}.pw-version-editor__palette{max-height:200px;border-right:0;border-bottom:1px solid #e2e5ea}.pw-version-editor__side{border-left:0;border-top:1px solid #e2e5ea}}\n"]
|
|
4816
5858
|
}]
|
|
4817
5859
|
}],
|
|
4818
5860
|
ctorParameters: () => [
|
|
4819
5861
|
{ type: FlowsWorkflowService },
|
|
4820
5862
|
{ type: FlowsNodeService },
|
|
5863
|
+
{ type: FlowsRunService },
|
|
4821
5864
|
{ type: i0.ChangeDetectorRef }
|
|
4822
5865
|
],
|
|
4823
5866
|
propDecorators: {
|
|
@@ -4825,6 +5868,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4825
5868
|
duplicateOf: [{ type: Input }],
|
|
4826
5869
|
workflowId: [{ type: Input }],
|
|
4827
5870
|
subscriptionId: [{ type: Input }],
|
|
5871
|
+
check: [{ type: Input }],
|
|
4828
5872
|
saved: [{ type: Output }],
|
|
4829
5873
|
cancelled: [{ type: Output }],
|
|
4830
5874
|
canvas: [{
|
|
@@ -4845,9 +5889,7 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
4845
5889
|
this.workflowName = "";
|
|
4846
5890
|
this.versions = [];
|
|
4847
5891
|
this.totalRecords = 0;
|
|
4848
|
-
this.
|
|
4849
|
-
this.editorVersion = null;
|
|
4850
|
-
this.editorDuplicateOf = null;
|
|
5892
|
+
this.editor = new FlowVersionEditorState();
|
|
4851
5893
|
this.requestedVersionId = null;
|
|
4852
5894
|
this.icons = FLOWS_ICONS;
|
|
4853
5895
|
this.isPublished = isFlowVersionPublished;
|
|
@@ -4874,17 +5916,13 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
4874
5916
|
this.destroy$.complete();
|
|
4875
5917
|
}
|
|
4876
5918
|
openEditor(version = null, duplicateOf = null) {
|
|
4877
|
-
this.
|
|
4878
|
-
this.editorDuplicateOf = duplicateOf;
|
|
4879
|
-
this.editorOpen = true;
|
|
5919
|
+
this.editor.show(version, duplicateOf);
|
|
4880
5920
|
}
|
|
4881
5921
|
duplicate(version) {
|
|
4882
5922
|
this.openEditor(null, version);
|
|
4883
5923
|
}
|
|
4884
5924
|
closeEditor() {
|
|
4885
|
-
this.
|
|
4886
|
-
this.editorVersion = null;
|
|
4887
|
-
this.editorDuplicateOf = null;
|
|
5925
|
+
this.editor.close();
|
|
4888
5926
|
}
|
|
4889
5927
|
onVersionSaved() {
|
|
4890
5928
|
this.closeEditor();
|
|
@@ -4893,18 +5931,21 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
4893
5931
|
publish(version) {
|
|
4894
5932
|
if (this.publishing) return;
|
|
4895
5933
|
this.publishing = true;
|
|
4896
|
-
this.workflowService.
|
|
4897
|
-
|
|
4898
|
-
|
|
4899
|
-
|
|
4900
|
-
|
|
4901
|
-
|
|
4902
|
-
error: () => {
|
|
4903
|
-
this.publishing = false;
|
|
4904
|
-
this.cdr.markForCheck();
|
|
4905
|
-
}
|
|
5934
|
+
this.workflowService.publishChecked(this.workflowId, version, this.subscriptionId).pipe(finalize(() => {
|
|
5935
|
+
this.publishing = false;
|
|
5936
|
+
this.cdr.markForCheck();
|
|
5937
|
+
}), takeUntil(this.destroy$)).subscribe({
|
|
5938
|
+
next: (outcome) => this.publishOutcome(version, outcome),
|
|
5939
|
+
error: () => null
|
|
4906
5940
|
});
|
|
4907
5941
|
}
|
|
5942
|
+
publishOutcome(version, outcome) {
|
|
5943
|
+
if ("valid" in outcome) this.editor.show(version, null, outcome);
|
|
5944
|
+
else {
|
|
5945
|
+
this.editor.published(outcome);
|
|
5946
|
+
this.load();
|
|
5947
|
+
}
|
|
5948
|
+
}
|
|
4908
5949
|
back() {
|
|
4909
5950
|
this.router.navigate(["workflows"], { relativeTo: this.route.parent });
|
|
4910
5951
|
}
|
|
@@ -4936,7 +5977,7 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
4936
5977
|
openRequestedVersion() {
|
|
4937
5978
|
const version = this.versions.find(({ id }) => id === this.requestedVersionId);
|
|
4938
5979
|
this.requestedVersionId = null;
|
|
4939
|
-
if (version) this.openEditor(version);
|
|
5980
|
+
if (version || !this.totalRecords && !this.editor.open) this.openEditor(version ?? null);
|
|
4940
5981
|
}
|
|
4941
5982
|
settle() {
|
|
4942
5983
|
this.loading = false;
|
|
@@ -4966,12 +6007,12 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
4966
6007
|
selector: "pw-flows-workflow-versions",
|
|
4967
6008
|
usesInheritance: true,
|
|
4968
6009
|
ngImport: i0,
|
|
4969
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ 'Flows.Versions.Title' | transloco }}\n @if (workflowName) {\n <span class=\"pw-versions-subject\">{{ workflowName }}</span>\n }\n </h2>\n <div>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary me-2\"\n [disabled]=\"
|
|
6010
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ 'Flows.Versions.Title' | transloco }}\n @if (workflowName) {\n <span class=\"pw-versions-subject\">{{ workflowName }}</span>\n }\n </h2>\n <div>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary me-2\"\n [disabled]=\"editor.open\"\n (click)=\"openEditor()\">\n <fa-icon [icon]=\"icons.create\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Versions.Create' | transloco }}\n </button>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-secondary\"\n (click)=\"back()\">\n <fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Back' | transloco }}\n </button>\n </div>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"5\" [showCaption]=\"false\" />\n}\n\n@if (!loading) {\n@if (notFound) {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Versions.NotFound' | transloco\"></pw-no-data>\n} @else {\n@if (versions.length > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table [value]=\"versions\">\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Versions.Column.Version' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Versions.Column.State' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Versions.Column.Published' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Versions.Column.Created' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-three\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-version>\n <tr>\n <td data-head=\"Version\">{{ version.version }}</td>\n <td data-head=\"State\">\n <span [class]=\"badgeClass(version)\">\n {{ (isPublished(version) ? 'Flows.Versions.State.Published' : 'Flows.Versions.State.Draft') | transloco }}\n </span>\n </td>\n <td data-head=\"Published\">\n {{ version.published_at ? (version.published_at | dateFormat) : '—' }}\n </td>\n <td data-head=\"Created\">{{ version.created_at | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li [pTooltip]=\"(isPublished(version) ? 'Flows.Versions.Action.View' : 'Flows.Versions.Action.Edit') | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon [class]=\"isPublished(version) ? 'cta1-icon' : 'edit-icon'\"\n [icon]=\"isPublished(version) ? icons.inspect : icons.edit\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"(isPublished(version) ? 'Flows.Versions.Action.View' : 'Flows.Versions.Action.Edit') | transloco\"\n (click)=\"openEditor(version)\"\n (keydown.enter)=\"openEditor(version)\"></fa-icon>\n </li>\n <li [pTooltip]=\"'Flows.Versions.Action.Duplicate' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.duplicate\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Versions.Action.Duplicate' | transloco\"\n (click)=\"duplicate(version)\"\n (keydown.enter)=\"duplicate(version)\"></fa-icon>\n </li>\n <!-- Hiding this is courtesy; protect_endpoint! is the control. -->\n @if (!isPublished(version) && canPublish) {\n <li [pTooltip]=\"'Flows.Versions.Action.Publish' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.publish\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Versions.Action.Publish' | transloco\"\n (click)=\"publish(version)\"\n (keydown.enter)=\"publish(version)\"></fa-icon>\n </li>\n }\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n\n <pw-records-summary [showing]=\"versions.length\"\n [total]=\"totalRecords\" />\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Versions.Empty' | transloco\" [description]=\"'Flows.Versions.EmptyDescription' | transloco\"></pw-no-data>\n}\n\n@if (editor.open) {\n<pw-flows-version-editor [version]=\"editor.version\"\n [duplicateOf]=\"editor.duplicateOf\"\n [workflowId]=\"workflowId\"\n [subscriptionId]=\"subscriptionId\"\n [check]=\"editor.check\"\n (saved)=\"onVersionSaved()\"\n (cancelled)=\"closeEditor()\">\n</pw-flows-version-editor>\n}\n}\n}\n",
|
|
4970
6011
|
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.pw-versions-subject{margin-left:.5rem;color:#5a6473;font-weight:400}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}\n"],
|
|
4971
6012
|
dependencies: [
|
|
4972
6013
|
{
|
|
4973
6014
|
kind: "component",
|
|
4974
|
-
type:
|
|
6015
|
+
type: i4$1.SkeletonTableComponent,
|
|
4975
6016
|
selector: "pw-skeleton-table",
|
|
4976
6017
|
inputs: [
|
|
4977
6018
|
"rows",
|
|
@@ -4984,7 +6025,7 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
4984
6025
|
},
|
|
4985
6026
|
{
|
|
4986
6027
|
kind: "directive",
|
|
4987
|
-
type:
|
|
6028
|
+
type: i1$1.Tooltip,
|
|
4988
6029
|
selector: "[pTooltip]",
|
|
4989
6030
|
inputs: [
|
|
4990
6031
|
"tooltipPosition",
|
|
@@ -5012,7 +6053,7 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
5012
6053
|
},
|
|
5013
6054
|
{
|
|
5014
6055
|
kind: "component",
|
|
5015
|
-
type:
|
|
6056
|
+
type: i5.Table,
|
|
5016
6057
|
selector: "p-table",
|
|
5017
6058
|
inputs: [
|
|
5018
6059
|
"frozenColumns",
|
|
@@ -5125,7 +6166,7 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
5125
6166
|
},
|
|
5126
6167
|
{
|
|
5127
6168
|
kind: "component",
|
|
5128
|
-
type:
|
|
6169
|
+
type: i6.NoDataComponent,
|
|
5129
6170
|
selector: "pw-no-data",
|
|
5130
6171
|
inputs: [
|
|
5131
6172
|
"message",
|
|
@@ -5135,13 +6176,13 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
5135
6176
|
},
|
|
5136
6177
|
{
|
|
5137
6178
|
kind: "component",
|
|
5138
|
-
type:
|
|
6179
|
+
type: i6.RecordsSummaryComponent,
|
|
5139
6180
|
selector: "pw-records-summary",
|
|
5140
6181
|
inputs: ["showing", "total"]
|
|
5141
6182
|
},
|
|
5142
6183
|
{
|
|
5143
6184
|
kind: "component",
|
|
5144
|
-
type:
|
|
6185
|
+
type: i2$3.FaIconComponent,
|
|
5145
6186
|
selector: "fa-icon",
|
|
5146
6187
|
inputs: [
|
|
5147
6188
|
"icon",
|
|
@@ -5184,19 +6225,20 @@ var FlowsWorkflowVersionsComponent = class FlowsWorkflowVersionsComponent extend
|
|
|
5184
6225
|
"version",
|
|
5185
6226
|
"duplicateOf",
|
|
5186
6227
|
"workflowId",
|
|
5187
|
-
"subscriptionId"
|
|
6228
|
+
"subscriptionId",
|
|
6229
|
+
"check"
|
|
5188
6230
|
],
|
|
5189
6231
|
outputs: ["saved", "cancelled"]
|
|
5190
6232
|
},
|
|
5191
6233
|
{
|
|
5192
6234
|
kind: "pipe",
|
|
5193
|
-
type:
|
|
5194
|
-
name: "
|
|
6235
|
+
type: i2$4.TranslocoPipe,
|
|
6236
|
+
name: "transloco"
|
|
5195
6237
|
},
|
|
5196
6238
|
{
|
|
5197
6239
|
kind: "pipe",
|
|
5198
|
-
type:
|
|
5199
|
-
name: "
|
|
6240
|
+
type: i13.DateFormatPipe,
|
|
6241
|
+
name: "dateFormat"
|
|
5200
6242
|
}
|
|
5201
6243
|
]
|
|
5202
6244
|
});
|
|
@@ -5212,7 +6254,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
5212
6254
|
args: [{
|
|
5213
6255
|
selector: "pw-flows-workflow-versions",
|
|
5214
6256
|
standalone: false,
|
|
5215
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ 'Flows.Versions.Title' | transloco }}\n @if (workflowName) {\n <span class=\"pw-versions-subject\">{{ workflowName }}</span>\n }\n </h2>\n <div>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary me-2\"\n [disabled]=\"
|
|
6257
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">\n {{ 'Flows.Versions.Title' | transloco }}\n @if (workflowName) {\n <span class=\"pw-versions-subject\">{{ workflowName }}</span>\n }\n </h2>\n <div>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary me-2\"\n [disabled]=\"editor.open\"\n (click)=\"openEditor()\">\n <fa-icon [icon]=\"icons.create\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Versions.Create' | transloco }}\n </button>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-secondary\"\n (click)=\"back()\">\n <fa-icon [icon]=\"icons.back\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Back' | transloco }}\n </button>\n </div>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"5\" [showCaption]=\"false\" />\n}\n\n@if (!loading) {\n@if (notFound) {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Versions.NotFound' | transloco\"></pw-no-data>\n} @else {\n@if (versions.length > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table [value]=\"versions\">\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Versions.Column.Version' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Versions.Column.State' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Versions.Column.Published' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Versions.Column.Created' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-three\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-version>\n <tr>\n <td data-head=\"Version\">{{ version.version }}</td>\n <td data-head=\"State\">\n <span [class]=\"badgeClass(version)\">\n {{ (isPublished(version) ? 'Flows.Versions.State.Published' : 'Flows.Versions.State.Draft') | transloco }}\n </span>\n </td>\n <td data-head=\"Published\">\n {{ version.published_at ? (version.published_at | dateFormat) : '—' }}\n </td>\n <td data-head=\"Created\">{{ version.created_at | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li [pTooltip]=\"(isPublished(version) ? 'Flows.Versions.Action.View' : 'Flows.Versions.Action.Edit') | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon [class]=\"isPublished(version) ? 'cta1-icon' : 'edit-icon'\"\n [icon]=\"isPublished(version) ? icons.inspect : icons.edit\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"(isPublished(version) ? 'Flows.Versions.Action.View' : 'Flows.Versions.Action.Edit') | transloco\"\n (click)=\"openEditor(version)\"\n (keydown.enter)=\"openEditor(version)\"></fa-icon>\n </li>\n <li [pTooltip]=\"'Flows.Versions.Action.Duplicate' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.duplicate\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Versions.Action.Duplicate' | transloco\"\n (click)=\"duplicate(version)\"\n (keydown.enter)=\"duplicate(version)\"></fa-icon>\n </li>\n <!-- Hiding this is courtesy; protect_endpoint! is the control. -->\n @if (!isPublished(version) && canPublish) {\n <li [pTooltip]=\"'Flows.Versions.Action.Publish' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.publish\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Versions.Action.Publish' | transloco\"\n (click)=\"publish(version)\"\n (keydown.enter)=\"publish(version)\"></fa-icon>\n </li>\n }\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n\n <pw-records-summary [showing]=\"versions.length\"\n [total]=\"totalRecords\" />\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Versions.Empty' | transloco\" [description]=\"'Flows.Versions.EmptyDescription' | transloco\"></pw-no-data>\n}\n\n@if (editor.open) {\n<pw-flows-version-editor [version]=\"editor.version\"\n [duplicateOf]=\"editor.duplicateOf\"\n [workflowId]=\"workflowId\"\n [subscriptionId]=\"subscriptionId\"\n [check]=\"editor.check\"\n (saved)=\"onVersionSaved()\"\n (cancelled)=\"closeEditor()\">\n</pw-flows-version-editor>\n}\n}\n}\n",
|
|
5216
6258
|
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.pw-versions-subject{margin-left:.5rem;color:#5a6473;font-weight:400}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}\n"]
|
|
5217
6259
|
}]
|
|
5218
6260
|
}],
|
|
@@ -5338,7 +6380,7 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5338
6380
|
deps: [
|
|
5339
6381
|
{ token: i0.Injector },
|
|
5340
6382
|
{ token: FlowsWorkflowService },
|
|
5341
|
-
{ token:
|
|
6383
|
+
{ token: i6.ConfirmDialogService },
|
|
5342
6384
|
{ token: i0.ChangeDetectorRef }
|
|
5343
6385
|
],
|
|
5344
6386
|
target: i0.ɵɵFactoryTarget.Component
|
|
@@ -5353,7 +6395,7 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5353
6395
|
selector: "pw-flows-workflows",
|
|
5354
6396
|
usesInheritance: true,
|
|
5355
6397
|
ngImport: i0,
|
|
5356
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Workflows.Title' | transloco }}</h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary\"\n (click)=\"createWorkflow()\">\n <fa-icon [icon]=\"icons.create\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Create' | transloco }}\n </button>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"5\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"workflows\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\"\n filterDelay=\"1000\">\n <ng-template #caption>\n <div class=\"search-filter\">\n <div class=\"col-12 col-sm-4\">\n <p-select inputId=\"flows-workflows-status\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n [placeholder]=\"'Flows.Workflows.Filter.Status' | transloco\"\n [showClear]=\"true\"\n [(ngModel)]=\"status\"\n (onChange)=\"filterByStatus($event.value)\"\n appendTo=\"body\">\n </p-select>\n </div>\n <!-- No ngModel — onLazyLoad is the single writer of searchText. -->\n <div class=\"text-end\">\n <label for=\"flows-workflows-search\"\n class=\"visually-hidden\">{{ 'Flows.Workflows.Filter.SearchLabel' | transloco }}</label>\n <p-iconfield iconPosition=\"left\">\n <p-inputicon><fa-icon [icon]=\"icons.search\"\n aria-hidden=\"true\"></fa-icon></p-inputicon>\n <input #searchInput\n type=\"text\"\n id=\"flows-workflows-search\"\n name=\"flows-workflows-search\"\n pInputText\n [placeholder]=\"'Flows.Workflows.Filter.Search' | transloco\"\n (input)=\"dt.filterGlobal(searchInput.value, 'contains')\" />\n </p-iconfield>\n </div>\n </div>\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Name' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Description' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Created' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-three\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-workflow>\n <tr>\n <td data-head=\"Name\">{{ workflow.name }}</td>\n <td data-head=\"Description\">{{ workflow.description || '—' }}</td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(workflow.status)\">\n {{ 'Flows.WorkflowStatus.' + workflow.status | transloco }}\n </span>\n </td>\n <td data-head=\"Created\">{{ workflow.created_at |
|
|
6398
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Workflows.Title' | transloco }}</h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary\"\n (click)=\"createWorkflow()\">\n <fa-icon [icon]=\"icons.create\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Create' | transloco }}\n </button>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"5\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"workflows\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\"\n filterDelay=\"1000\">\n <ng-template #caption>\n <div class=\"search-filter\">\n <div class=\"col-12 col-sm-4\">\n <p-select inputId=\"flows-workflows-status\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n [placeholder]=\"'Flows.Workflows.Filter.Status' | transloco\"\n [showClear]=\"true\"\n [(ngModel)]=\"status\"\n (onChange)=\"filterByStatus($event.value)\"\n appendTo=\"body\">\n </p-select>\n </div>\n <!-- No ngModel — onLazyLoad is the single writer of searchText. -->\n <div class=\"text-end\">\n <label for=\"flows-workflows-search\"\n class=\"visually-hidden\">{{ 'Flows.Workflows.Filter.SearchLabel' | transloco }}</label>\n <p-iconfield iconPosition=\"left\">\n <p-inputicon><fa-icon [icon]=\"icons.search\"\n aria-hidden=\"true\"></fa-icon></p-inputicon>\n <input #searchInput\n type=\"text\"\n id=\"flows-workflows-search\"\n name=\"flows-workflows-search\"\n pInputText\n [placeholder]=\"'Flows.Workflows.Filter.Search' | transloco\"\n (input)=\"dt.filterGlobal(searchInput.value, 'contains')\" />\n </p-iconfield>\n </div>\n </div>\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Name' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Description' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Created' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-three\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-workflow>\n <tr>\n <td data-head=\"Name\">{{ workflow.name }}</td>\n <td data-head=\"Description\">{{ workflow.description || '—' }}</td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(workflow.status)\">\n {{ 'Flows.WorkflowStatus.' + workflow.status | transloco }}\n </span>\n </td>\n <td data-head=\"Created\">{{ workflow.created_at | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li [pTooltip]=\"'Flows.Workflows.Action.Versions' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.versions\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Workflows.Action.Versions' | transloco\"\n (click)=\"openVersions(workflow)\"\n (keydown.enter)=\"openVersions(workflow)\"></fa-icon>\n </li>\n <li [pTooltip]=\"'Flows.Workflows.Action.Edit' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"edit-icon\"\n [icon]=\"icons.edit\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Workflows.Action.Edit' | transloco\"\n (click)=\"editWorkflow(workflow)\"\n (keydown.enter)=\"editWorkflow(workflow)\"></fa-icon>\n </li>\n <li [pTooltip]=\"'Flows.Workflows.Action.Delete' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"delete-icon\"\n [icon]=\"icons.delete\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Workflows.Action.Delete' | transloco\"\n (click)=\"deleteWorkflow(workflow)\"\n (keydown.enter)=\"deleteWorkflow(workflow)\"></fa-icon>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n\n <pw-records-summary [showing]=\"workflows.length\"\n [total]=\"totalRecords\" />\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Workflows.Empty' | transloco\" [description]=\"'Flows.Workflows.EmptyDescription' | transloco\"></pw-no-data>\n}\n}\n",
|
|
5357
6399
|
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}.primeng-datatable-container td[data-head=Name]{min-width:200px;font-weight:600;color:#1a1d21}.primeng-datatable-container td[data-head=Description]{min-width:220px;color:#5a6473}\n"],
|
|
5358
6400
|
dependencies: [
|
|
5359
6401
|
{
|
|
@@ -5376,7 +6418,7 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5376
6418
|
},
|
|
5377
6419
|
{
|
|
5378
6420
|
kind: "component",
|
|
5379
|
-
type:
|
|
6421
|
+
type: i4$1.SkeletonTableComponent,
|
|
5380
6422
|
selector: "pw-skeleton-table",
|
|
5381
6423
|
inputs: [
|
|
5382
6424
|
"rows",
|
|
@@ -5389,7 +6431,7 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5389
6431
|
},
|
|
5390
6432
|
{
|
|
5391
6433
|
kind: "directive",
|
|
5392
|
-
type:
|
|
6434
|
+
type: i1$1.Tooltip,
|
|
5393
6435
|
selector: "[pTooltip]",
|
|
5394
6436
|
inputs: [
|
|
5395
6437
|
"tooltipPosition",
|
|
@@ -5417,7 +6459,7 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5417
6459
|
},
|
|
5418
6460
|
{
|
|
5419
6461
|
kind: "component",
|
|
5420
|
-
type:
|
|
6462
|
+
type: i5.Table,
|
|
5421
6463
|
selector: "p-table",
|
|
5422
6464
|
inputs: [
|
|
5423
6465
|
"frozenColumns",
|
|
@@ -5600,7 +6642,7 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5600
6642
|
},
|
|
5601
6643
|
{
|
|
5602
6644
|
kind: "component",
|
|
5603
|
-
type:
|
|
6645
|
+
type: i6.NoDataComponent,
|
|
5604
6646
|
selector: "pw-no-data",
|
|
5605
6647
|
inputs: [
|
|
5606
6648
|
"message",
|
|
@@ -5610,13 +6652,13 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5610
6652
|
},
|
|
5611
6653
|
{
|
|
5612
6654
|
kind: "component",
|
|
5613
|
-
type:
|
|
6655
|
+
type: i6.RecordsSummaryComponent,
|
|
5614
6656
|
selector: "pw-records-summary",
|
|
5615
6657
|
inputs: ["showing", "total"]
|
|
5616
6658
|
},
|
|
5617
6659
|
{
|
|
5618
6660
|
kind: "component",
|
|
5619
|
-
type:
|
|
6661
|
+
type: i2$3.FaIconComponent,
|
|
5620
6662
|
selector: "fa-icon",
|
|
5621
6663
|
inputs: [
|
|
5622
6664
|
"icon",
|
|
@@ -5679,13 +6721,13 @@ var FlowsWorkflowsComponent = class FlowsWorkflowsComponent extends AppBaseCompo
|
|
|
5679
6721
|
},
|
|
5680
6722
|
{
|
|
5681
6723
|
kind: "pipe",
|
|
5682
|
-
type:
|
|
5683
|
-
name: "
|
|
6724
|
+
type: i2$4.TranslocoPipe,
|
|
6725
|
+
name: "transloco"
|
|
5684
6726
|
},
|
|
5685
6727
|
{
|
|
5686
6728
|
kind: "pipe",
|
|
5687
|
-
type:
|
|
5688
|
-
name: "
|
|
6729
|
+
type: i13.DateFormatPipe,
|
|
6730
|
+
name: "dateFormat"
|
|
5689
6731
|
}
|
|
5690
6732
|
]
|
|
5691
6733
|
});
|
|
@@ -5701,14 +6743,14 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
5701
6743
|
args: [{
|
|
5702
6744
|
selector: "pw-flows-workflows",
|
|
5703
6745
|
standalone: false,
|
|
5704
|
-
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Workflows.Title' | transloco }}</h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary\"\n (click)=\"createWorkflow()\">\n <fa-icon [icon]=\"icons.create\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Create' | transloco }}\n </button>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"5\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"workflows\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\"\n filterDelay=\"1000\">\n <ng-template #caption>\n <div class=\"search-filter\">\n <div class=\"col-12 col-sm-4\">\n <p-select inputId=\"flows-workflows-status\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n [placeholder]=\"'Flows.Workflows.Filter.Status' | transloco\"\n [showClear]=\"true\"\n [(ngModel)]=\"status\"\n (onChange)=\"filterByStatus($event.value)\"\n appendTo=\"body\">\n </p-select>\n </div>\n <!-- No ngModel — onLazyLoad is the single writer of searchText. -->\n <div class=\"text-end\">\n <label for=\"flows-workflows-search\"\n class=\"visually-hidden\">{{ 'Flows.Workflows.Filter.SearchLabel' | transloco }}</label>\n <p-iconfield iconPosition=\"left\">\n <p-inputicon><fa-icon [icon]=\"icons.search\"\n aria-hidden=\"true\"></fa-icon></p-inputicon>\n <input #searchInput\n type=\"text\"\n id=\"flows-workflows-search\"\n name=\"flows-workflows-search\"\n pInputText\n [placeholder]=\"'Flows.Workflows.Filter.Search' | transloco\"\n (input)=\"dt.filterGlobal(searchInput.value, 'contains')\" />\n </p-iconfield>\n </div>\n </div>\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Name' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Description' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Created' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-three\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-workflow>\n <tr>\n <td data-head=\"Name\">{{ workflow.name }}</td>\n <td data-head=\"Description\">{{ workflow.description || '—' }}</td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(workflow.status)\">\n {{ 'Flows.WorkflowStatus.' + workflow.status | transloco }}\n </span>\n </td>\n <td data-head=\"Created\">{{ workflow.created_at |
|
|
6746
|
+
template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0\">{{ 'Flows.Workflows.Title' | transloco }}</h2>\n <button type=\"button\"\n class=\"btn btn-sm btn-outline-primary\"\n (click)=\"createWorkflow()\">\n <fa-icon [icon]=\"icons.create\"\n aria-hidden=\"true\"></fa-icon>\n {{ 'Flows.Workflows.Create' | transloco }}\n </button>\n </div>\n</div>\n\n@if (loading) {\n<pw-skeleton-table [rows]=\"8\" [columns]=\"5\" [showCaption]=\"true\" />\n}\n\n@if (!loading) {\n@if (totalRecordsUnFilter > 0) {\n<div class=\"primeng-datatable-container table-responsive mt-3\">\n <p-table #dt\n [value]=\"workflows\"\n [paginator]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n (onLazyLoad)=\"onLazyLoad($event)\"\n filterDelay=\"1000\">\n <ng-template #caption>\n <div class=\"search-filter\">\n <div class=\"col-12 col-sm-4\">\n <p-select inputId=\"flows-workflows-status\"\n [options]=\"statusOptions\"\n optionValue=\"value\"\n [placeholder]=\"'Flows.Workflows.Filter.Status' | transloco\"\n [showClear]=\"true\"\n [(ngModel)]=\"status\"\n (onChange)=\"filterByStatus($event.value)\"\n appendTo=\"body\">\n </p-select>\n </div>\n <!-- No ngModel — onLazyLoad is the single writer of searchText. -->\n <div class=\"text-end\">\n <label for=\"flows-workflows-search\"\n class=\"visually-hidden\">{{ 'Flows.Workflows.Filter.SearchLabel' | transloco }}</label>\n <p-iconfield iconPosition=\"left\">\n <p-inputicon><fa-icon [icon]=\"icons.search\"\n aria-hidden=\"true\"></fa-icon></p-inputicon>\n <input #searchInput\n type=\"text\"\n id=\"flows-workflows-search\"\n name=\"flows-workflows-search\"\n pInputText\n [placeholder]=\"'Flows.Workflows.Filter.Search' | transloco\"\n (input)=\"dt.filterGlobal(searchInput.value, 'contains')\" />\n </p-iconfield>\n </div>\n </div>\n </ng-template>\n\n <ng-template #header>\n <tr>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Name' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Description' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Status' | transloco }}</th>\n <th scope=\"col\">{{ 'Flows.Workflows.Column.Created' | transloco }}</th>\n <th scope=\"col\"\n class=\"actions-list-three\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n\n <ng-template #body\n let-workflow>\n <tr>\n <td data-head=\"Name\">{{ workflow.name }}</td>\n <td data-head=\"Description\">{{ workflow.description || '—' }}</td>\n <td data-head=\"Status\">\n <span [class]=\"badgeClass(workflow.status)\">\n {{ 'Flows.WorkflowStatus.' + workflow.status | transloco }}\n </span>\n </td>\n <td data-head=\"Created\">{{ workflow.created_at | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li [pTooltip]=\"'Flows.Workflows.Action.Versions' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"cta1-icon\"\n [icon]=\"icons.versions\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Workflows.Action.Versions' | transloco\"\n (click)=\"openVersions(workflow)\"\n (keydown.enter)=\"openVersions(workflow)\"></fa-icon>\n </li>\n <li [pTooltip]=\"'Flows.Workflows.Action.Edit' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"edit-icon\"\n [icon]=\"icons.edit\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Workflows.Action.Edit' | transloco\"\n (click)=\"editWorkflow(workflow)\"\n (keydown.enter)=\"editWorkflow(workflow)\"></fa-icon>\n </li>\n <li [pTooltip]=\"'Flows.Workflows.Action.Delete' | transloco\"\n tooltipPosition=\"top\"\n appendTo=\"body\">\n <fa-icon class=\"delete-icon\"\n [icon]=\"icons.delete\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-label]=\"'Flows.Workflows.Action.Delete' | transloco\"\n (click)=\"deleteWorkflow(workflow)\"\n (keydown.enter)=\"deleteWorkflow(workflow)\"></fa-icon>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n\n <pw-records-summary [showing]=\"workflows.length\"\n [total]=\"totalRecords\" />\n</div>\n} @else {\n<pw-no-data [withImage]=\"true\" [message]=\"'Flows.Workflows.Empty' | transloco\" [description]=\"'Flows.Workflows.EmptyDescription' | transloco\"></pw-no-data>\n}\n}\n",
|
|
5705
6747
|
styles: [".pw-flow-badge{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:2px 8px;border-radius:4px;letter-spacing:.01em;white-space:nowrap}.pw-flow-badge:before{content:\"\";width:6px;height:6px;border-radius:50%;background-color:currentColor;flex:0 0 auto}.pw-flow-badge--success{background-color:#e6f4ec;color:#0f6b3a}.pw-flow-badge--danger{background-color:#fbeae8;color:#c0392b}.pw-flow-badge--warning{background-color:#fbf1e3;color:#8a5a00}.pw-flow-badge--info{background-color:#e6f3f6;color:#1f6378}.pw-flow-badge--muted{background-color:#eef0f3;color:#5a6473}td[data-head=Run],td[data-head=Workflow],td[data-head=Version],td[data-head=Attempts],td[data-head=Duration]{color:#5a6473;font-variant-numeric:tabular-nums;white-space:nowrap}td[data-head=Node]{min-width:180px;font-weight:600;color:#1a1d21;overflow-wrap:anywhere}.primeng-datatable-container table tbody tr:hover{background-color:#f5f7fa}.primeng-datatable-container td[data-head=Name]{min-width:200px;font-weight:600;color:#1a1d21}.primeng-datatable-container td[data-head=Description]{min-width:220px;color:#5a6473}\n"]
|
|
5706
6748
|
}]
|
|
5707
6749
|
}],
|
|
5708
6750
|
ctorParameters: () => [
|
|
5709
6751
|
{ type: i0.Injector },
|
|
5710
6752
|
{ type: FlowsWorkflowService },
|
|
5711
|
-
{ type:
|
|
6753
|
+
{ type: i6.ConfirmDialogService },
|
|
5712
6754
|
{ type: i0.ChangeDetectorRef }
|
|
5713
6755
|
]
|
|
5714
6756
|
});
|
|
@@ -5770,7 +6812,7 @@ var FlowsPrivateRoutingModule = class FlowsPrivateRoutingModule {
|
|
|
5770
6812
|
version: "22.2.0",
|
|
5771
6813
|
ngImport: i0,
|
|
5772
6814
|
type: FlowsPrivateRoutingModule,
|
|
5773
|
-
imports: [
|
|
6815
|
+
imports: [i8.RouterModule],
|
|
5774
6816
|
exports: [RouterModule]
|
|
5775
6817
|
});
|
|
5776
6818
|
}
|
|
@@ -5820,11 +6862,14 @@ var FlowsPrivateModule = class FlowsPrivateModule {
|
|
|
5820
6862
|
FlowsWorkflowFormComponent,
|
|
5821
6863
|
FlowsWorkflowVersionsComponent,
|
|
5822
6864
|
FlowsVersionEditorComponent,
|
|
6865
|
+
FlowsGraphCheckComponent,
|
|
5823
6866
|
FlowsRunsComponent,
|
|
5824
6867
|
FlowsRunsFiltersComponent,
|
|
5825
6868
|
FlowsCronFieldComponent,
|
|
5826
6869
|
FlowsTimezoneFieldComponent,
|
|
5827
6870
|
FlowsRunInspectorComponent,
|
|
6871
|
+
FlowsRunProgressComponent,
|
|
6872
|
+
FlowsStepErrorComponent,
|
|
5828
6873
|
FlowsGraphCanvasComponent,
|
|
5829
6874
|
FlowsCanvasNodeComponent,
|
|
5830
6875
|
FlowsCanvasSocketComponent,
|
|
@@ -5834,7 +6879,9 @@ var FlowsPrivateModule = class FlowsPrivateModule {
|
|
|
5834
6879
|
FlowsJsonFieldComponent,
|
|
5835
6880
|
FlowsConditionFieldComponent,
|
|
5836
6881
|
FlowsPairsFieldComponent,
|
|
5837
|
-
FlowsMemberFieldComponent
|
|
6882
|
+
FlowsMemberFieldComponent,
|
|
6883
|
+
FlowsRetryFieldComponent,
|
|
6884
|
+
FlowsAvailableFieldsComponent
|
|
5838
6885
|
],
|
|
5839
6886
|
imports: [
|
|
5840
6887
|
CommonModule,
|
|
@@ -5844,6 +6891,7 @@ var FlowsPrivateModule = class FlowsPrivateModule {
|
|
|
5844
6891
|
CoreTranslocoModule,
|
|
5845
6892
|
AppLoaderModule,
|
|
5846
6893
|
SharedComponentsModule,
|
|
6894
|
+
PipesModule,
|
|
5847
6895
|
FontAwesomeModule,
|
|
5848
6896
|
IconFieldModule,
|
|
5849
6897
|
InputIconModule,
|
|
@@ -5874,6 +6922,7 @@ var FlowsPrivateModule = class FlowsPrivateModule {
|
|
|
5874
6922
|
CoreTranslocoModule,
|
|
5875
6923
|
AppLoaderModule,
|
|
5876
6924
|
SharedComponentsModule,
|
|
6925
|
+
PipesModule,
|
|
5877
6926
|
FontAwesomeModule,
|
|
5878
6927
|
IconFieldModule,
|
|
5879
6928
|
InputIconModule,
|
|
@@ -5901,6 +6950,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
5901
6950
|
CoreTranslocoModule,
|
|
5902
6951
|
AppLoaderModule,
|
|
5903
6952
|
SharedComponentsModule,
|
|
6953
|
+
PipesModule,
|
|
5904
6954
|
FontAwesomeModule,
|
|
5905
6955
|
IconFieldModule,
|
|
5906
6956
|
InputIconModule,
|
|
@@ -5922,11 +6972,14 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
5922
6972
|
FlowsWorkflowFormComponent,
|
|
5923
6973
|
FlowsWorkflowVersionsComponent,
|
|
5924
6974
|
FlowsVersionEditorComponent,
|
|
6975
|
+
FlowsGraphCheckComponent,
|
|
5925
6976
|
FlowsRunsComponent,
|
|
5926
6977
|
FlowsRunsFiltersComponent,
|
|
5927
6978
|
FlowsCronFieldComponent,
|
|
5928
6979
|
FlowsTimezoneFieldComponent,
|
|
5929
6980
|
FlowsRunInspectorComponent,
|
|
6981
|
+
FlowsRunProgressComponent,
|
|
6982
|
+
FlowsStepErrorComponent,
|
|
5930
6983
|
FlowsGraphCanvasComponent,
|
|
5931
6984
|
FlowsCanvasNodeComponent,
|
|
5932
6985
|
FlowsCanvasSocketComponent,
|
|
@@ -5936,7 +6989,9 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
5936
6989
|
FlowsJsonFieldComponent,
|
|
5937
6990
|
FlowsConditionFieldComponent,
|
|
5938
6991
|
FlowsPairsFieldComponent,
|
|
5939
|
-
FlowsMemberFieldComponent
|
|
6992
|
+
FlowsMemberFieldComponent,
|
|
6993
|
+
FlowsRetryFieldComponent,
|
|
6994
|
+
FlowsAvailableFieldsComponent
|
|
5940
6995
|
]
|
|
5941
6996
|
}]
|
|
5942
6997
|
}]
|