@valtimo/decision 13.24.0 → 13.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/valtimo-decision.mjs +241 -97
- package/fesm2022/valtimo-decision.mjs.map +1 -1
- package/lib/constants/decision.test-ids.d.ts +11 -0
- package/lib/constants/decision.test-ids.d.ts.map +1 -0
- package/lib/constants/index.d.ts +2 -0
- package/lib/constants/index.d.ts.map +1 -0
- package/lib/decision-deploy/decision-deploy.component.d.ts +4 -0
- package/lib/decision-deploy/decision-deploy.component.d.ts.map +1 -1
- package/lib/decision-list/decision-list.component.d.ts +5 -1
- package/lib/decision-list/decision-list.component.d.ts.map +1 -1
- package/lib/decision-modeler/decision-modeler.component.d.ts +7 -1
- package/lib/decision-modeler/decision-modeler.component.d.ts.map +1 -1
- package/lib/services/decision.service.d.ts +5 -0
- package/lib/services/decision.service.d.ts.map +1 -1
- package/lib/utils/decision.utils.d.ts +3 -0
- package/lib/utils/decision.utils.d.ts.map +1 -0
- package/package.json +1 -1
- package/public-api.d.ts +3 -0
- package/public-api.d.ts.map +1 -1
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, Component, ViewEncapsulation, EventEmitter, Output, ViewChild, NgModule } from '@angular/core';
|
|
3
|
+
import { Subject, startWith, BehaviorSubject, map, combineLatest, switchMap, tap, filter, take, from, of, catchError } from 'rxjs';
|
|
4
|
+
import * as i1 from '@angular/common/http';
|
|
5
|
+
import { HttpHeaders } from '@angular/common/http';
|
|
6
|
+
import * as i6 from '@valtimo/shared';
|
|
7
|
+
import { BaseApiService, InterceptorSkip, getCaseManagementRouteParams, getBuildingBlockManagementRouteParams, getContextObservable, ROLE_ADMIN } from '@valtimo/shared';
|
|
3
8
|
import * as i2 from '@angular/router';
|
|
4
9
|
import { RouterModule } from '@angular/router';
|
|
5
10
|
import * as i7 from '@angular/common';
|
|
6
11
|
import { CommonModule } from '@angular/common';
|
|
7
12
|
import { AuthGuardService } from '@valtimo/security';
|
|
8
|
-
import * as i6 from '@valtimo/shared';
|
|
9
|
-
import { BaseApiService, InterceptorSkip, getCaseManagementRouteParams, getContextObservable, ROLE_ADMIN } from '@valtimo/shared';
|
|
10
13
|
import DmnJS from 'dmn-js/dist/dmn-modeler.development.js';
|
|
11
14
|
import { migrateDiagram } from '@bpmn-io/dmn-migrate';
|
|
12
|
-
import { BehaviorSubject, map, combineLatest, switchMap, tap, filter, take, from, of, catchError, Subject, startWith } from 'rxjs';
|
|
13
15
|
import * as i4 from '@valtimo/components';
|
|
14
16
|
import { PendingChangesComponent, WidgetModule, SelectModule as SelectModule$1, RenderInPageHeaderDirective, FitPageDirective, OverflowMenuComponent, OverflowMenuOptionComponent, OverflowMenuTriggerComponent, CarbonListModule, ModalModule as ModalModule$1, SpinnerModule } from '@valtimo/components';
|
|
15
17
|
import * as i3 from '@ngx-translate/core';
|
|
@@ -17,8 +19,6 @@ import { TranslateModule } from '@ngx-translate/core';
|
|
|
17
19
|
import * as i6$1 from 'carbon-components-angular';
|
|
18
20
|
import { ModalModule, SelectModule, ButtonModule, IconModule, LayerModule, FileUploaderModule } from 'carbon-components-angular';
|
|
19
21
|
import { Deploy16, Download16, ArrowLeft16, Upload16 } from '@carbon/icons';
|
|
20
|
-
import * as i1 from '@angular/common/http';
|
|
21
|
-
import { HttpHeaders } from '@angular/common/http';
|
|
22
22
|
import DmnViewer from 'dmn-js';
|
|
23
23
|
import * as i3$1 from '@angular/forms';
|
|
24
24
|
import { Validators, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
@@ -86,33 +86,28 @@ import { Validators, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
|
86
86
|
* See the License for the specific language governing permissions and
|
|
87
87
|
* limitations under the License.
|
|
88
88
|
*/
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
</dmndi:DMNDiagram>
|
|
109
|
-
</dmndi:DMNDI>
|
|
110
|
-
</definitions>
|
|
111
|
-
`,
|
|
112
|
-
};
|
|
89
|
+
class DecisionStateService {
|
|
90
|
+
constructor() {
|
|
91
|
+
this._refreshDecisions$ = new Subject();
|
|
92
|
+
}
|
|
93
|
+
get refreshDecisions$() {
|
|
94
|
+
return this._refreshDecisions$.asObservable().pipe(startWith(null));
|
|
95
|
+
}
|
|
96
|
+
refreshDecisions() {
|
|
97
|
+
this._refreshDecisions$.next(null);
|
|
98
|
+
}
|
|
99
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionStateService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
100
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionStateService, providedIn: 'root' }); }
|
|
101
|
+
}
|
|
102
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionStateService, decorators: [{
|
|
103
|
+
type: Injectable,
|
|
104
|
+
args: [{
|
|
105
|
+
providedIn: 'root',
|
|
106
|
+
}]
|
|
107
|
+
}] });
|
|
113
108
|
|
|
114
109
|
/*
|
|
115
|
-
* Copyright 2015-
|
|
110
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
116
111
|
*
|
|
117
112
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
118
113
|
* you may not use this file except in compliance with the License.
|
|
@@ -164,6 +159,19 @@ class DecisionService extends BaseApiService {
|
|
|
164
159
|
deleteCaseDecisionDefinition(caseDefinitionKey, versionTag, decisionDefinitionKey) {
|
|
165
160
|
return this.httpClient.delete(this.getApiUrl(`/management/v1/case-definition/${caseDefinitionKey}/version/${versionTag}/decision-definition/${decisionDefinitionKey}`));
|
|
166
161
|
}
|
|
162
|
+
listBuildingBlockDecisionDefinitions(key, versionTag) {
|
|
163
|
+
return this.httpClient.get(this.getApiUrl(`/management/v1/building-block/${key}/version/${versionTag}/decision-definition`));
|
|
164
|
+
}
|
|
165
|
+
deployBuildingBlockDecisionDefinition(key, versionTag, dmn) {
|
|
166
|
+
const formData = new FormData();
|
|
167
|
+
formData.append('file', dmn);
|
|
168
|
+
return this.httpClient.post(this.getApiUrl(`/management/v1/building-block/${key}/version/${versionTag}/decision-definition`), formData, {
|
|
169
|
+
headers: new HttpHeaders().set(InterceptorSkip, '204'),
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
deleteBuildingBlockDecisionDefinition(key, versionTag, decisionDefinitionKey) {
|
|
173
|
+
return this.httpClient.delete(this.getApiUrl(`/management/v1/building-block/${key}/version/${versionTag}/decision-definition/${decisionDefinitionKey}`));
|
|
174
|
+
}
|
|
167
175
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionService, deps: [{ token: i1.HttpClient }, { token: i6.ConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
168
176
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionService, providedIn: 'root' }); }
|
|
169
177
|
}
|
|
@@ -174,6 +182,119 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
174
182
|
}]
|
|
175
183
|
}], ctorParameters: () => [{ type: i1.HttpClient }, { type: i6.ConfigService }] });
|
|
176
184
|
|
|
185
|
+
/*
|
|
186
|
+
* Copyright 2015-2025 Ritense BV, the Netherlands.
|
|
187
|
+
*
|
|
188
|
+
* Licensed under EUPL, Version 1.2 (the "License");
|
|
189
|
+
* you may not use this file except in compliance with the License.
|
|
190
|
+
* You may obtain a copy of the License at
|
|
191
|
+
*
|
|
192
|
+
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
193
|
+
*
|
|
194
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
195
|
+
* distributed under the License is distributed on an "AS IS" basis,
|
|
196
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
197
|
+
* See the License for the specific language governing permissions and
|
|
198
|
+
* limitations under the License.
|
|
199
|
+
*/
|
|
200
|
+
|
|
201
|
+
/*
|
|
202
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
203
|
+
*
|
|
204
|
+
* Licensed under EUPL, Version 1.2 (the "License");
|
|
205
|
+
* you may not use this file except in compliance with the License.
|
|
206
|
+
* You may obtain a copy of the License at
|
|
207
|
+
*
|
|
208
|
+
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
209
|
+
*
|
|
210
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
211
|
+
* distributed under the License is distributed on an "AS IS" basis,
|
|
212
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
213
|
+
* See the License for the specific language governing permissions and
|
|
214
|
+
* limitations under the License.
|
|
215
|
+
*/
|
|
216
|
+
const DECISION_LIST_TEST_IDS = {
|
|
217
|
+
uploadButton: 'decisionListUploadButton',
|
|
218
|
+
};
|
|
219
|
+
const DECISION_UPLOAD_TEST_IDS = {
|
|
220
|
+
submitButton: 'decisionUploadModalSubmitButton',
|
|
221
|
+
};
|
|
222
|
+
const DECISION_MODELER_TEST_IDS = {
|
|
223
|
+
deployButton: 'decisionModelerDeployButton',
|
|
224
|
+
backButton: 'decisionModelerBackButton',
|
|
225
|
+
};
|
|
226
|
+
|
|
227
|
+
/*
|
|
228
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
229
|
+
*
|
|
230
|
+
* Licensed under EUPL, Version 1.2 (the "License");
|
|
231
|
+
* you may not use this file except in compliance with the License.
|
|
232
|
+
* You may obtain a copy of the License at
|
|
233
|
+
*
|
|
234
|
+
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
235
|
+
*
|
|
236
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
237
|
+
* distributed under the License is distributed on an "AS IS" basis,
|
|
238
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
239
|
+
* See the License for the specific language governing permissions and
|
|
240
|
+
* limitations under the License.
|
|
241
|
+
*/
|
|
242
|
+
|
|
243
|
+
/*
|
|
244
|
+
* Copyright 2015-2025 Ritense BV, the Netherlands.
|
|
245
|
+
*
|
|
246
|
+
* Licensed under EUPL, Version 1.2 (the "License");
|
|
247
|
+
* you may not use this file except in compliance with the License.
|
|
248
|
+
* You may obtain a copy of the License at
|
|
249
|
+
*
|
|
250
|
+
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
251
|
+
*
|
|
252
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
253
|
+
* distributed under the License is distributed on an "AS IS" basis,
|
|
254
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
255
|
+
* See the License for the specific language governing permissions and
|
|
256
|
+
* limitations under the License.
|
|
257
|
+
*/
|
|
258
|
+
const EMPTY_DECISION = {
|
|
259
|
+
id: '',
|
|
260
|
+
dmnXml: `<?xml version="1.0" encoding="UTF-8"?>
|
|
261
|
+
<definitions xmlns="https://www.omg.org/spec/DMN/20191111/MODEL/" xmlns:dmndi="https://www.omg.org/spec/DMN/20191111/DMNDI/" xmlns:dc="http://www.omg.org/spec/DMN/20180521/DC/" id="Definitions_1h198v9" name="DRD" namespace="http://camunda.org/schema/1.0/dmn" xmlns:modeler="http://camunda.org/schema/modeler/1.0" exporter="Camunda Modeler" exporterVersion="5.2.0" modeler:executionPlatform="Camunda Cloud" modeler:executionPlatformVersion="8.0.0">
|
|
262
|
+
<decision id="Decision_1e18q76" name="Decision 1">
|
|
263
|
+
<decisionTable id="DecisionTable_1apu23m">
|
|
264
|
+
<input id="Input_1">
|
|
265
|
+
<inputExpression id="InputExpression_1" typeRef="string">
|
|
266
|
+
<text></text>
|
|
267
|
+
</inputExpression>
|
|
268
|
+
</input>
|
|
269
|
+
<output id="Output_1" typeRef="string" />
|
|
270
|
+
</decisionTable>
|
|
271
|
+
</decision>
|
|
272
|
+
<dmndi:DMNDI>
|
|
273
|
+
<dmndi:DMNDiagram>
|
|
274
|
+
<dmndi:DMNShape dmnElementRef="Decision_1e18q76">
|
|
275
|
+
<dc:Bounds height="80" width="180" x="160" y="100" />
|
|
276
|
+
</dmndi:DMNShape>
|
|
277
|
+
</dmndi:DMNDiagram>
|
|
278
|
+
</dmndi:DMNDI>
|
|
279
|
+
</definitions>
|
|
280
|
+
`,
|
|
281
|
+
};
|
|
282
|
+
|
|
283
|
+
/*
|
|
284
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
285
|
+
*
|
|
286
|
+
* Licensed under EUPL, Version 1.2 (the "License");
|
|
287
|
+
* you may not use this file except in compliance with the License.
|
|
288
|
+
* You may obtain a copy of the License at
|
|
289
|
+
*
|
|
290
|
+
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
291
|
+
*
|
|
292
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
293
|
+
* distributed under the License is distributed on an "AS IS" basis,
|
|
294
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
295
|
+
* See the License for the specific language governing permissions and
|
|
296
|
+
* limitations under the License.
|
|
297
|
+
*/
|
|
177
298
|
class DecisionModelerComponent extends PendingChangesComponent {
|
|
178
299
|
constructor(decisionService, route, router, translateService, pageTitleService, breadcrumbService, iconService, pageHeaderService, notificationService, editPermissionsService) {
|
|
179
300
|
super();
|
|
@@ -192,10 +313,12 @@ class DecisionModelerComponent extends PendingChangesComponent {
|
|
|
192
313
|
decisionTable: 'dmn-icon-decision-table',
|
|
193
314
|
literalExpression: 'dmn-icon-literal-expression',
|
|
194
315
|
};
|
|
316
|
+
this.testIds = DECISION_MODELER_TEST_IDS;
|
|
195
317
|
this.versionSelectionDisabled$ = new BehaviorSubject(true);
|
|
196
318
|
this.isCreating$ = new BehaviorSubject(false);
|
|
197
319
|
this.selectionId$ = new BehaviorSubject('');
|
|
198
320
|
this.caseManagementRouteParams$ = getCaseManagementRouteParams(this.route);
|
|
321
|
+
this.buildingBlockManagementRouteParams$ = getBuildingBlockManagementRouteParams(this.route);
|
|
199
322
|
this.context$ = getContextObservable(this.route);
|
|
200
323
|
this.isIndependent$ = this.context$.pipe(map(context => context === 'independent'));
|
|
201
324
|
this.compactMode$ = this.pageHeaderService.compactMode$;
|
|
@@ -226,17 +349,28 @@ class DecisionModelerComponent extends PendingChangesComponent {
|
|
|
226
349
|
}
|
|
227
350
|
ngOnDestroy() {
|
|
228
351
|
this.pageTitleService.enableReset();
|
|
352
|
+
this.breadcrumbService.clearThirdBreadcrumb();
|
|
353
|
+
this.breadcrumbService.clearFourthBreadcrumb();
|
|
229
354
|
}
|
|
230
355
|
ngAfterViewInit() {
|
|
231
356
|
this.setProperties();
|
|
232
357
|
this.setTabEvents();
|
|
233
358
|
this.setModelerEvents();
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
.subscribe(([params, context]) => {
|
|
237
|
-
if (!params || !context)
|
|
359
|
+
this.context$.pipe(take(1)).subscribe(context => {
|
|
360
|
+
if (!context)
|
|
238
361
|
return;
|
|
239
|
-
|
|
362
|
+
if (context === 'buildingBlock') {
|
|
363
|
+
this.buildingBlockManagementRouteParams$.pipe(take(1)).subscribe(params => {
|
|
364
|
+
if (params)
|
|
365
|
+
this.initBuildingBlockBreadcrumbs(params);
|
|
366
|
+
});
|
|
367
|
+
}
|
|
368
|
+
else {
|
|
369
|
+
this.caseManagementRouteParams$.pipe(take(1)).subscribe(params => {
|
|
370
|
+
if (params)
|
|
371
|
+
this.initBreadcrumbs(params, context);
|
|
372
|
+
});
|
|
373
|
+
}
|
|
240
374
|
});
|
|
241
375
|
}
|
|
242
376
|
switchVersion(decisionId) {
|
|
@@ -247,9 +381,15 @@ class DecisionModelerComponent extends PendingChangesComponent {
|
|
|
247
381
|
}
|
|
248
382
|
deploy() {
|
|
249
383
|
from(this.dmnModeler.saveXML({ format: true }))
|
|
250
|
-
.pipe(map(result => new File([result.xml], this._fileName, { type: 'text/xml' })), switchMap(file => combineLatest([of(file), this.context$])), switchMap(([file, context]) =>
|
|
251
|
-
|
|
252
|
-
|
|
384
|
+
.pipe(map(result => new File([result.xml], this._fileName, { type: 'text/xml' })), switchMap(file => combineLatest([of(file), this.context$])), switchMap(([file, context]) => {
|
|
385
|
+
if (context === 'independent') {
|
|
386
|
+
return this.decisionService.deployDmn(file);
|
|
387
|
+
}
|
|
388
|
+
if (context === 'buildingBlock') {
|
|
389
|
+
return this.buildingBlockManagementRouteParams$.pipe(switchMap(params => this.decisionService.deployBuildingBlockDecisionDefinition(params?.buildingBlockDefinitionKey ?? '', params?.buildingBlockDefinitionVersionTag ?? '', file)));
|
|
390
|
+
}
|
|
391
|
+
return this.caseManagementRouteParams$.pipe(switchMap(params => this.decisionService.deployCaseDecisionDefinition(params?.caseDefinitionKey ?? '', params?.caseDefinitionVersionTag ?? '', file)));
|
|
392
|
+
}), tap((res) => {
|
|
253
393
|
this.switchVersion(res.identifier);
|
|
254
394
|
this.showNotification('success', 'decisions.deploySuccess');
|
|
255
395
|
}), catchError(() => {
|
|
@@ -363,8 +503,23 @@ class DecisionModelerComponent extends PendingChangesComponent {
|
|
|
363
503
|
href: routeWithDecisions,
|
|
364
504
|
});
|
|
365
505
|
}
|
|
506
|
+
initBuildingBlockBreadcrumbs(params) {
|
|
507
|
+
const route = `/building-block-management/building-block/${params.buildingBlockDefinitionKey}/version/${params.buildingBlockDefinitionVersionTag}`;
|
|
508
|
+
const generalRoute = `${route}/general`;
|
|
509
|
+
this.breadcrumbService.setThirdBreadcrumb({
|
|
510
|
+
route: [generalRoute],
|
|
511
|
+
content: `${params.buildingBlockDefinitionKey} (${params.buildingBlockDefinitionVersionTag})`,
|
|
512
|
+
href: generalRoute,
|
|
513
|
+
});
|
|
514
|
+
const routeWithDecisions = `${route}/decisions`;
|
|
515
|
+
this.breadcrumbService.setFourthBreadcrumb({
|
|
516
|
+
route: [routeWithDecisions],
|
|
517
|
+
content: this.translateService.instant('buildingBlockManagement.tabs.decisions'),
|
|
518
|
+
href: routeWithDecisions,
|
|
519
|
+
});
|
|
520
|
+
}
|
|
366
521
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionModelerComponent, deps: [{ token: DecisionService }, { token: i2.ActivatedRoute }, { token: i2.Router }, { token: i3.TranslateService }, { token: i4.PageTitleService }, { token: i4.BreadcrumbService }, { token: i6$1.IconService }, { token: i4.PageHeaderService }, { token: i6.GlobalNotificationService }, { token: i6.EditPermissionsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
367
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.20", type: DecisionModelerComponent, isStandalone: true, selector: "valtimo-decision-modeler", usesInheritance: true, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n decisionXml: decisionXml$ | async,\n decisionTitle: decisionTitle$ | async,\n } as obs\"\n fitPage\n [disableOverflow]=\"true\"\n class=\"dmn-editor\"\n>\n <ng-container *ngTemplateOutlet=\"diagram\"></ng-container>\n</div>\n\n<ng-template #diagram>\n <div class=\"editor-parent\">\n <div class=\"editor-container\"></div>\n <div class=\"editor-tabs\"></div>\n </div>\n</ng-template>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div\n *ngIf=\"{\n selectionId: selectionId$ | async,\n isCreating: isCreating$ | async,\n context: context$ | async,\n compactMode: compactMode$ | async,\n hasEditPermissions: hasEditPermissions$ | async,\n } as obs\"\n class=\"decision-modeler-actions\"\n >\n <ng-container *ngTemplateOutlet=\"versionSelection\"></ng-container>\n\n <button\n *ngIf=\"obs.context === 'case'\"\n cdsButton=\"secondary\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n (click)=\"navigateBack(null)\"\n >\n <svg class=\"cds--btn__icon\" cdsIcon=\"arrow--left\" size=\"16\"></svg>\n\n <span>{{ 'interface.back' | translate }}</span>\n </button>\n\n @if (obs.selectionId && !obs.isCreating) {\n <button\n *ngIf=\"obs.hasEditPermissions\"\n cdsButton=\"primary\"\n (click)=\"deploy()\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n >\n {{ 'decisions.deploy' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"deploy\" size=\"16\"></svg>\n </button>\n\n <v-overflow-menu class=\"overflow-button\" placement=\"bottom-end\">\n <v-overflow-menu-trigger overflowTrigger></v-overflow-menu-trigger>\n <v-overflow-menu-option (selected)=\"download()\"\n >{{ 'interface.export' | translate }}\n </v-overflow-menu-option>\n </v-overflow-menu>\n } @else {\n <button class=\"btn btn-success btn-space\" (click)=\"deploy()\">\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'decisions.deploy' | translate }}\n </button>\n }\n </div>\n </ng-template>\n</ng-container>\n\n<ng-template #versionSelection>\n <ng-container\n *ngIf=\"{\n selectItems: (decisionVersionSelectItems$ | async) || [],\n isIndependent: isIndependent$ | async,\n versionSelectionDisabled: versionSelectionDisabled$ | async,\n selectionId: selectionId$ | async,\n } as obs\"\n >\n <v-select\n *ngIf=\"obs.isIndependent\"\n name=\"version\"\n [title]=\"'decisions.version' | translate\"\n [disabled]=\"obs.versionSelectionDisabled\"\n [clearable]=\"false\"\n [loading]=\"obs.selectItems.length === 0\"\n [items]=\"obs.selectItems\"\n [defaultSelectionId]=\"obs.selectionId\"\n [widthInPx]=\"120\"\n (selectedChange)=\"switchVersion($event)\"\n ></v-select>\n </ng-container>\n</ng-template>\n", styles: ["#save-button{position:absolute;bottom:10px;left:10px;background:#fff;border:solid 1px #ccc;border-radius:2px;padding:8px;font-family:Arial,sans-serif;font-weight:700;cursor:default;font-size:14px;color:#444}.dmn-modeler{display:flex;flex-direction:column;width:100%;padding:1rem}.diagram,.diagram-header{border:1px solid #dee2e6}.decision-title{color:#6b6b6b;font-size:1.5rem;margin:0}.fullscreen-toggle{font-size:2rem}.fullscreen-toggle>i{cursor:pointer}.dmn-editor{background-color:var(--cds-layer);outline:1px solid var(--cds-border-subtle);outline-offset:-1px;padding:16px}.decision-modeler-actions{display:flex;width:100%;justify-content:flex-end;align-items:flex-end;gap:16px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i7.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i7.AsyncPipe, name: "async" }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: ModalModule }, { kind: "ngmodule", type: SelectModule }, { kind: "ngmodule", type: WidgetModule }, { kind: "ngmodule", type: SelectModule$1 }, { kind: "component", type: i4.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "invalid", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "clearable", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "warn", "warnText", "dataTestId"], outputs: ["selectedChange"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3.TranslatePipe, name: "translate" }, { kind: "directive", type: RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i6$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i6$1.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "directive", type: FitPageDirective, selector: "[fitPage]", inputs: ["spaceAdjustment", "fitPageDisabled", "disableOverflow"] }, { kind: "component", type: OverflowMenuComponent, selector: "v-overflow-menu", inputs: ["open", "placement", "menuWidth", "offsetX", "offsetY", "closeOnSelect", "useHostAsReference", "portalToBody"], outputs: ["openChange"] }, { kind: "component", type: OverflowMenuOptionComponent, selector: "v-overflow-menu-option", inputs: ["disabled", "type", "testId", "optionId"], outputs: ["selected"] }, { kind: "component", type: OverflowMenuTriggerComponent, selector: "v-overflow-menu-trigger", inputs: ["compact"] }] }); }
|
|
522
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.20", type: DecisionModelerComponent, isStandalone: true, selector: "valtimo-decision-modeler", usesInheritance: true, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n decisionXml: decisionXml$ | async,\n decisionTitle: decisionTitle$ | async,\n } as obs\"\n fitPage\n [disableOverflow]=\"true\"\n class=\"dmn-editor\"\n>\n <ng-container *ngTemplateOutlet=\"diagram\"></ng-container>\n</div>\n\n<ng-template #diagram>\n <div class=\"editor-parent\">\n <div class=\"editor-container\"></div>\n <div class=\"editor-tabs\"></div>\n </div>\n</ng-template>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div\n *ngIf=\"{\n selectionId: selectionId$ | async,\n isCreating: isCreating$ | async,\n context: context$ | async,\n compactMode: compactMode$ | async,\n hasEditPermissions: hasEditPermissions$ | async,\n } as obs\"\n class=\"decision-modeler-actions\"\n >\n <ng-container *ngTemplateOutlet=\"versionSelection\"></ng-container>\n\n <button\n *ngIf=\"obs.context === 'case'\"\n cdsButton=\"secondary\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n (click)=\"navigateBack(null)\"\n [attr.data-test-id]=\"testIds.backButton\"\n >\n <svg class=\"cds--btn__icon\" cdsIcon=\"arrow--left\" size=\"16\"></svg>\n\n <span>{{ 'interface.back' | translate }}</span>\n </button>\n\n @if (obs.selectionId && !obs.isCreating) {\n <button\n *ngIf=\"obs.hasEditPermissions\"\n cdsButton=\"primary\"\n (click)=\"deploy()\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n [attr.data-test-id]=\"testIds.deployButton\"\n >\n {{ 'decisions.deploy' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"deploy\" size=\"16\"></svg>\n </button>\n\n <v-overflow-menu class=\"overflow-button\" placement=\"bottom-end\">\n <v-overflow-menu-trigger overflowTrigger></v-overflow-menu-trigger>\n <v-overflow-menu-option (selected)=\"download()\"\n >{{ 'interface.export' | translate }}\n </v-overflow-menu-option>\n </v-overflow-menu>\n } @else {\n <button class=\"btn btn-success btn-space\" (click)=\"deploy()\">\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'decisions.deploy' | translate }}\n </button>\n }\n </div>\n </ng-template>\n</ng-container>\n\n<ng-template #versionSelection>\n <ng-container\n *ngIf=\"{\n selectItems: (decisionVersionSelectItems$ | async) || [],\n isIndependent: isIndependent$ | async,\n versionSelectionDisabled: versionSelectionDisabled$ | async,\n selectionId: selectionId$ | async,\n } as obs\"\n >\n <v-select\n *ngIf=\"obs.isIndependent\"\n name=\"version\"\n [title]=\"'decisions.version' | translate\"\n [disabled]=\"obs.versionSelectionDisabled\"\n [clearable]=\"false\"\n [loading]=\"obs.selectItems.length === 0\"\n [items]=\"obs.selectItems\"\n [defaultSelectionId]=\"obs.selectionId\"\n [widthInPx]=\"120\"\n (selectedChange)=\"switchVersion($event)\"\n ></v-select>\n </ng-container>\n</ng-template>\n", styles: ["#save-button{position:absolute;bottom:10px;left:10px;background:#fff;border:solid 1px #ccc;border-radius:2px;padding:8px;font-family:Arial,sans-serif;font-weight:700;cursor:default;font-size:14px;color:#444}.dmn-modeler{display:flex;flex-direction:column;width:100%;padding:1rem}.diagram,.diagram-header{border:1px solid #dee2e6}.decision-title{color:#6b6b6b;font-size:1.5rem;margin:0}.fullscreen-toggle{font-size:2rem}.fullscreen-toggle>i{cursor:pointer}.dmn-editor{background-color:var(--cds-layer);outline:1px solid var(--cds-border-subtle);outline-offset:-1px;padding:16px}.decision-modeler-actions{display:flex;width:100%;justify-content:flex-end;align-items:flex-end;gap:16px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i7.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i7.AsyncPipe, name: "async" }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: ModalModule }, { kind: "ngmodule", type: SelectModule }, { kind: "ngmodule", type: WidgetModule }, { kind: "ngmodule", type: SelectModule$1 }, { kind: "component", type: i4.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "invalid", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "clearable", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "warn", "warnText", "dataTestId"], outputs: ["selectedChange"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3.TranslatePipe, name: "translate" }, { kind: "directive", type: RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i6$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i6$1.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "directive", type: FitPageDirective, selector: "[fitPage]", inputs: ["spaceAdjustment", "fitPageDisabled", "disableOverflow"] }, { kind: "component", type: OverflowMenuComponent, selector: "v-overflow-menu", inputs: ["open", "placement", "menuWidth", "offsetX", "offsetY", "closeOnSelect", "useHostAsReference", "portalToBody"], outputs: ["openChange"] }, { kind: "component", type: OverflowMenuOptionComponent, selector: "v-overflow-menu-option", inputs: ["disabled", "type", "testId", "optionId"], outputs: ["selected"] }, { kind: "component", type: OverflowMenuTriggerComponent, selector: "v-overflow-menu-trigger", inputs: ["compact"] }] }); }
|
|
368
523
|
}
|
|
369
524
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionModelerComponent, decorators: [{
|
|
370
525
|
type: Component,
|
|
@@ -383,7 +538,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
383
538
|
OverflowMenuComponent,
|
|
384
539
|
OverflowMenuOptionComponent,
|
|
385
540
|
OverflowMenuTriggerComponent,
|
|
386
|
-
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n decisionXml: decisionXml$ | async,\n decisionTitle: decisionTitle$ | async,\n } as obs\"\n fitPage\n [disableOverflow]=\"true\"\n class=\"dmn-editor\"\n>\n <ng-container *ngTemplateOutlet=\"diagram\"></ng-container>\n</div>\n\n<ng-template #diagram>\n <div class=\"editor-parent\">\n <div class=\"editor-container\"></div>\n <div class=\"editor-tabs\"></div>\n </div>\n</ng-template>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div\n *ngIf=\"{\n selectionId: selectionId$ | async,\n isCreating: isCreating$ | async,\n context: context$ | async,\n compactMode: compactMode$ | async,\n hasEditPermissions: hasEditPermissions$ | async,\n } as obs\"\n class=\"decision-modeler-actions\"\n >\n <ng-container *ngTemplateOutlet=\"versionSelection\"></ng-container>\n\n <button\n *ngIf=\"obs.context === 'case'\"\n cdsButton=\"secondary\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n (click)=\"navigateBack(null)\"\n >\n <svg class=\"cds--btn__icon\" cdsIcon=\"arrow--left\" size=\"16\"></svg>\n\n <span>{{ 'interface.back' | translate }}</span>\n </button>\n\n @if (obs.selectionId && !obs.isCreating) {\n <button\n *ngIf=\"obs.hasEditPermissions\"\n cdsButton=\"primary\"\n (click)=\"deploy()\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n >\n {{ 'decisions.deploy' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"deploy\" size=\"16\"></svg>\n </button>\n\n <v-overflow-menu class=\"overflow-button\" placement=\"bottom-end\">\n <v-overflow-menu-trigger overflowTrigger></v-overflow-menu-trigger>\n <v-overflow-menu-option (selected)=\"download()\"\n >{{ 'interface.export' | translate }}\n </v-overflow-menu-option>\n </v-overflow-menu>\n } @else {\n <button class=\"btn btn-success btn-space\" (click)=\"deploy()\">\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'decisions.deploy' | translate }}\n </button>\n }\n </div>\n </ng-template>\n</ng-container>\n\n<ng-template #versionSelection>\n <ng-container\n *ngIf=\"{\n selectItems: (decisionVersionSelectItems$ | async) || [],\n isIndependent: isIndependent$ | async,\n versionSelectionDisabled: versionSelectionDisabled$ | async,\n selectionId: selectionId$ | async,\n } as obs\"\n >\n <v-select\n *ngIf=\"obs.isIndependent\"\n name=\"version\"\n [title]=\"'decisions.version' | translate\"\n [disabled]=\"obs.versionSelectionDisabled\"\n [clearable]=\"false\"\n [loading]=\"obs.selectItems.length === 0\"\n [items]=\"obs.selectItems\"\n [defaultSelectionId]=\"obs.selectionId\"\n [widthInPx]=\"120\"\n (selectedChange)=\"switchVersion($event)\"\n ></v-select>\n </ng-container>\n</ng-template>\n", styles: ["#save-button{position:absolute;bottom:10px;left:10px;background:#fff;border:solid 1px #ccc;border-radius:2px;padding:8px;font-family:Arial,sans-serif;font-weight:700;cursor:default;font-size:14px;color:#444}.dmn-modeler{display:flex;flex-direction:column;width:100%;padding:1rem}.diagram,.diagram-header{border:1px solid #dee2e6}.decision-title{color:#6b6b6b;font-size:1.5rem;margin:0}.fullscreen-toggle{font-size:2rem}.fullscreen-toggle>i{cursor:pointer}.dmn-editor{background-color:var(--cds-layer);outline:1px solid var(--cds-border-subtle);outline-offset:-1px;padding:16px}.decision-modeler-actions{display:flex;width:100%;justify-content:flex-end;align-items:flex-end;gap:16px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
541
|
+
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n decisionXml: decisionXml$ | async,\n decisionTitle: decisionTitle$ | async,\n } as obs\"\n fitPage\n [disableOverflow]=\"true\"\n class=\"dmn-editor\"\n>\n <ng-container *ngTemplateOutlet=\"diagram\"></ng-container>\n</div>\n\n<ng-template #diagram>\n <div class=\"editor-parent\">\n <div class=\"editor-container\"></div>\n <div class=\"editor-tabs\"></div>\n </div>\n</ng-template>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div\n *ngIf=\"{\n selectionId: selectionId$ | async,\n isCreating: isCreating$ | async,\n context: context$ | async,\n compactMode: compactMode$ | async,\n hasEditPermissions: hasEditPermissions$ | async,\n } as obs\"\n class=\"decision-modeler-actions\"\n >\n <ng-container *ngTemplateOutlet=\"versionSelection\"></ng-container>\n\n <button\n *ngIf=\"obs.context === 'case'\"\n cdsButton=\"secondary\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n (click)=\"navigateBack(null)\"\n [attr.data-test-id]=\"testIds.backButton\"\n >\n <svg class=\"cds--btn__icon\" cdsIcon=\"arrow--left\" size=\"16\"></svg>\n\n <span>{{ 'interface.back' | translate }}</span>\n </button>\n\n @if (obs.selectionId && !obs.isCreating) {\n <button\n *ngIf=\"obs.hasEditPermissions\"\n cdsButton=\"primary\"\n (click)=\"deploy()\"\n [size]=\"obs.compactMode ? 'sm' : 'md'\"\n [attr.data-test-id]=\"testIds.deployButton\"\n >\n {{ 'decisions.deploy' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"deploy\" size=\"16\"></svg>\n </button>\n\n <v-overflow-menu class=\"overflow-button\" placement=\"bottom-end\">\n <v-overflow-menu-trigger overflowTrigger></v-overflow-menu-trigger>\n <v-overflow-menu-option (selected)=\"download()\"\n >{{ 'interface.export' | translate }}\n </v-overflow-menu-option>\n </v-overflow-menu>\n } @else {\n <button class=\"btn btn-success btn-space\" (click)=\"deploy()\">\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'decisions.deploy' | translate }}\n </button>\n }\n </div>\n </ng-template>\n</ng-container>\n\n<ng-template #versionSelection>\n <ng-container\n *ngIf=\"{\n selectItems: (decisionVersionSelectItems$ | async) || [],\n isIndependent: isIndependent$ | async,\n versionSelectionDisabled: versionSelectionDisabled$ | async,\n selectionId: selectionId$ | async,\n } as obs\"\n >\n <v-select\n *ngIf=\"obs.isIndependent\"\n name=\"version\"\n [title]=\"'decisions.version' | translate\"\n [disabled]=\"obs.versionSelectionDisabled\"\n [clearable]=\"false\"\n [loading]=\"obs.selectItems.length === 0\"\n [items]=\"obs.selectItems\"\n [defaultSelectionId]=\"obs.selectionId\"\n [widthInPx]=\"120\"\n (selectedChange)=\"switchVersion($event)\"\n ></v-select>\n </ng-container>\n</ng-template>\n", styles: ["#save-button{position:absolute;bottom:10px;left:10px;background:#fff;border:solid 1px #ccc;border-radius:2px;padding:8px;font-family:Arial,sans-serif;font-weight:700;cursor:default;font-size:14px;color:#444}.dmn-modeler{display:flex;flex-direction:column;width:100%;padding:1rem}.diagram,.diagram-header{border:1px solid #dee2e6}.decision-title{color:#6b6b6b;font-size:1.5rem;margin:0}.fullscreen-toggle{font-size:2rem}.fullscreen-toggle>i{cursor:pointer}.dmn-editor{background-color:var(--cds-layer);outline:1px solid var(--cds-border-subtle);outline-offset:-1px;padding:16px}.decision-modeler-actions{display:flex;width:100%;justify-content:flex-end;align-items:flex-end;gap:16px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
387
542
|
}], ctorParameters: () => [{ type: DecisionService }, { type: i2.ActivatedRoute }, { type: i2.Router }, { type: i3.TranslateService }, { type: i4.PageTitleService }, { type: i4.BreadcrumbService }, { type: i6$1.IconService }, { type: i4.PageHeaderService }, { type: i6.GlobalNotificationService }, { type: i6.EditPermissionsService }] });
|
|
388
543
|
|
|
389
544
|
/*
|
|
@@ -452,7 +607,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
452
607
|
}], ctorParameters: () => [{ type: DecisionService }, { type: i2.ActivatedRoute }] });
|
|
453
608
|
|
|
454
609
|
/*
|
|
455
|
-
* Copyright 2015-
|
|
610
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
456
611
|
*
|
|
457
612
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
458
613
|
* you may not use this file except in compliance with the License.
|
|
@@ -466,44 +621,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
466
621
|
* See the License for the specific language governing permissions and
|
|
467
622
|
* limitations under the License.
|
|
468
623
|
*/
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
}
|
|
479
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionStateService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
480
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionStateService, providedIn: 'root' }); }
|
|
624
|
+
function filterLatestDecisionVersions(decisions) {
|
|
625
|
+
return decisions.reduce((acc, curr) => {
|
|
626
|
+
const existing = acc.find(d => d.key === curr.key);
|
|
627
|
+
if (existing && existing.version >= curr.version)
|
|
628
|
+
return acc;
|
|
629
|
+
if (existing && existing.version < curr.version)
|
|
630
|
+
return [...acc.filter(d => d.key !== curr.key), curr];
|
|
631
|
+
return [...acc, curr];
|
|
632
|
+
}, []);
|
|
481
633
|
}
|
|
482
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionStateService, decorators: [{
|
|
483
|
-
type: Injectable,
|
|
484
|
-
args: [{
|
|
485
|
-
providedIn: 'root',
|
|
486
|
-
}]
|
|
487
|
-
}] });
|
|
488
634
|
|
|
489
635
|
/*
|
|
490
|
-
* Copyright 2015-
|
|
491
|
-
*
|
|
492
|
-
* Licensed under EUPL, Version 1.2 (the "License");
|
|
493
|
-
* you may not use this file except in compliance with the License.
|
|
494
|
-
* You may obtain a copy of the License at
|
|
495
|
-
*
|
|
496
|
-
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
497
|
-
*
|
|
498
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
499
|
-
* distributed under the License is distributed on an "AS IS" basis,
|
|
500
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
501
|
-
* See the License for the specific language governing permissions and
|
|
502
|
-
* limitations under the License.
|
|
503
|
-
*/
|
|
504
|
-
|
|
505
|
-
/*
|
|
506
|
-
* Copyright 2015-2025 Ritense BV, the Netherlands.
|
|
636
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
507
637
|
*
|
|
508
638
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
509
639
|
* you may not use this file except in compliance with the License.
|
|
@@ -526,7 +656,9 @@ class DecisionDeployComponent {
|
|
|
526
656
|
this.deploySuccessful = new EventEmitter();
|
|
527
657
|
this.dmn = null;
|
|
528
658
|
this.modalOpen$ = new BehaviorSubject(false);
|
|
659
|
+
this.testIds = DECISION_UPLOAD_TEST_IDS;
|
|
529
660
|
this.caseManagementRouteParams$ = getCaseManagementRouteParams(this.route);
|
|
661
|
+
this.buildingBlockManagementRouteParams$ = getBuildingBlockManagementRouteParams(this.route);
|
|
530
662
|
this.context$ = getContextObservable(this.route);
|
|
531
663
|
this.ACCEPTED_FILES = ['dmn'];
|
|
532
664
|
this.form = this.formBuilder.group({
|
|
@@ -544,10 +676,16 @@ class DecisionDeployComponent {
|
|
|
544
676
|
const dmnFile = this.selectedDmnFile;
|
|
545
677
|
if (!dmnFile)
|
|
546
678
|
return;
|
|
547
|
-
|
|
548
|
-
.pipe(take(1), switchMap(
|
|
549
|
-
|
|
550
|
-
|
|
679
|
+
this.context$
|
|
680
|
+
.pipe(take(1), switchMap(context => {
|
|
681
|
+
if (context === 'case') {
|
|
682
|
+
return this.caseManagementRouteParams$.pipe(take(1), switchMap(params => this.decisionService.deployCaseDecisionDefinition(params.caseDefinitionKey, params.caseDefinitionVersionTag, dmnFile)));
|
|
683
|
+
}
|
|
684
|
+
if (context === 'buildingBlock') {
|
|
685
|
+
return this.buildingBlockManagementRouteParams$.pipe(take(1), switchMap(params => this.decisionService.deployBuildingBlockDecisionDefinition(params.buildingBlockDefinitionKey, params.buildingBlockDefinitionVersionTag, dmnFile)));
|
|
686
|
+
}
|
|
687
|
+
return this.decisionService.deployDmn(dmnFile);
|
|
688
|
+
}))
|
|
551
689
|
.subscribe(() => {
|
|
552
690
|
this.closeModal();
|
|
553
691
|
this.deploySuccessful.emit();
|
|
@@ -561,7 +699,7 @@ class DecisionDeployComponent {
|
|
|
561
699
|
this.modalOpen$.next(false);
|
|
562
700
|
}
|
|
563
701
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionDeployComponent, deps: [{ token: DecisionService }, { token: DecisionStateService }, { token: i2.ActivatedRoute }, { token: i3$1.FormBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
564
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: DecisionDeployComponent, isStandalone: true, selector: "valtimo-decision-deploy", outputs: { deploySuccessful: "deploySuccessful" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal showFooter=\"true\" valtimoCdsModal [open]=\"modalOpen$ | async\" (close)=\"closeModal()\">\n <cds-modal-header showCloseButton=\"true\" (closeSelect)=\"closeModal()\">\n <h3 cdsModalHeaderHeading>{{ 'decisions.upload.title' | translate }}</h3>\n </cds-modal-header>\n\n <section cdsModalContent [cdsLayer]=\"1\" [formGroup]=\"form\">\n <cds-file-uploader\n [accept]=\"ACCEPTED_FILES\"\n [multiple]=\"false\"\n buttonType=\"primary\"\n [title]=\"'decisions.upload.fileUploaderTitle' | translate\"\n [description]=\"'decisions.upload.fileUploaderDescription' | translate\"\n [buttonText]=\"'decisions.upload.fileUploaderButton' | translate\"\n formControlName=\"file\"\n >\n </cds-file-uploader>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"secondary\" (click)=\"closeModal()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button
|
|
702
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: DecisionDeployComponent, isStandalone: true, selector: "valtimo-decision-deploy", outputs: { deploySuccessful: "deploySuccessful" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal showFooter=\"true\" valtimoCdsModal [open]=\"modalOpen$ | async\" (close)=\"closeModal()\">\n <cds-modal-header showCloseButton=\"true\" (closeSelect)=\"closeModal()\">\n <h3 cdsModalHeaderHeading>{{ 'decisions.upload.title' | translate }}</h3>\n </cds-modal-header>\n\n <section cdsModalContent [cdsLayer]=\"1\" [formGroup]=\"form\">\n <cds-file-uploader\n [accept]=\"ACCEPTED_FILES\"\n [multiple]=\"false\"\n buttonType=\"primary\"\n [title]=\"'decisions.upload.fileUploaderTitle' | translate\"\n [description]=\"'decisions.upload.fileUploaderDescription' | translate\"\n [buttonText]=\"'decisions.upload.fileUploaderButton' | translate\"\n formControlName=\"file\"\n >\n </cds-file-uploader>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"secondary\" (click)=\"closeModal()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button\n cdsButton=\"primary\"\n [disabled]=\"!selectedDmnFile\"\n (click)=\"deployDmn()\"\n [attr.data-test-id]=\"testIds.submitButton\"\n >\n {{ 'interface.upload' | translate }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n", styles: ["/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i7.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ModalModule }, { kind: "component", type: i6$1.Modal, selector: "cds-modal, ibm-modal", inputs: ["size", "theme", "ariaLabel", "open", "trigger", "hasScrollingContent"], outputs: ["overlaySelected", "close"] }, { kind: "component", type: i6$1.ModalHeader, selector: "cds-modal-header, ibm-modal-header", inputs: ["theme", "closeLabel", "showCloseButton"], outputs: ["closeSelect"] }, { kind: "component", type: i6$1.ModalFooter, selector: "cds-modal-footer, ibm-modal-footer" }, { kind: "directive", type: i6$1.ModalContent, selector: "[cdsModalContent], [ibmModalContent]", inputs: ["hasForm"] }, { kind: "directive", type: i6$1.ModalHeaderHeading, selector: "[cdsModalHeaderHeading], [ibmModalHeaderHeading]" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i6$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: LayerModule }, { kind: "directive", type: i6$1.LayerDirective, selector: "[cdsLayer], [ibmLayer]", inputs: ["ibmLayer", "cdsLayer"], exportAs: ["layer"] }, { kind: "ngmodule", type: FileUploaderModule }, { kind: "component", type: i6$1.FileUploader, selector: "cds-file-uploader, ibm-file-uploader", inputs: ["buttonText", "buttonType", "title", "description", "accept", "multiple", "skeleton", "size", "fileItemSize", "drop", "dropText", "fileUploaderId", "files", "disabled"], outputs: ["filesChange"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i3$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }] }); }
|
|
565
703
|
}
|
|
566
704
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionDeployComponent, decorators: [{
|
|
567
705
|
type: Component,
|
|
@@ -574,13 +712,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
574
712
|
LayerModule,
|
|
575
713
|
FileUploaderModule,
|
|
576
714
|
ReactiveFormsModule,
|
|
577
|
-
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal showFooter=\"true\" valtimoCdsModal [open]=\"modalOpen$ | async\" (close)=\"closeModal()\">\n <cds-modal-header showCloseButton=\"true\" (closeSelect)=\"closeModal()\">\n <h3 cdsModalHeaderHeading>{{ 'decisions.upload.title' | translate }}</h3>\n </cds-modal-header>\n\n <section cdsModalContent [cdsLayer]=\"1\" [formGroup]=\"form\">\n <cds-file-uploader\n [accept]=\"ACCEPTED_FILES\"\n [multiple]=\"false\"\n buttonType=\"primary\"\n [title]=\"'decisions.upload.fileUploaderTitle' | translate\"\n [description]=\"'decisions.upload.fileUploaderDescription' | translate\"\n [buttonText]=\"'decisions.upload.fileUploaderButton' | translate\"\n formControlName=\"file\"\n >\n </cds-file-uploader>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"secondary\" (click)=\"closeModal()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button
|
|
715
|
+
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal showFooter=\"true\" valtimoCdsModal [open]=\"modalOpen$ | async\" (close)=\"closeModal()\">\n <cds-modal-header showCloseButton=\"true\" (closeSelect)=\"closeModal()\">\n <h3 cdsModalHeaderHeading>{{ 'decisions.upload.title' | translate }}</h3>\n </cds-modal-header>\n\n <section cdsModalContent [cdsLayer]=\"1\" [formGroup]=\"form\">\n <cds-file-uploader\n [accept]=\"ACCEPTED_FILES\"\n [multiple]=\"false\"\n buttonType=\"primary\"\n [title]=\"'decisions.upload.fileUploaderTitle' | translate\"\n [description]=\"'decisions.upload.fileUploaderDescription' | translate\"\n [buttonText]=\"'decisions.upload.fileUploaderButton' | translate\"\n formControlName=\"file\"\n >\n </cds-file-uploader>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"secondary\" (click)=\"closeModal()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button\n cdsButton=\"primary\"\n [disabled]=\"!selectedDmnFile\"\n (click)=\"deployDmn()\"\n [attr.data-test-id]=\"testIds.submitButton\"\n >\n {{ 'interface.upload' | translate }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n", styles: ["/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
578
716
|
}], ctorParameters: () => [{ type: DecisionService }, { type: DecisionStateService }, { type: i2.ActivatedRoute }, { type: i3$1.FormBuilder }], propDecorators: { deploySuccessful: [{
|
|
579
717
|
type: Output
|
|
580
718
|
}] } });
|
|
581
719
|
|
|
582
720
|
/*
|
|
583
|
-
* Copyright 2015-
|
|
721
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
584
722
|
*
|
|
585
723
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
586
724
|
* you may not use this file except in compliance with the License.
|
|
@@ -610,18 +748,19 @@ class DecisionListComponent {
|
|
|
610
748
|
{ key: 'version', label: 'Version' },
|
|
611
749
|
];
|
|
612
750
|
this.loading$ = new BehaviorSubject(true);
|
|
751
|
+
this.testIds = DECISION_LIST_TEST_IDS;
|
|
613
752
|
this.caseManagementRouteParams$ = getCaseManagementRouteParams(this.route);
|
|
753
|
+
this.buildingBlockManagementRouteParams$ = getBuildingBlockManagementRouteParams(this.route);
|
|
614
754
|
this.context$ = getContextObservable(this.route);
|
|
615
|
-
this.decisionsLatestVersions$ = this.stateService.refreshDecisions$.pipe(switchMap(() => this.context$), switchMap(context =>
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
if (
|
|
620
|
-
return
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
}, [])), tap(() => {
|
|
755
|
+
this.decisionsLatestVersions$ = this.stateService.refreshDecisions$.pipe(switchMap(() => this.context$), switchMap(context => {
|
|
756
|
+
if (context === 'case') {
|
|
757
|
+
return this.caseManagementRouteParams$.pipe(switchMap(params => this.decisionService.listCaseDecisionDefinitions(params.caseDefinitionKey, params.caseDefinitionVersionTag)));
|
|
758
|
+
}
|
|
759
|
+
if (context === 'buildingBlock') {
|
|
760
|
+
return this.buildingBlockManagementRouteParams$.pipe(switchMap(params => this.decisionService.listBuildingBlockDecisionDefinitions(params.buildingBlockDefinitionKey, params.buildingBlockDefinitionVersionTag)));
|
|
761
|
+
}
|
|
762
|
+
return this.decisionService.getDecisions();
|
|
763
|
+
}), map(filterLatestDecisionVersions), tap(() => {
|
|
625
764
|
this.loading$.next(false);
|
|
626
765
|
this.cdr.detectChanges();
|
|
627
766
|
}));
|
|
@@ -640,6 +779,11 @@ class DecisionListComponent {
|
|
|
640
779
|
const basePath = this.experimentalEditing ? '/decision-tables/edit/' : '/decision-tables/';
|
|
641
780
|
this.router.navigate([basePath + decision.id]);
|
|
642
781
|
}
|
|
782
|
+
else if (context === 'buildingBlock') {
|
|
783
|
+
this.buildingBlockManagementRouteParams$.pipe(take(1)).subscribe(params => {
|
|
784
|
+
this.router.navigateByUrl(`building-block-management/building-block/${params.buildingBlockDefinitionKey}/version/${params.buildingBlockDefinitionVersionTag}/decisions/${decision.id}`);
|
|
785
|
+
});
|
|
786
|
+
}
|
|
643
787
|
else {
|
|
644
788
|
this.caseManagementRouteParams$.pipe(take(1)).subscribe(params => {
|
|
645
789
|
this.router.navigateByUrl(`case-management/case/${params.caseDefinitionKey}/version/${params.caseDefinitionVersionTag}/decisions/${decision.id}`);
|
|
@@ -648,7 +792,7 @@ class DecisionListComponent {
|
|
|
648
792
|
});
|
|
649
793
|
}
|
|
650
794
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionListComponent, deps: [{ token: DecisionService }, { token: i6$1.IconService }, { token: i2.Router }, { token: i6.ConfigService }, { token: DecisionStateService }, { token: i2.ActivatedRoute }, { token: i0.ChangeDetectorRef }, { token: i6.EditPermissionsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
651
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: DecisionListComponent, isStandalone: true, selector: "valtimo-decision-list", viewQueries: [{ propertyName: "deploy", first: true, predicate: ["decisionDeploy"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [items]=\"(decisionsLatestVersions$ | async) || []\"\n [loading]=\"loading$ | async\"\n [fields]=\"fields\"\n (rowClicked)=\"viewDecisionTable($event)\"\n [header]=\"false\"\n [isSearchable]=\"true\"\n>\n <ng-container carbonToolbarContent>\n <button\n *ngIf=\"hasEditPermissions$ | async\"\n cdsButton=\"primary\"\n (click)=\"this.deploy.openModal()\"\n >\n {{ 'Upload' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"upload\" size=\"16\"></svg>\n </button>\n </ng-container>\n</valtimo-carbon-list>\n\n<valtimo-decision-deploy #decisionDeploy></valtimo-decision-deploy>\n", styles: ["/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i7.AsyncPipe, name: "async" }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: CarbonListModule }, { kind: "component", type: i4.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "skeletonRowCount", "actions", "actionItems", "showActionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i6$1.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "ngmodule", type: WidgetModule }, { kind: "component", type: DecisionDeployComponent, selector: "valtimo-decision-deploy", outputs: ["deploySuccessful"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i6$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }] }); }
|
|
795
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: DecisionListComponent, isStandalone: true, selector: "valtimo-decision-list", viewQueries: [{ propertyName: "deploy", first: true, predicate: ["decisionDeploy"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [items]=\"(decisionsLatestVersions$ | async) || []\"\n [loading]=\"loading$ | async\"\n [fields]=\"fields\"\n (rowClicked)=\"viewDecisionTable($event)\"\n [header]=\"false\"\n [isSearchable]=\"true\"\n>\n <ng-container carbonToolbarContent>\n <button\n *ngIf=\"hasEditPermissions$ | async\"\n cdsButton=\"primary\"\n (click)=\"this.deploy.openModal()\"\n [attr.data-test-id]=\"testIds.uploadButton\"\n >\n {{ 'Upload' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"upload\" size=\"16\"></svg>\n </button>\n </ng-container>\n</valtimo-carbon-list>\n\n<valtimo-decision-deploy #decisionDeploy></valtimo-decision-deploy>\n", styles: ["/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i7.AsyncPipe, name: "async" }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: CarbonListModule }, { kind: "component", type: i4.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "skeletonRowCount", "actions", "actionItems", "showActionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i6$1.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "ngmodule", type: WidgetModule }, { kind: "component", type: DecisionDeployComponent, selector: "valtimo-decision-deploy", outputs: ["deploySuccessful"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i6$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }] }); }
|
|
652
796
|
}
|
|
653
797
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: DecisionListComponent, decorators: [{
|
|
654
798
|
type: Component,
|
|
@@ -661,7 +805,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
661
805
|
DecisionDeployComponent,
|
|
662
806
|
TranslateModule,
|
|
663
807
|
ButtonModule,
|
|
664
|
-
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [items]=\"(decisionsLatestVersions$ | async) || []\"\n [loading]=\"loading$ | async\"\n [fields]=\"fields\"\n (rowClicked)=\"viewDecisionTable($event)\"\n [header]=\"false\"\n [isSearchable]=\"true\"\n>\n <ng-container carbonToolbarContent>\n <button\n *ngIf=\"hasEditPermissions$ | async\"\n cdsButton=\"primary\"\n (click)=\"this.deploy.openModal()\"\n >\n {{ 'Upload' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"upload\" size=\"16\"></svg>\n </button>\n </ng-container>\n</valtimo-carbon-list>\n\n<valtimo-decision-deploy #decisionDeploy></valtimo-decision-deploy>\n", styles: ["/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
808
|
+
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [items]=\"(decisionsLatestVersions$ | async) || []\"\n [loading]=\"loading$ | async\"\n [fields]=\"fields\"\n (rowClicked)=\"viewDecisionTable($event)\"\n [header]=\"false\"\n [isSearchable]=\"true\"\n>\n <ng-container carbonToolbarContent>\n <button\n *ngIf=\"hasEditPermissions$ | async\"\n cdsButton=\"primary\"\n (click)=\"this.deploy.openModal()\"\n [attr.data-test-id]=\"testIds.uploadButton\"\n >\n {{ 'Upload' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"upload\" size=\"16\"></svg>\n </button>\n </ng-container>\n</valtimo-carbon-list>\n\n<valtimo-decision-deploy #decisionDeploy></valtimo-decision-deploy>\n", styles: ["/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
665
809
|
}], ctorParameters: () => [{ type: DecisionService }, { type: i6$1.IconService }, { type: i2.Router }, { type: i6.ConfigService }, { type: DecisionStateService }, { type: i2.ActivatedRoute }, { type: i0.ChangeDetectorRef }, { type: i6.EditPermissionsService }], propDecorators: { deploy: [{
|
|
666
810
|
type: ViewChild,
|
|
667
811
|
args: ['decisionDeploy']
|
|
@@ -812,7 +956,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
812
956
|
}] });
|
|
813
957
|
|
|
814
958
|
/*
|
|
815
|
-
* Copyright 2015-
|
|
959
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
816
960
|
*
|
|
817
961
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
818
962
|
* you may not use this file except in compliance with the License.
|
|
@@ -834,5 +978,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImpo
|
|
|
834
978
|
* Generated bundle index. Do not edit.
|
|
835
979
|
*/
|
|
836
980
|
|
|
837
|
-
export { DecisionDeployComponent, DecisionDisplayComponent, DecisionListComponent, DecisionModelerComponent, DecisionModule };
|
|
981
|
+
export { DECISION_LIST_TEST_IDS, DECISION_MODELER_TEST_IDS, DECISION_UPLOAD_TEST_IDS, DecisionDeployComponent, DecisionDisplayComponent, DecisionListComponent, DecisionModelerComponent, DecisionModule, DecisionService, DecisionStateService, filterLatestDecisionVersions };
|
|
838
982
|
//# sourceMappingURL=valtimo-decision.mjs.map
|