@valtimo/process-management 10.8.0 → 11.0.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.
Files changed (23) hide show
  1. package/{esm2020 → esm2022}/lib/process-management-builder/process-management-builder.component.mjs +4 -4
  2. package/esm2022/lib/process-management-list/process-management-list.component.mjs +51 -0
  3. package/{esm2020 → esm2022}/lib/process-management-routing.mjs +5 -5
  4. package/{esm2020 → esm2022}/lib/process-management-upload/process-management-upload.component.mjs +4 -4
  5. package/{esm2020 → esm2022}/lib/process-management.component.mjs +4 -4
  6. package/{esm2020 → esm2022}/lib/process-management.module.mjs +18 -18
  7. package/esm2022/lib/process-management.service.mjs +42 -0
  8. package/{fesm2020 → fesm2022}/valtimo-process-management.mjs +39 -36
  9. package/fesm2022/valtimo-process-management.mjs.map +1 -0
  10. package/lib/process-management-builder/process-management-builder.component.d.ts +1 -1
  11. package/lib/process-management-list/process-management-list.component.d.ts +1 -1
  12. package/lib/process-management-list/process-management-list.component.d.ts.map +1 -1
  13. package/lib/process-management-upload/process-management-upload.component.d.ts +1 -1
  14. package/lib/process-management.component.d.ts +1 -1
  15. package/lib/process-management.service.d.ts.map +1 -1
  16. package/package.json +10 -19
  17. package/esm2020/lib/process-management-list/process-management-list.component.mjs +0 -51
  18. package/esm2020/lib/process-management.service.mjs +0 -42
  19. package/fesm2015/valtimo-process-management.mjs +0 -472
  20. package/fesm2015/valtimo-process-management.mjs.map +0 -1
  21. package/fesm2020/valtimo-process-management.mjs.map +0 -1
  22. /package/{esm2020 → esm2022}/public-api.mjs +0 -0
  23. /package/{esm2020 → esm2022}/valtimo-process-management.mjs +0 -0
@@ -1,42 +0,0 @@
1
- /*
2
- * Copyright 2015-2023 Ritense BV, the Netherlands.
3
- *
4
- * Licensed under EUPL, Version 1.2 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" basis,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- import { Injectable } from '@angular/core';
17
- import * as i0 from "@angular/core";
18
- import * as i1 from "@valtimo/config";
19
- import * as i2 from "@angular/common/http";
20
- export class ProcessManagementService {
21
- constructor(configService, http) {
22
- this.configService = configService;
23
- this.http = http;
24
- this.valtimoApiConfig = configService.config.valtimoApi;
25
- }
26
- deployBpmn(bpmn) {
27
- const formData = new FormData();
28
- formData.append('file', bpmn);
29
- formData.append('deployment-name', 'valtimoConsoleApp');
30
- formData.append('deployment-source', 'process application');
31
- return this.http.post(`${this.valtimoApiConfig.endpointUri}v1/process/definition/deployment`, formData);
32
- }
33
- }
34
- ProcessManagementService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementService, deps: [{ token: i1.ConfigService }, { token: i2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
35
- ProcessManagementService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementService, providedIn: 'root' });
36
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementService, decorators: [{
37
- type: Injectable,
38
- args: [{
39
- providedIn: 'root',
40
- }]
41
- }], ctorParameters: function () { return [{ type: i1.ConfigService }, { type: i2.HttpClient }]; } });
42
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJvY2Vzcy1tYW5hZ2VtZW50LnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy92YWx0aW1vL3Byb2Nlc3MtbWFuYWdlbWVudC9zcmMvbGliL3Byb2Nlc3MtbWFuYWdlbWVudC5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7Ozs7Ozs7Ozs7OztHQWNHO0FBRUgsT0FBTyxFQUFDLFVBQVUsRUFBQyxNQUFNLGVBQWUsQ0FBQzs7OztBQVF6QyxNQUFNLE9BQU8sd0JBQXdCO0lBR25DLFlBQW9CLGFBQTRCLEVBQVUsSUFBZ0I7UUFBdEQsa0JBQWEsR0FBYixhQUFhLENBQWU7UUFBVSxTQUFJLEdBQUosSUFBSSxDQUFZO1FBQ3hFLElBQUksQ0FBQyxnQkFBZ0IsR0FBRyxhQUFhLENBQUMsTUFBTSxDQUFDLFVBQVUsQ0FBQztJQUMxRCxDQUFDO0lBRUQsVUFBVSxDQUFDLElBQVU7UUFDbkIsTUFBTSxRQUFRLEdBQWEsSUFBSSxRQUFRLEVBQUUsQ0FBQztRQUMxQyxRQUFRLENBQUMsTUFBTSxDQUFDLE1BQU0sRUFBRSxJQUFJLENBQUMsQ0FBQztRQUM5QixRQUFRLENBQUMsTUFBTSxDQUFDLGlCQUFpQixFQUFFLG1CQUFtQixDQUFDLENBQUM7UUFDeEQsUUFBUSxDQUFDLE1BQU0sQ0FBQyxtQkFBbUIsRUFBRSxxQkFBcUIsQ0FBQyxDQUFDO1FBQzVELE9BQU8sSUFBSSxDQUFDLElBQUksQ0FBQyxJQUFJLENBQ25CLEdBQUcsSUFBSSxDQUFDLGdCQUFnQixDQUFDLFdBQVcsa0NBQWtDLEVBQ3RFLFFBQVEsQ0FDVCxDQUFDO0lBQ0osQ0FBQzs7cUhBaEJVLHdCQUF3Qjt5SEFBeEIsd0JBQXdCLGNBRnZCLE1BQU07MkZBRVAsd0JBQXdCO2tCQUhwQyxVQUFVO21CQUFDO29CQUNWLFVBQVUsRUFBRSxNQUFNO2lCQUNuQiIsInNvdXJjZXNDb250ZW50IjpbIi8qXG4gKiBDb3B5cmlnaHQgMjAxNS0yMDIzIFJpdGVuc2UgQlYsIHRoZSBOZXRoZXJsYW5kcy5cbiAqXG4gKiBMaWNlbnNlZCB1bmRlciBFVVBMLCBWZXJzaW9uIDEuMiAodGhlIFwiTGljZW5zZVwiKTtcbiAqIHlvdSBtYXkgbm90IHVzZSB0aGlzIGZpbGUgZXhjZXB0IGluIGNvbXBsaWFuY2Ugd2l0aCB0aGUgTGljZW5zZS5cbiAqIFlvdSBtYXkgb2J0YWluIGEgY29weSBvZiB0aGUgTGljZW5zZSBhdFxuICpcbiAqIGh0dHBzOi8vam9pbnVwLmVjLmV1cm9wYS5ldS9jb2xsZWN0aW9uL2V1cGwvZXVwbC10ZXh0LWV1cGwtMTJcbiAqXG4gKiBVbmxlc3MgcmVxdWlyZWQgYnkgYXBwbGljYWJsZSBsYXcgb3IgYWdyZWVkIHRvIGluIHdyaXRpbmcsIHNvZnR3YXJlXG4gKiBkaXN0cmlidXRlZCB1bmRlciB0aGUgTGljZW5zZSBpcyBkaXN0cmlidXRlZCBvbiBhbiBcIkFTIElTXCIgYmFzaXMsXG4gKiBXSVRIT1VUIFdBUlJBTlRJRVMgT1IgQ09ORElUSU9OUyBPRiBBTlkgS0lORCwgZWl0aGVyIGV4cHJlc3Mgb3IgaW1wbGllZC5cbiAqIFNlZSB0aGUgTGljZW5zZSBmb3IgdGhlIHNwZWNpZmljIGxhbmd1YWdlIGdvdmVybmluZyBwZXJtaXNzaW9ucyBhbmRcbiAqIGxpbWl0YXRpb25zIHVuZGVyIHRoZSBMaWNlbnNlLlxuICovXG5cbmltcG9ydCB7SW5qZWN0YWJsZX0gZnJvbSAnQGFuZ3VsYXIvY29yZSc7XG5pbXBvcnQge09ic2VydmFibGV9IGZyb20gJ3J4anMnO1xuaW1wb3J0IHtIdHRwQ2xpZW50fSBmcm9tICdAYW5ndWxhci9jb21tb24vaHR0cCc7XG5pbXBvcnQge0NvbmZpZ1NlcnZpY2V9IGZyb20gJ0B2YWx0aW1vL2NvbmZpZyc7XG5cbkBJbmplY3RhYmxlKHtcbiAgcHJvdmlkZWRJbjogJ3Jvb3QnLFxufSlcbmV4cG9ydCBjbGFzcyBQcm9jZXNzTWFuYWdlbWVudFNlcnZpY2Uge1xuICBwcml2YXRlIHZhbHRpbW9BcGlDb25maWc6IGFueTtcblxuICBjb25zdHJ1Y3Rvcihwcml2YXRlIGNvbmZpZ1NlcnZpY2U6IENvbmZpZ1NlcnZpY2UsIHByaXZhdGUgaHR0cDogSHR0cENsaWVudCkge1xuICAgIHRoaXMudmFsdGltb0FwaUNvbmZpZyA9IGNvbmZpZ1NlcnZpY2UuY29uZmlnLnZhbHRpbW9BcGk7XG4gIH1cblxuICBkZXBsb3lCcG1uKGJwbW46IEZpbGUpOiBPYnNlcnZhYmxlPGFueT4ge1xuICAgIGNvbnN0IGZvcm1EYXRhOiBGb3JtRGF0YSA9IG5ldyBGb3JtRGF0YSgpO1xuICAgIGZvcm1EYXRhLmFwcGVuZCgnZmlsZScsIGJwbW4pO1xuICAgIGZvcm1EYXRhLmFwcGVuZCgnZGVwbG95bWVudC1uYW1lJywgJ3ZhbHRpbW9Db25zb2xlQXBwJyk7XG4gICAgZm9ybURhdGEuYXBwZW5kKCdkZXBsb3ltZW50LXNvdXJjZScsICdwcm9jZXNzIGFwcGxpY2F0aW9uJyk7XG4gICAgcmV0dXJuIHRoaXMuaHR0cC5wb3N0PGFueT4oXG4gICAgICBgJHt0aGlzLnZhbHRpbW9BcGlDb25maWcuZW5kcG9pbnRVcml9djEvcHJvY2Vzcy9kZWZpbml0aW9uL2RlcGxveW1lbnRgLFxuICAgICAgZm9ybURhdGFcbiAgICApO1xuICB9XG59XG4iXX0=
@@ -1,472 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { Component, Injectable, EventEmitter, Output, ViewChild, ViewEncapsulation, NgModule } from '@angular/core';
3
- import * as i5 from '@angular/router';
4
- import { RouterModule } from '@angular/router';
5
- import * as i1 from '@valtimo/process';
6
- import * as i4 from '@valtimo/components';
7
- import { WidgetModule, ListModule } from '@valtimo/components';
8
- import * as i4$1 from '@ngx-translate/core';
9
- import { TranslateModule } from '@ngx-translate/core';
10
- import * as i1$1 from '@valtimo/config';
11
- import { ROLE_ADMIN } from '@valtimo/config';
12
- import * as i2 from '@angular/common/http';
13
- import * as i6 from '@angular/common';
14
- import { CommonModule } from '@angular/common';
15
- import { AuthGuardService } from '@valtimo/security';
16
- import { BehaviorSubject, forkJoin } from 'rxjs';
17
- import Modeler from 'bpmn-js/lib/Modeler';
18
- import BpmnJS from 'bpmn-js/dist/bpmn-navigated-viewer.production.min.js';
19
- import PropertiesPanelModule from 'bpmn-js-properties-panel';
20
- import PropertiesProviderModule from 'bpmn-js-properties-panel/lib/provider/camunda';
21
- import CamundaExtensionModule from 'camunda-bpmn-moddle/lib';
22
- import CamundaModdleDescriptor from 'camunda-bpmn-moddle/resources/camunda.json';
23
- import * as i3 from '@valtimo/layout';
24
- import * as i7 from '@angular/forms';
25
- import { FormsModule } from '@angular/forms';
26
-
27
- /*
28
- * Copyright 2015-2023 Ritense BV, the Netherlands.
29
- *
30
- * Licensed under EUPL, Version 1.2 (the "License");
31
- * you may not use this file except in compliance with the License.
32
- * You may obtain a copy of the License at
33
- *
34
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
35
- *
36
- * Unless required by applicable law or agreed to in writing, software
37
- * distributed under the License is distributed on an "AS IS" basis,
38
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
39
- * See the License for the specific language governing permissions and
40
- * limitations under the License.
41
- */
42
- class ProcessManagementListComponent {
43
- constructor(processService, router) {
44
- this.processService = processService;
45
- this.router = router;
46
- this.processDefinitions = [];
47
- this.fields = [
48
- { key: 'key', label: 'Key' },
49
- { key: 'name', label: 'Name' },
50
- { key: 'readOnly', label: 'Read-only' },
51
- ];
52
- }
53
- ngOnInit() {
54
- this.loadProcessDefinitions();
55
- }
56
- loadProcessDefinitions() {
57
- this.processService.getProcessDefinitions().subscribe((processDefs) => {
58
- this.processDefinitions = processDefs;
59
- });
60
- }
61
- editProcessDefinition(processDefinition) {
62
- this.router.navigate(['/processes/process', processDefinition.key]);
63
- }
64
- }
65
- ProcessManagementListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementListComponent, deps: [{ token: i1.ProcessService }, { token: i5.Router }], target: i0.ɵɵFactoryTarget.Component });
66
- ProcessManagementListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ProcessManagementListComponent, selector: "valtimo-process-management-list", ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 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-widget>\n <valtimo-list\n [items]=\"processDefinitions\"\n [fields]=\"fields\"\n (rowClicked)=\"editProcessDefinition($event)\"\n [header]=\"true\"\n [viewMode]=\"true\"\n [isSearchable]=\"true\"\n >\n <div header>\n <h3 class=\"list-header-title\">{{ 'Processes' | translate }}</h3>\n <h5 class=\"list-header-description\">{{ 'Overview of all Processes' | translate }}</h5>\n </div>\n </valtimo-list>\n</valtimo-widget>\n", styles: ["/*!\n * Copyright 2015-2023 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: "component", type: i4.WidgetComponent, selector: "valtimo-widget", inputs: ["type", "name", "icon", "contrast", "divider", "title", "subtitle", "collapseAble", "collapse", "additionalClasses"] }, { kind: "component", type: i4.ListComponent, selector: "valtimo-list", inputs: ["items", "fields", "pagination", "viewMode", "isSearchable", "header", "actions", "paginationIdentifier", "initialSortState", "lastColumnTemplate"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged"] }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }] });
67
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementListComponent, decorators: [{
68
- type: Component,
69
- args: [{ selector: 'valtimo-process-management-list', template: "<!--\n ~ Copyright 2015-2023 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-widget>\n <valtimo-list\n [items]=\"processDefinitions\"\n [fields]=\"fields\"\n (rowClicked)=\"editProcessDefinition($event)\"\n [header]=\"true\"\n [viewMode]=\"true\"\n [isSearchable]=\"true\"\n >\n <div header>\n <h3 class=\"list-header-title\">{{ 'Processes' | translate }}</h3>\n <h5 class=\"list-header-description\">{{ 'Overview of all Processes' | translate }}</h5>\n </div>\n </valtimo-list>\n</valtimo-widget>\n", styles: ["/*!\n * Copyright 2015-2023 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"] }]
70
- }], ctorParameters: function () { return [{ type: i1.ProcessService }, { type: i5.Router }]; } });
71
-
72
- /*
73
- * Copyright 2015-2023 Ritense BV, the Netherlands.
74
- *
75
- * Licensed under EUPL, Version 1.2 (the "License");
76
- * you may not use this file except in compliance with the License.
77
- * You may obtain a copy of the License at
78
- *
79
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
80
- *
81
- * Unless required by applicable law or agreed to in writing, software
82
- * distributed under the License is distributed on an "AS IS" basis,
83
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
84
- * See the License for the specific language governing permissions and
85
- * limitations under the License.
86
- */
87
- class ProcessManagementService {
88
- constructor(configService, http) {
89
- this.configService = configService;
90
- this.http = http;
91
- this.valtimoApiConfig = configService.config.valtimoApi;
92
- }
93
- deployBpmn(bpmn) {
94
- const formData = new FormData();
95
- formData.append('file', bpmn);
96
- formData.append('deployment-name', 'valtimoConsoleApp');
97
- formData.append('deployment-source', 'process application');
98
- return this.http.post(`${this.valtimoApiConfig.endpointUri}v1/process/definition/deployment`, formData);
99
- }
100
- }
101
- ProcessManagementService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementService, deps: [{ token: i1$1.ConfigService }, { token: i2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
102
- ProcessManagementService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementService, providedIn: 'root' });
103
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementService, decorators: [{
104
- type: Injectable,
105
- args: [{
106
- providedIn: 'root',
107
- }]
108
- }], ctorParameters: function () { return [{ type: i1$1.ConfigService }, { type: i2.HttpClient }]; } });
109
-
110
- /*
111
- * Copyright 2015-2023 Ritense BV, the Netherlands.
112
- *
113
- * Licensed under EUPL, Version 1.2 (the "License");
114
- * you may not use this file except in compliance with the License.
115
- * You may obtain a copy of the License at
116
- *
117
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
118
- *
119
- * Unless required by applicable law or agreed to in writing, software
120
- * distributed under the License is distributed on an "AS IS" basis,
121
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
122
- * See the License for the specific language governing permissions and
123
- * limitations under the License.
124
- */
125
- class ProcessManagementUploadComponent {
126
- constructor(processManagementService, alertService) {
127
- this.processManagementService = processManagementService;
128
- this.alertService = alertService;
129
- this.bpmn = null;
130
- this.reload = new EventEmitter();
131
- }
132
- ngOnInit() { }
133
- onChange(files) {
134
- this.bpmn = files.item(0);
135
- }
136
- uploadProcessBpmn() {
137
- this.processManagementService.deployBpmn(this.bpmn).subscribe(() => {
138
- this.bpmn = null;
139
- this.bpmnFile.nativeElement.value = '';
140
- this.alertService.success('Deployment successful');
141
- this.reload.emit();
142
- }, error => {
143
- this.bpmn = null;
144
- this.bpmnFile.nativeElement.value = '';
145
- this.alertService.error(`Deployment failed. ${error}`);
146
- });
147
- }
148
- }
149
- ProcessManagementUploadComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementUploadComponent, deps: [{ token: ProcessManagementService }, { token: i4.AlertService }], target: i0.ɵɵFactoryTarget.Component });
150
- ProcessManagementUploadComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ProcessManagementUploadComponent, selector: "valtimo-process-management-upload", outputs: { reload: "reload" }, viewQueries: [{ propertyName: "bpmnFile", first: true, predicate: ["bpmnFile"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 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 class=\"modal fade\"\n id=\"uploadProcess\"\n tabindex=\"-1\"\n role=\"dialog\"\n aria-labelledby=\"uploadProcessLabel\"\n aria-hidden=\"true\"\n>\n <div class=\"modal-dialog modal-dialog-centered\" role=\"document\">\n <div class=\"modal-content\">\n <div class=\"modal-header\">\n <h3 class=\"modal-title\" id=\"uploadProcessLabel\">Upload process</h3>\n <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n <span aria-hidden=\"true\">&times;</span>\n </button>\n </div>\n <div class=\"modal-body\">\n <h5>BPMN Model</h5>\n <input\n #bpmnFile\n type=\"file\"\n id=\"file\"\n accept=\".bpmn\"\n (change)=\"onChange($event.target.files)\"\n />\n </div>\n <div class=\"modal-footer\">\n <div class=\"btn-group\">\n <button\n type=\"button\"\n class=\"btn btn-primary btn-space\"\n (click)=\"uploadProcessBpmn()\"\n [disabled]=\"!bpmn\"\n data-dismiss=\"modal\"\n >\n Upload\n </button>\n </div>\n </div>\n </div>\n </div>\n</div>\n", styles: ["/*!\n * Copyright 2015-2023 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"] });
151
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementUploadComponent, decorators: [{
152
- type: Component,
153
- args: [{ selector: 'valtimo-process-management-upload', template: "<!--\n ~ Copyright 2015-2023 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 class=\"modal fade\"\n id=\"uploadProcess\"\n tabindex=\"-1\"\n role=\"dialog\"\n aria-labelledby=\"uploadProcessLabel\"\n aria-hidden=\"true\"\n>\n <div class=\"modal-dialog modal-dialog-centered\" role=\"document\">\n <div class=\"modal-content\">\n <div class=\"modal-header\">\n <h3 class=\"modal-title\" id=\"uploadProcessLabel\">Upload process</h3>\n <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n <span aria-hidden=\"true\">&times;</span>\n </button>\n </div>\n <div class=\"modal-body\">\n <h5>BPMN Model</h5>\n <input\n #bpmnFile\n type=\"file\"\n id=\"file\"\n accept=\".bpmn\"\n (change)=\"onChange($event.target.files)\"\n />\n </div>\n <div class=\"modal-footer\">\n <div class=\"btn-group\">\n <button\n type=\"button\"\n class=\"btn btn-primary btn-space\"\n (click)=\"uploadProcessBpmn()\"\n [disabled]=\"!bpmn\"\n data-dismiss=\"modal\"\n >\n Upload\n </button>\n </div>\n </div>\n </div>\n </div>\n</div>\n", styles: ["/*!\n * Copyright 2015-2023 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"] }]
154
- }], ctorParameters: function () { return [{ type: ProcessManagementService }, { type: i4.AlertService }]; }, propDecorators: { reload: [{
155
- type: Output
156
- }], bpmnFile: [{
157
- type: ViewChild,
158
- args: ['bpmnFile']
159
- }] } });
160
-
161
- /*
162
- * Copyright 2015-2023 Ritense BV, the Netherlands.
163
- *
164
- * Licensed under EUPL, Version 1.2 (the "License");
165
- * you may not use this file except in compliance with the License.
166
- * You may obtain a copy of the License at
167
- *
168
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
169
- *
170
- * Unless required by applicable law or agreed to in writing, software
171
- * distributed under the License is distributed on an "AS IS" basis,
172
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
173
- * See the License for the specific language governing permissions and
174
- * limitations under the License.
175
- */
176
- class ProcessManagementComponent {
177
- constructor() { }
178
- ngOnInit() { }
179
- }
180
- ProcessManagementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
181
- ProcessManagementComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ProcessManagementComponent, selector: "valtimo-process-management", viewQueries: [{ propertyName: "processManagementList", first: true, predicate: ["processManagementList"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 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 class=\"main-content pt-0\">\n <div class=\"container-fluid\">\n <div class=\"text-right\">\n <div class=\"btn-group mt-m3px mb-3\">\n <button\n class=\"btn btn-secondary btn-space\"\n data-toggle=\"modal\"\n data-target=\"#uploadProcess\"\n >\n <i class=\"icon mdi mdi-upload mr-1\"></i>\n {{ 'Upload process' | translate }}\n </button>\n <button class=\"btn btn-primary btn-space mr-0\" [routerLink]=\"'create'\">\n <i class=\"icon mdi mdi-plus mr-1\"></i>\n {{ 'Create new Process' | translate }}\n </button>\n </div>\n </div>\n <valtimo-process-management-upload\n (reload)=\"processManagementList.loadProcessDefinitions()\"\n ></valtimo-process-management-upload>\n <valtimo-process-management-list #processManagementList></valtimo-process-management-list>\n </div>\n</div>\n", styles: ["/*!\n * Copyright 2015-2023 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: "directive", type: i5.RouterLink, selector: ":not(a):not(area)[routerLink]", inputs: ["queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: ProcessManagementListComponent, selector: "valtimo-process-management-list" }, { kind: "component", type: ProcessManagementUploadComponent, selector: "valtimo-process-management-upload", outputs: ["reload"] }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }] });
182
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementComponent, decorators: [{
183
- type: Component,
184
- args: [{ selector: 'valtimo-process-management', template: "<!--\n ~ Copyright 2015-2023 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 class=\"main-content pt-0\">\n <div class=\"container-fluid\">\n <div class=\"text-right\">\n <div class=\"btn-group mt-m3px mb-3\">\n <button\n class=\"btn btn-secondary btn-space\"\n data-toggle=\"modal\"\n data-target=\"#uploadProcess\"\n >\n <i class=\"icon mdi mdi-upload mr-1\"></i>\n {{ 'Upload process' | translate }}\n </button>\n <button class=\"btn btn-primary btn-space mr-0\" [routerLink]=\"'create'\">\n <i class=\"icon mdi mdi-plus mr-1\"></i>\n {{ 'Create new Process' | translate }}\n </button>\n </div>\n </div>\n <valtimo-process-management-upload\n (reload)=\"processManagementList.loadProcessDefinitions()\"\n ></valtimo-process-management-upload>\n <valtimo-process-management-list #processManagementList></valtimo-process-management-list>\n </div>\n</div>\n", styles: ["/*!\n * Copyright 2015-2023 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"] }]
185
- }], ctorParameters: function () { return []; }, propDecorators: { processManagementList: [{
186
- type: ViewChild,
187
- args: ['processManagementList']
188
- }] } });
189
-
190
- /*
191
- * Copyright 2015-2023 Ritense BV, the Netherlands.
192
- *
193
- * Licensed under EUPL, Version 1.2 (the "License");
194
- * you may not use this file except in compliance with the License.
195
- * You may obtain a copy of the License at
196
- *
197
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
198
- *
199
- * Unless required by applicable law or agreed to in writing, software
200
- * distributed under the License is distributed on an "AS IS" basis,
201
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
202
- * See the License for the specific language governing permissions and
203
- * limitations under the License.
204
- */
205
- class ProcessManagementBuilderComponent {
206
- constructor(http, processService, layoutService, alertService, route, router, pageTitleService) {
207
- this.http = http;
208
- this.processService = processService;
209
- this.layoutService = layoutService;
210
- this.alertService = alertService;
211
- this.route = route;
212
- this.router = router;
213
- this.pageTitleService = pageTitleService;
214
- this.processDefinitionVersions = null;
215
- this.selectedVersion = null;
216
- this.processKey = null;
217
- this.isReadOnlyProcess$ = new BehaviorSubject(false);
218
- this.isSystemProcess$ = new BehaviorSubject(false);
219
- this.elementTemplateFiles = ['mailSendTask'];
220
- }
221
- ngOnInit() {
222
- this.init();
223
- }
224
- init() {
225
- this.processKey = this.route.snapshot.paramMap.get('key');
226
- forkJoin(this.getElementTemplates()).subscribe((elementTemplates) => {
227
- this.bpmnModeler = new Modeler({
228
- container: '#canvas',
229
- height: '90vh',
230
- additionalModules: [
231
- PropertiesPanelModule,
232
- PropertiesProviderModule,
233
- CamundaExtensionModule,
234
- ],
235
- propertiesPanel: {
236
- parent: '#properties',
237
- },
238
- moddleExtensions: {
239
- camunda: CamundaModdleDescriptor,
240
- },
241
- elementTemplates,
242
- });
243
- this.bpmnViewer = new BpmnJS();
244
- this.bpmnViewer.attachTo('#readOnlyCanvas');
245
- if (this.processKey) {
246
- this.loadProcessVersions(this.processKey);
247
- this.selectedVersion = null;
248
- }
249
- else {
250
- this.loadEmptyBpmn();
251
- }
252
- });
253
- }
254
- deploy() {
255
- this.bpmnModeler.saveXML((err, xml) => {
256
- this.processService.deployProcess(xml).subscribe(asd => {
257
- if (this.processKey) {
258
- this.loadProcessVersions(this.processKey);
259
- }
260
- else {
261
- this.router.navigate(['/processes']);
262
- }
263
- this.alertService.success('Deployment successful');
264
- this.selectedVersion = null;
265
- });
266
- });
267
- }
268
- reset() {
269
- this.bpmnModeler.destroy();
270
- this.bpmnViewer.destroy();
271
- this.init();
272
- }
273
- download() {
274
- this.bpmnModeler.saveXML((err, xml) => {
275
- const file = new Blob([xml], { type: 'text/xml' });
276
- const link = document.createElement('a');
277
- link.download = 'diagram.bpmn';
278
- link.href = window.URL.createObjectURL(file);
279
- link.click();
280
- window.URL.revokeObjectURL(link.href);
281
- link.remove();
282
- });
283
- }
284
- loadEmptyBpmn() {
285
- const url = '/assets/bpmn/initial.bpmn';
286
- this.http
287
- .get(url, {
288
- headers: { observe: 'response' },
289
- responseType: 'text',
290
- })
291
- .subscribe((xml) => {
292
- this.bpmnModeler.importXML(xml);
293
- this.bpmnViewer.importXML(xml);
294
- });
295
- }
296
- getElementTemplates() {
297
- const templateObs = [];
298
- for (const file of this.elementTemplateFiles) {
299
- templateObs.push(this.http.get(`/assets/bpmn/element-templates/${file}.json`, {
300
- headers: { observe: 'response' },
301
- responseType: 'json',
302
- }));
303
- }
304
- return templateObs;
305
- }
306
- setLatestVersion() {
307
- this.selectedVersion = this.processDefinitionVersions.reduce((acc, version) => version.version > acc.version ? version : acc);
308
- this.loadProcessBpmn();
309
- }
310
- loadProcessVersions(processDefinitionKey) {
311
- this.processService
312
- .getProcessDefinitionVersions(processDefinitionKey)
313
- .subscribe((processDefinitionVersions) => {
314
- this.processDefinitionVersions = processDefinitionVersions;
315
- this.pageTitleService.setCustomPageTitle(processDefinitionVersions[processDefinitionVersions.length - 1].name);
316
- this.setLatestVersion();
317
- });
318
- }
319
- compareProcessDefinitions(pd1, pd2) {
320
- if (pd1 === null && pd2 === null) {
321
- return true;
322
- }
323
- if (pd1 === null || pd2 === null) {
324
- return false;
325
- }
326
- return pd1.id === pd2.id;
327
- }
328
- loadProcessBpmn() {
329
- this.processService.getProcessDefinitionXml(this.selectedVersion.id).subscribe(result => {
330
- this.bpmnModeler.importXML(result['bpmn20Xml']);
331
- this.bpmnViewer.importXML(result['bpmn20Xml']);
332
- this.isReadOnlyProcess$.next(result.readOnly);
333
- this.isSystemProcess$.next(result.systemProcess);
334
- });
335
- }
336
- ngOnDestroy() {
337
- this.bpmnModeler.destroy();
338
- this.bpmnViewer.destroy();
339
- }
340
- }
341
- ProcessManagementBuilderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementBuilderComponent, deps: [{ token: i2.HttpClient }, { token: i1.ProcessService }, { token: i3.LayoutService }, { token: i4.AlertService }, { token: i5.ActivatedRoute }, { token: i5.Router }, { token: i4.PageTitleService }], target: i0.ɵɵFactoryTarget.Component });
342
- ProcessManagementBuilderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ProcessManagementBuilderComponent, selector: "valtimo-process-management-builder", ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 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 class=\"mb-5\" [ngClass]=\"{'main-content pt-0': !layoutService.isFullscreen}\">\n <div [ngClass]=\"{'container-fluid': !layoutService.isFullscreen}\">\n <div class=\"text-right\">\n <div\n class=\"btn-group mt-m3px mb-3\"\n *ngIf=\"(selectedVersion !== null || processKey === null) && !layoutService.isFullscreen\"\n >\n <button class=\"btn btn-primary btn-space\" (click)=\"download()\">\n <i class=\"icon mdi mdi-download mr-1\"></i>{{ 'processManagement.download' | translate }}\n </button>\n <button\n class=\"btn btn-success btn-space\"\n (click)=\"deploy()\"\n *ngIf=\"(isReadOnlyProcess$ | async) === false\"\n [ngClass]=\"{'mr-0': selectedVersion !== null}\"\n >\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'processManagement.deploy' | translate }}\n </button>\n <button\n *ngIf=\"selectedVersion === null\"\n class=\"btn btn-danger btn-space mr-0\"\n (click)=\"reset()\"\n >\n <i class=\"icon mdi mdi-delete mr-1\"></i>{{ 'processManagement.clear' | translate }}\n </button>\n </div>\n </div>\n\n <div class=\"modeler pl-3 pr-3 mb-3\" [ngClass]=\"{'mt-4': !layoutService.isFullscreen}\">\n <div\n class=\"row pt-4 pb-3 bg-light versions\"\n *ngIf=\"processDefinitionVersions\"\n [ngClass]=\"{'border-bottom-0': selectedVersion !== null}\"\n >\n <div class=\"col-md-4\" *ngIf=\"processDefinitionVersions.length > 0\">\n <span class=\"badge badge-pill badge-info mr-1\" *ngIf=\"isReadOnlyProcess$ | async\">\n {{ 'processManagement.readOnly' | translate }}\n </span>\n <span class=\"badge badge-pill badge-warning mr-1\" *ngIf=\"isSystemProcess$ | async\">\n {{ 'processManagement.systemProcess' | translate }}\n </span>\n </div>\n <div class=\"col-md-2 offset-md-2\">\n <label for=\"processVersion\"><strong>Version</strong></label>\n <select\n id=\"processVersion\"\n class=\"form-control select-version-control\"\n [(ngModel)]=\"selectedVersion\"\n (change)=\"loadProcessBpmn()\"\n [compareWith]=\"compareProcessDefinitions\"\n >\n <option [ngValue]=\"null\" disabled selected>Version</option>\n <option\n *ngFor=\"let processDefinition of processDefinitionVersions\"\n [ngValue]=\"processDefinition\"\n >\n {{ processDefinition.version }}\n </option>\n </select>\n </div>\n <div\n class=\"col-md-auto d-flex align-items-end text-right\"\n *ngIf=\"(selectedVersion !== null || processKey === null) && layoutService.isFullscreen\"\n >\n <div class=\"btn-group\">\n <button class=\"btn btn-primary btn-space\" (click)=\"download()\">\n <i class=\"icon mdi mdi-download mr-1\"></i\n >{{ 'processManagement.download' | translate }}\n </button>\n <button\n class=\"btn btn-success btn-space\"\n (click)=\"deploy()\"\n *ngIf=\"(isReadOnlyProcess$ | async) === false\"\n >\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'processManagement.deploy' | translate }}\n </button>\n <button *ngIf=\"!selectedVersion\" class=\"btn btn-danger btn-space\" (click)=\"reset()\">\n <i class=\"icon mdi mdi-delete mr-1\"></i>{{ 'processManagement.clear' | translate }}\n </button>\n </div>\n </div>\n <div\n *ngIf=\"selectedVersion\"\n class=\"col-md-1 fullscreen-toggle text-right\"\n [ngClass]=\"{'offset-md-2': !layoutService.isFullscreen}\"\n >\n <i\n class=\"fas\"\n [ngClass]=\"{\n 'fa-expand-arrows-alt': !layoutService.isFullscreen,\n 'fa-compress-arrows-alt': layoutService.isFullscreen\n }\"\n (click)=\"layoutService.toggleFullscreen()\"\n ></i>\n </div>\n </div>\n <div\n *ngIf=\"(isSystemProcess$ | async) && (isReadOnlyProcess$ | async)\"\n class=\"row bg-warning text-black mb-0 p-3 text-center\"\n [translate]=\"'processManagement.readOnlySystemProcessWarningMessage'\"\n ></div>\n <div\n *ngIf=\"(isSystemProcess$ | async) && (isReadOnlyProcess$ | async) === false\"\n class=\"row bg-warning text-black mb-0 p-3 text-center\"\n [translate]=\"'processManagement.systemProcessWarningMessage'\"\n ></div>\n <div [hidden]=\"!selectedVersion && processKey\" class=\"row bg-white diagram mb-3\">\n <div id=\"canvas\" class=\"col-9\" [hidden]=\"isReadOnlyProcess$ | async\"></div>\n <div id=\"properties\" class=\"col-3 pr-0\" [hidden]=\"isReadOnlyProcess$ | async\"></div>\n <div\n id=\"readOnlyCanvas\"\n class=\"col-12\"\n [hidden]=\"(isReadOnlyProcess$ | async) === false\"\n ></div>\n </div>\n </div>\n </div>\n</div>\n", styles: ["/*!\n * Copyright 2015-2023 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 */.versions,.diagram{border:1px solid #dee2e6}.process-title{color:#6b6b6b;font-size:1.5rem}.fullscreen-toggle{font-size:2rem}.fullscreen-toggle>i{cursor:pointer}.modeler{height:90vh}.select-version-control{width:90px}#properties{border-left:1px solid #dee2e6;padding-left:0}#readOnlyCanvas{height:90vh}\n"], dependencies: [{ kind: "directive", type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i7.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i7.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i7.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i7.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i7.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i4$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "pipe", type: i6.AsyncPipe, name: "async" }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None });
343
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementBuilderComponent, decorators: [{
344
- type: Component,
345
- args: [{ selector: 'valtimo-process-management-builder', encapsulation: ViewEncapsulation.None, template: "<!--\n ~ Copyright 2015-2023 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 class=\"mb-5\" [ngClass]=\"{'main-content pt-0': !layoutService.isFullscreen}\">\n <div [ngClass]=\"{'container-fluid': !layoutService.isFullscreen}\">\n <div class=\"text-right\">\n <div\n class=\"btn-group mt-m3px mb-3\"\n *ngIf=\"(selectedVersion !== null || processKey === null) && !layoutService.isFullscreen\"\n >\n <button class=\"btn btn-primary btn-space\" (click)=\"download()\">\n <i class=\"icon mdi mdi-download mr-1\"></i>{{ 'processManagement.download' | translate }}\n </button>\n <button\n class=\"btn btn-success btn-space\"\n (click)=\"deploy()\"\n *ngIf=\"(isReadOnlyProcess$ | async) === false\"\n [ngClass]=\"{'mr-0': selectedVersion !== null}\"\n >\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'processManagement.deploy' | translate }}\n </button>\n <button\n *ngIf=\"selectedVersion === null\"\n class=\"btn btn-danger btn-space mr-0\"\n (click)=\"reset()\"\n >\n <i class=\"icon mdi mdi-delete mr-1\"></i>{{ 'processManagement.clear' | translate }}\n </button>\n </div>\n </div>\n\n <div class=\"modeler pl-3 pr-3 mb-3\" [ngClass]=\"{'mt-4': !layoutService.isFullscreen}\">\n <div\n class=\"row pt-4 pb-3 bg-light versions\"\n *ngIf=\"processDefinitionVersions\"\n [ngClass]=\"{'border-bottom-0': selectedVersion !== null}\"\n >\n <div class=\"col-md-4\" *ngIf=\"processDefinitionVersions.length > 0\">\n <span class=\"badge badge-pill badge-info mr-1\" *ngIf=\"isReadOnlyProcess$ | async\">\n {{ 'processManagement.readOnly' | translate }}\n </span>\n <span class=\"badge badge-pill badge-warning mr-1\" *ngIf=\"isSystemProcess$ | async\">\n {{ 'processManagement.systemProcess' | translate }}\n </span>\n </div>\n <div class=\"col-md-2 offset-md-2\">\n <label for=\"processVersion\"><strong>Version</strong></label>\n <select\n id=\"processVersion\"\n class=\"form-control select-version-control\"\n [(ngModel)]=\"selectedVersion\"\n (change)=\"loadProcessBpmn()\"\n [compareWith]=\"compareProcessDefinitions\"\n >\n <option [ngValue]=\"null\" disabled selected>Version</option>\n <option\n *ngFor=\"let processDefinition of processDefinitionVersions\"\n [ngValue]=\"processDefinition\"\n >\n {{ processDefinition.version }}\n </option>\n </select>\n </div>\n <div\n class=\"col-md-auto d-flex align-items-end text-right\"\n *ngIf=\"(selectedVersion !== null || processKey === null) && layoutService.isFullscreen\"\n >\n <div class=\"btn-group\">\n <button class=\"btn btn-primary btn-space\" (click)=\"download()\">\n <i class=\"icon mdi mdi-download mr-1\"></i\n >{{ 'processManagement.download' | translate }}\n </button>\n <button\n class=\"btn btn-success btn-space\"\n (click)=\"deploy()\"\n *ngIf=\"(isReadOnlyProcess$ | async) === false\"\n >\n <i class=\"icon mdi mdi-upload mr-1\"></i>{{ 'processManagement.deploy' | translate }}\n </button>\n <button *ngIf=\"!selectedVersion\" class=\"btn btn-danger btn-space\" (click)=\"reset()\">\n <i class=\"icon mdi mdi-delete mr-1\"></i>{{ 'processManagement.clear' | translate }}\n </button>\n </div>\n </div>\n <div\n *ngIf=\"selectedVersion\"\n class=\"col-md-1 fullscreen-toggle text-right\"\n [ngClass]=\"{'offset-md-2': !layoutService.isFullscreen}\"\n >\n <i\n class=\"fas\"\n [ngClass]=\"{\n 'fa-expand-arrows-alt': !layoutService.isFullscreen,\n 'fa-compress-arrows-alt': layoutService.isFullscreen\n }\"\n (click)=\"layoutService.toggleFullscreen()\"\n ></i>\n </div>\n </div>\n <div\n *ngIf=\"(isSystemProcess$ | async) && (isReadOnlyProcess$ | async)\"\n class=\"row bg-warning text-black mb-0 p-3 text-center\"\n [translate]=\"'processManagement.readOnlySystemProcessWarningMessage'\"\n ></div>\n <div\n *ngIf=\"(isSystemProcess$ | async) && (isReadOnlyProcess$ | async) === false\"\n class=\"row bg-warning text-black mb-0 p-3 text-center\"\n [translate]=\"'processManagement.systemProcessWarningMessage'\"\n ></div>\n <div [hidden]=\"!selectedVersion && processKey\" class=\"row bg-white diagram mb-3\">\n <div id=\"canvas\" class=\"col-9\" [hidden]=\"isReadOnlyProcess$ | async\"></div>\n <div id=\"properties\" class=\"col-3 pr-0\" [hidden]=\"isReadOnlyProcess$ | async\"></div>\n <div\n id=\"readOnlyCanvas\"\n class=\"col-12\"\n [hidden]=\"(isReadOnlyProcess$ | async) === false\"\n ></div>\n </div>\n </div>\n </div>\n</div>\n", styles: ["/*!\n * Copyright 2015-2023 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 */.versions,.diagram{border:1px solid #dee2e6}.process-title{color:#6b6b6b;font-size:1.5rem}.fullscreen-toggle{font-size:2rem}.fullscreen-toggle>i{cursor:pointer}.modeler{height:90vh}.select-version-control{width:90px}#properties{border-left:1px solid #dee2e6;padding-left:0}#readOnlyCanvas{height:90vh}\n"] }]
346
- }], ctorParameters: function () { return [{ type: i2.HttpClient }, { type: i1.ProcessService }, { type: i3.LayoutService }, { type: i4.AlertService }, { type: i5.ActivatedRoute }, { type: i5.Router }, { type: i4.PageTitleService }]; } });
347
-
348
- /*
349
- * Copyright 2015-2023 Ritense BV, the Netherlands.
350
- *
351
- * Licensed under EUPL, Version 1.2 (the "License");
352
- * you may not use this file except in compliance with the License.
353
- * You may obtain a copy of the License at
354
- *
355
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
356
- *
357
- * Unless required by applicable law or agreed to in writing, software
358
- * distributed under the License is distributed on an "AS IS" basis,
359
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
360
- * See the License for the specific language governing permissions and
361
- * limitations under the License.
362
- */
363
- const routes = [
364
- {
365
- path: 'processes',
366
- component: ProcessManagementComponent,
367
- canActivate: [AuthGuardService],
368
- data: { title: 'Processes', roles: [ROLE_ADMIN] },
369
- },
370
- {
371
- path: 'processes/create',
372
- component: ProcessManagementBuilderComponent,
373
- canActivate: [AuthGuardService],
374
- data: { title: 'Create new Process', roles: [ROLE_ADMIN] },
375
- },
376
- {
377
- path: 'processes/process/:key',
378
- component: ProcessManagementBuilderComponent,
379
- canActivate: [AuthGuardService],
380
- data: { title: 'Process details', roles: [ROLE_ADMIN], customPageTitle: true },
381
- },
382
- ];
383
- class ProcessManagementRoutingModule {
384
- }
385
- ProcessManagementRoutingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
386
- ProcessManagementRoutingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementRoutingModule, imports: [CommonModule, i5.RouterModule], exports: [RouterModule] });
387
- ProcessManagementRoutingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementRoutingModule, imports: [CommonModule, RouterModule.forChild(routes), RouterModule] });
388
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementRoutingModule, decorators: [{
389
- type: NgModule,
390
- args: [{
391
- declarations: [],
392
- imports: [CommonModule, RouterModule.forChild(routes)],
393
- exports: [RouterModule],
394
- }]
395
- }] });
396
-
397
- /*
398
- * Copyright 2015-2023 Ritense BV, the Netherlands.
399
- *
400
- * Licensed under EUPL, Version 1.2 (the "License");
401
- * you may not use this file except in compliance with the License.
402
- * You may obtain a copy of the License at
403
- *
404
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
405
- *
406
- * Unless required by applicable law or agreed to in writing, software
407
- * distributed under the License is distributed on an "AS IS" basis,
408
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
409
- * See the License for the specific language governing permissions and
410
- * limitations under the License.
411
- */
412
- class ProcessManagementModule {
413
- }
414
- ProcessManagementModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
415
- ProcessManagementModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementModule, declarations: [ProcessManagementComponent,
416
- ProcessManagementBuilderComponent,
417
- ProcessManagementListComponent,
418
- ProcessManagementUploadComponent], imports: [CommonModule,
419
- ProcessManagementRoutingModule,
420
- WidgetModule,
421
- ListModule,
422
- FormsModule,
423
- TranslateModule], exports: [ProcessManagementComponent] });
424
- ProcessManagementModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementModule, imports: [CommonModule,
425
- ProcessManagementRoutingModule,
426
- WidgetModule,
427
- ListModule,
428
- FormsModule,
429
- TranslateModule] });
430
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ProcessManagementModule, decorators: [{
431
- type: NgModule,
432
- args: [{
433
- declarations: [
434
- ProcessManagementComponent,
435
- ProcessManagementBuilderComponent,
436
- ProcessManagementListComponent,
437
- ProcessManagementUploadComponent,
438
- ],
439
- imports: [
440
- CommonModule,
441
- ProcessManagementRoutingModule,
442
- WidgetModule,
443
- ListModule,
444
- FormsModule,
445
- TranslateModule,
446
- ],
447
- exports: [ProcessManagementComponent],
448
- }]
449
- }] });
450
-
451
- /*
452
- * Copyright 2015-2023 Ritense BV, the Netherlands.
453
- *
454
- * Licensed under EUPL, Version 1.2 (the "License");
455
- * you may not use this file except in compliance with the License.
456
- * You may obtain a copy of the License at
457
- *
458
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
459
- *
460
- * Unless required by applicable law or agreed to in writing, software
461
- * distributed under the License is distributed on an "AS IS" basis,
462
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
463
- * See the License for the specific language governing permissions and
464
- * limitations under the License.
465
- */
466
-
467
- /**
468
- * Generated bundle index. Do not edit.
469
- */
470
-
471
- export { ProcessManagementComponent, ProcessManagementModule };
472
- //# sourceMappingURL=valtimo-process-management.mjs.map