@valtimo/milestone 4.15.2-next-main.15 → 4.15.3-next-main.16

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 (31) hide show
  1. package/README.md +13 -6
  2. package/bundles/valtimo-milestone.umd.js +1011 -971
  3. package/bundles/valtimo-milestone.umd.js.map +1 -1
  4. package/bundles/valtimo-milestone.umd.min.js +1 -1
  5. package/bundles/valtimo-milestone.umd.min.js.map +1 -1
  6. package/esm2015/lib/milestone-create/milestone-create.component.js +110 -102
  7. package/esm2015/lib/milestone-edit/milestone-edit.component.js +150 -141
  8. package/esm2015/lib/milestone-list/milestone-list.component.js +90 -88
  9. package/esm2015/lib/milestone-routing.module.js +69 -72
  10. package/esm2015/lib/milestone-set-create/milestone-set-create.component.js +61 -61
  11. package/esm2015/lib/milestone-set-edit/milestone-set-edit.component.js +87 -85
  12. package/esm2015/lib/milestone.component.js +29 -31
  13. package/esm2015/lib/milestone.module.js +55 -49
  14. package/esm2015/lib/milestone.service.js +72 -72
  15. package/esm2015/public-api.js +22 -22
  16. package/esm2015/valtimo-milestone.js +11 -11
  17. package/fesm2015/valtimo-milestone.js +662 -640
  18. package/fesm2015/valtimo-milestone.js.map +1 -1
  19. package/lib/milestone-create/milestone-create.component.d.ts +28 -28
  20. package/lib/milestone-edit/milestone-edit.component.d.ts +33 -33
  21. package/lib/milestone-list/milestone-list.component.d.ts +23 -23
  22. package/lib/milestone-routing.module.d.ts +2 -2
  23. package/lib/milestone-set-create/milestone-set-create.component.d.ts +19 -19
  24. package/lib/milestone-set-edit/milestone-set-edit.component.d.ts +23 -23
  25. package/lib/milestone.component.d.ts +5 -5
  26. package/lib/milestone.module.d.ts +2 -2
  27. package/lib/milestone.service.d.ts +21 -21
  28. package/package.json +1 -1
  29. package/public-api.d.ts +3 -3
  30. package/valtimo-milestone.d.ts +10 -10
  31. package/valtimo-milestone.metadata.json +1 -1
@@ -4,999 +4,1039 @@
4
4
  (global = global || self, factory((global.valtimo = global.valtimo || {}, global.valtimo.milestone = {}), global.ng.core, global.ng.common.http, global.config, global.ng.forms, global.components, global.ng.router, global.ng.common, global.security, global.process, global.rxjs.operators, global.contract, global.rxjs, global.ngxColorPicker, global.core$1));
5
5
  }(this, (function (exports, i0, i2, i1, forms, components, router, common, security, process, operators, contract, rxjs, ngxColorPicker, core) { 'use strict';
6
6
 
7
- /*
8
- * Copyright 2015-2020 Ritense BV, the Netherlands.
9
- *
10
- * Licensed under EUPL, Version 1.2 (the "License");
11
- * you may not use this file except in compliance with the License.
12
- * You may obtain a copy of the License at
13
- *
14
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
15
- *
16
- * Unless required by applicable law or agreed to in writing, software
17
- * distributed under the License is distributed on an "AS IS" basis,
18
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19
- * See the License for the specific language governing permissions and
20
- * limitations under the License.
21
- */
22
- var MilestoneService = /** @class */ (function () {
23
- function MilestoneService(configService, http) {
24
- this.configService = configService;
25
- this.http = http;
26
- this.valtimoApiConfig = configService.config.valtimoApi;
27
- }
28
- MilestoneService.prototype.getMilestones = function () {
29
- return this.http.get(this.valtimoApiConfig.endpointUri + "milestones");
30
- };
31
- MilestoneService.prototype.getMilestone = function (milestoneId) {
32
- return this.http.get(this.valtimoApiConfig.endpointUri + "milestones/" + milestoneId);
33
- };
34
- MilestoneService.prototype.createMilestone = function (milestone) {
35
- return this.http.post(this.valtimoApiConfig.endpointUri + "milestones", milestone);
36
- };
37
- MilestoneService.prototype.updateMilestone = function (milestone) {
38
- return this.http.post(this.valtimoApiConfig.endpointUri + "milestones", milestone);
39
- };
40
- MilestoneService.prototype.deleteMilestone = function (milestoneId) {
41
- return this.http.delete(this.valtimoApiConfig.endpointUri + "milestones/" + milestoneId);
42
- };
43
- MilestoneService.prototype.getMilestoneSets = function () {
44
- return this.http.get(this.valtimoApiConfig.endpointUri + "milestone-sets");
45
- };
46
- MilestoneService.prototype.getMilestoneSet = function (milestoneSetId) {
47
- return this.http.get(this.valtimoApiConfig.endpointUri + "milestone-sets/" + milestoneSetId);
48
- };
49
- MilestoneService.prototype.createMilestoneSet = function (milestoneSet) {
50
- return this.http.post(this.valtimoApiConfig.endpointUri + "milestone-sets", milestoneSet);
51
- };
52
- MilestoneService.prototype.updateMilestoneSet = function (milestoneSet) {
53
- return this.http.post(this.valtimoApiConfig.endpointUri + "milestone-sets", milestoneSet);
54
- };
55
- MilestoneService.prototype.deleteMilestoneSet = function (milestoneSetId) {
56
- return this.http.delete(this.valtimoApiConfig.endpointUri + "milestone-sets/" + milestoneSetId);
57
- };
58
- MilestoneService.prototype.getFlownodes = function (processDefinitionId) {
59
- return this.http.get(this.valtimoApiConfig.endpointUri + "milestones/" + processDefinitionId + "/flownodes");
60
- };
61
- return MilestoneService;
62
- }());
63
- MilestoneService.ɵprov = i0.ɵɵdefineInjectable({ factory: function MilestoneService_Factory() { return new MilestoneService(i0.ɵɵinject(i1.ConfigService), i0.ɵɵinject(i2.HttpClient)); }, token: MilestoneService, providedIn: "root" });
64
- MilestoneService.decorators = [
65
- { type: i0.Injectable, args: [{
66
- providedIn: 'root'
67
- },] }
68
- ];
69
- MilestoneService.ctorParameters = function () { return [
70
- { type: i1.ConfigService },
71
- { type: i2.HttpClient }
7
+ /*
8
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
9
+ *
10
+ * Licensed under EUPL, Version 1.2 (the "License");
11
+ * you may not use this file except in compliance with the License.
12
+ * You may obtain a copy of the License at
13
+ *
14
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
15
+ *
16
+ * Unless required by applicable law or agreed to in writing, software
17
+ * distributed under the License is distributed on an "AS IS" basis,
18
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19
+ * See the License for the specific language governing permissions and
20
+ * limitations under the License.
21
+ */
22
+ var MilestoneService = /** @class */ (function () {
23
+ function MilestoneService(configService, http) {
24
+ this.configService = configService;
25
+ this.http = http;
26
+ this.valtimoApiConfig = configService.config.valtimoApi;
27
+ }
28
+ MilestoneService.prototype.getMilestones = function () {
29
+ return this.http.get(this.valtimoApiConfig.endpointUri + "milestones");
30
+ };
31
+ MilestoneService.prototype.getMilestone = function (milestoneId) {
32
+ return this.http.get(this.valtimoApiConfig.endpointUri + "milestones/" + milestoneId);
33
+ };
34
+ MilestoneService.prototype.createMilestone = function (milestone) {
35
+ return this.http.post(this.valtimoApiConfig.endpointUri + "milestones", milestone);
36
+ };
37
+ MilestoneService.prototype.updateMilestone = function (milestone) {
38
+ return this.http.post(this.valtimoApiConfig.endpointUri + "milestones", milestone);
39
+ };
40
+ MilestoneService.prototype.deleteMilestone = function (milestoneId) {
41
+ return this.http.delete(this.valtimoApiConfig.endpointUri + "milestones/" + milestoneId);
42
+ };
43
+ MilestoneService.prototype.getMilestoneSets = function () {
44
+ return this.http.get(this.valtimoApiConfig.endpointUri + "milestone-sets");
45
+ };
46
+ MilestoneService.prototype.getMilestoneSet = function (milestoneSetId) {
47
+ return this.http.get(this.valtimoApiConfig.endpointUri + "milestone-sets/" + milestoneSetId);
48
+ };
49
+ MilestoneService.prototype.createMilestoneSet = function (milestoneSet) {
50
+ return this.http.post(this.valtimoApiConfig.endpointUri + "milestone-sets", milestoneSet);
51
+ };
52
+ MilestoneService.prototype.updateMilestoneSet = function (milestoneSet) {
53
+ return this.http.post(this.valtimoApiConfig.endpointUri + "milestone-sets", milestoneSet);
54
+ };
55
+ MilestoneService.prototype.deleteMilestoneSet = function (milestoneSetId) {
56
+ return this.http.delete(this.valtimoApiConfig.endpointUri + "milestone-sets/" + milestoneSetId);
57
+ };
58
+ MilestoneService.prototype.getFlownodes = function (processDefinitionId) {
59
+ return this.http.get(this.valtimoApiConfig.endpointUri + "milestones/" + processDefinitionId + "/flownodes");
60
+ };
61
+ return MilestoneService;
62
+ }());
63
+ MilestoneService.ɵprov = i0.ɵɵdefineInjectable({ factory: function MilestoneService_Factory() { return new MilestoneService(i0.ɵɵinject(i1.ConfigService), i0.ɵɵinject(i2.HttpClient)); }, token: MilestoneService, providedIn: "root" });
64
+ MilestoneService.decorators = [
65
+ { type: i0.Injectable, args: [{
66
+ providedIn: 'root',
67
+ },] }
68
+ ];
69
+ MilestoneService.ctorParameters = function () { return [
70
+ { type: i1.ConfigService },
71
+ { type: i2.HttpClient }
72
72
  ]; };
73
73
 
74
- /*
75
- * Copyright 2015-2020 Ritense BV, the Netherlands.
76
- *
77
- * Licensed under EUPL, Version 1.2 (the "License");
78
- * you may not use this file except in compliance with the License.
79
- * You may obtain a copy of the License at
80
- *
81
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
82
- *
83
- * Unless required by applicable law or agreed to in writing, software
84
- * distributed under the License is distributed on an "AS IS" basis,
85
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
86
- * See the License for the specific language governing permissions and
87
- * limitations under the License.
88
- */
89
- var MilestoneComponent = /** @class */ (function () {
90
- function MilestoneComponent() {
91
- }
92
- MilestoneComponent.prototype.ngOnInit = function () {
93
- };
94
- return MilestoneComponent;
95
- }());
96
- MilestoneComponent.decorators = [
97
- { type: i0.Component, args: [{
98
- selector: 'valtimo-milestone',
99
- template: "<!--\n ~ Copyright 2015-2020 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 [routerLink]=\"'sets/create'\" class=\"btn btn-primary btn-space\">\n <i class=\"icon mdi mdi-plus\"></i> &nbsp;\n <span>{{ 'Create new Milestone Set' | translate }}</span>\n </button>\n <button [routerLink]=\"'create'\" class=\"btn btn-primary btn-space mr-0\">\n <i class=\"icon mdi mdi-plus\"></i> &nbsp;\n <span>{{ 'Create new Milestone' | translate }}</span>\n </button>\n </div>\n </div>\n <valtimo-milestone-list></valtimo-milestone-list>\n </div>\n</div>\n",
100
- styles: ["/*!\n * Copyright 2015-2020 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 */"]
101
- },] }
102
- ];
74
+ /*
75
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
76
+ *
77
+ * Licensed under EUPL, Version 1.2 (the "License");
78
+ * you may not use this file except in compliance with the License.
79
+ * You may obtain a copy of the License at
80
+ *
81
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
82
+ *
83
+ * Unless required by applicable law or agreed to in writing, software
84
+ * distributed under the License is distributed on an "AS IS" basis,
85
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
86
+ * See the License for the specific language governing permissions and
87
+ * limitations under the License.
88
+ */
89
+ var MilestoneComponent = /** @class */ (function () {
90
+ function MilestoneComponent() {
91
+ }
92
+ MilestoneComponent.prototype.ngOnInit = function () { };
93
+ return MilestoneComponent;
94
+ }());
95
+ MilestoneComponent.decorators = [
96
+ { type: i0.Component, args: [{
97
+ selector: 'valtimo-milestone',
98
+ template: "<!--\n ~ Copyright 2015-2020 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 [routerLink]=\"'sets/create'\" class=\"btn btn-primary btn-space\">\n <i class=\"icon mdi mdi-plus\"></i> &nbsp;\n <span>{{ 'Create new Milestone Set' | translate }}</span>\n </button>\n <button [routerLink]=\"'create'\" class=\"btn btn-primary btn-space mr-0\">\n <i class=\"icon mdi mdi-plus\"></i> &nbsp;\n <span>{{ 'Create new Milestone' | translate }}</span>\n </button>\n </div>\n </div>\n <valtimo-milestone-list></valtimo-milestone-list>\n </div>\n</div>\n",
99
+ styles: ["/*!\n * Copyright 2015-2020 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 */"]
100
+ },] }
101
+ ];
103
102
  MilestoneComponent.ctorParameters = function () { return []; };
104
103
 
105
- /*
106
- * Copyright 2015-2020 Ritense BV, the Netherlands.
107
- *
108
- * Licensed under EUPL, Version 1.2 (the "License");
109
- * you may not use this file except in compliance with the License.
110
- * You may obtain a copy of the License at
111
- *
112
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
113
- *
114
- * Unless required by applicable law or agreed to in writing, software
115
- * distributed under the License is distributed on an "AS IS" basis,
116
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
117
- * See the License for the specific language governing permissions and
118
- * limitations under the License.
119
- */
120
- var MilestoneSetCreateComponent = /** @class */ (function () {
121
- function MilestoneSetCreateComponent(milestoneService, formBuilder, router, alertService) {
122
- this.milestoneService = milestoneService;
123
- this.formBuilder = formBuilder;
124
- this.router = router;
125
- this.alertService = alertService;
126
- }
127
- Object.defineProperty(MilestoneSetCreateComponent.prototype, "formControls", {
128
- get: function () {
129
- return this.form.controls;
130
- },
131
- enumerable: false,
132
- configurable: true
133
- });
134
- MilestoneSetCreateComponent.prototype.ngOnInit = function () {
135
- this.form = this.formBuilder.group({
136
- title: new forms.FormControl('', forms.Validators.required)
137
- });
138
- };
139
- MilestoneSetCreateComponent.prototype.reset = function () {
140
- this.form.setValue({
141
- title: ''
142
- });
143
- };
144
- MilestoneSetCreateComponent.prototype.createMilestoneSet = function () {
145
- var _this = this;
146
- this.milestoneService.createMilestoneSet(this.form.value).subscribe(function () {
147
- _this.router.navigate(['/milestones']);
148
- _this.alertService.success('New Milestone set has been created');
149
- });
150
- };
151
- return MilestoneSetCreateComponent;
152
- }());
153
- MilestoneSetCreateComponent.decorators = [
154
- { type: i0.Component, args: [{
155
- selector: 'valtimo-milestone-set-create',
156
- template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"createMilestoneSet()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input type=\"text\" id=\"title\" formControlName=\"title\"\n class=\"form-control\" placeholder=\"Milestone set title\"\n [ngClass]=\"{'is-valid': formControls.title.touched && formControls.title.valid, 'is-invalid': formControls.title.touched && formControls.title.errors}\"\n required/>\n <div *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
157
- styles: ["/*!\n * Copyright 2015-2020 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 */"]
158
- },] }
159
- ];
160
- MilestoneSetCreateComponent.ctorParameters = function () { return [
161
- { type: MilestoneService },
162
- { type: forms.FormBuilder },
163
- { type: router.Router },
164
- { type: components.AlertService }
104
+ /*
105
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
106
+ *
107
+ * Licensed under EUPL, Version 1.2 (the "License");
108
+ * you may not use this file except in compliance with the License.
109
+ * You may obtain a copy of the License at
110
+ *
111
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
112
+ *
113
+ * Unless required by applicable law or agreed to in writing, software
114
+ * distributed under the License is distributed on an "AS IS" basis,
115
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
116
+ * See the License for the specific language governing permissions and
117
+ * limitations under the License.
118
+ */
119
+ var MilestoneSetCreateComponent = /** @class */ (function () {
120
+ function MilestoneSetCreateComponent(milestoneService, formBuilder, router, alertService) {
121
+ this.milestoneService = milestoneService;
122
+ this.formBuilder = formBuilder;
123
+ this.router = router;
124
+ this.alertService = alertService;
125
+ }
126
+ Object.defineProperty(MilestoneSetCreateComponent.prototype, "formControls", {
127
+ get: function () {
128
+ return this.form.controls;
129
+ },
130
+ enumerable: false,
131
+ configurable: true
132
+ });
133
+ MilestoneSetCreateComponent.prototype.ngOnInit = function () {
134
+ this.form = this.formBuilder.group({
135
+ title: new forms.FormControl('', forms.Validators.required),
136
+ });
137
+ };
138
+ MilestoneSetCreateComponent.prototype.reset = function () {
139
+ this.form.setValue({
140
+ title: '',
141
+ });
142
+ };
143
+ MilestoneSetCreateComponent.prototype.createMilestoneSet = function () {
144
+ var _this = this;
145
+ this.milestoneService.createMilestoneSet(this.form.value).subscribe(function () {
146
+ _this.router.navigate(['/milestones']);
147
+ _this.alertService.success('New Milestone set has been created');
148
+ });
149
+ };
150
+ return MilestoneSetCreateComponent;
151
+ }());
152
+ MilestoneSetCreateComponent.decorators = [
153
+ { type: i0.Component, args: [{
154
+ selector: 'valtimo-milestone-set-create',
155
+ template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"createMilestoneSet()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n type=\"text\"\n id=\"title\"\n formControlName=\"title\"\n class=\"form-control\"\n placeholder=\"Milestone set title\"\n [ngClass]=\"{\n 'is-valid': formControls.title.touched && formControls.title.valid,\n 'is-invalid': formControls.title.touched && formControls.title.errors\n }\"\n required\n />\n <div\n *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">\n Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
156
+ styles: ["/*!\n * Copyright 2015-2020 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 */"]
157
+ },] }
158
+ ];
159
+ MilestoneSetCreateComponent.ctorParameters = function () { return [
160
+ { type: MilestoneService },
161
+ { type: forms.FormBuilder },
162
+ { type: router.Router },
163
+ { type: components.AlertService }
165
164
  ]; };
166
165
 
167
- /*
168
- * Copyright 2015-2020 Ritense BV, the Netherlands.
169
- *
170
- * Licensed under EUPL, Version 1.2 (the "License");
171
- * you may not use this file except in compliance with the License.
172
- * You may obtain a copy of the License at
173
- *
174
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
175
- *
176
- * Unless required by applicable law or agreed to in writing, software
177
- * distributed under the License is distributed on an "AS IS" basis,
178
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
179
- * See the License for the specific language governing permissions and
180
- * limitations under the License.
181
- */
182
- var MilestoneCreateComponent = /** @class */ (function () {
183
- function MilestoneCreateComponent(milestoneService, formBuilder, router, alertService, processService) {
184
- this.milestoneService = milestoneService;
185
- this.formBuilder = formBuilder;
186
- this.router = router;
187
- this.alertService = alertService;
188
- this.processService = processService;
189
- this.milestoneSets = [];
190
- this.processDefinitions = [];
191
- this.taskDefinitions = [];
192
- }
193
- Object.defineProperty(MilestoneCreateComponent.prototype, "formControls", {
194
- get: function () {
195
- return this.form.controls;
196
- },
197
- enumerable: false,
198
- configurable: true
199
- });
200
- MilestoneCreateComponent.prototype.ngOnInit = function () {
201
- this.form = this.formBuilder.group({
202
- milestoneSet: new forms.FormControl('', forms.Validators.required),
203
- title: new forms.FormControl('', forms.Validators.required),
204
- processDefinitionKey: new forms.FormControl('', forms.Validators.required),
205
- taskDefinitionKey: new forms.FormControl('', forms.Validators.required),
206
- plannedIntervalInDays: new forms.FormControl('', [forms.Validators.required, forms.Validators.pattern('^[0-9]*$')]),
207
- color: new forms.FormControl('', [forms.Validators.required, forms.Validators.pattern('^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$')])
208
- });
209
- this.getMilestoneSets();
210
- this.getMilestones();
211
- };
212
- MilestoneCreateComponent.prototype.reset = function () {
213
- this.form.patchValue({
214
- milestoneSet: '',
215
- title: '',
216
- processDefinitionKey: '',
217
- taskDefinitionKey: '',
218
- plannedIntervalInDays: '',
219
- color: ''
220
- });
221
- };
222
- MilestoneCreateComponent.prototype.getMilestoneSets = function () {
223
- var _this = this;
224
- this.milestoneService.getMilestoneSets().subscribe(function (milesetoneSets) {
225
- _this.milestoneSets = milesetoneSets;
226
- });
227
- };
228
- MilestoneCreateComponent.prototype.getMilestones = function () {
229
- var _this = this;
230
- this.processService.getProcessDefinitions().subscribe(function (processDefinitions) {
231
- _this.processDefinitions = processDefinitions;
232
- });
233
- };
234
- MilestoneCreateComponent.prototype.getFlownodes = function (processDefinitionId) {
235
- var _this = this;
236
- if (processDefinitionId) {
237
- this.milestoneService.getFlownodes(processDefinitionId).subscribe(function (flowNodes) {
238
- _this.taskDefinitions = flowNodes['flowNodeMap'];
239
- _this.form.controls.taskDefinitionKey.setValue('');
240
- });
241
- }
242
- };
243
- MilestoneCreateComponent.prototype.createMilestone = function () {
244
- var _this = this;
245
- var milestone = this.form.value;
246
- milestone.processDefinitionKey = milestone.processDefinitionKey['key'];
247
- milestone.id = null;
248
- this.milestoneService.createMilestone(milestone).subscribe(function () {
249
- _this.router.navigate(['/milestones']);
250
- _this.alertService.success('New Milestone has been created');
251
- }, function (err) {
252
- _this.alertService.error('Error creating new milestone');
253
- });
254
- };
255
- return MilestoneCreateComponent;
256
- }());
257
- MilestoneCreateComponent.decorators = [
258
- { type: i0.Component, args: [{
259
- selector: 'valtimo-milestone-create',
260
- template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"createMilestone()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Milestone set</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select type=\"text\" id=\"milestoneSet\" formControlName=\"milestoneSet\"\n class=\"form-control\"\n [ngClass]=\"{'is-valid': formControls.milestoneSet.touched && formControls.milestoneSet.valid, 'is-invalid': formControls.milestoneSet.touched && formControls.milestoneSet.errors}\"\n required>\n <option value=\"\" selected disabled>Choose a Milestone set</option>\n <option *ngFor=\"let milestoneSet of milestoneSets\" [value]=\"milestoneSet.id\">{{milestoneSet.title}} ({{milestoneSet.id}})</option>\n </select>\n <div *ngIf=\"formControls.milestoneSet.touched && formControls.milestoneSet.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.milestoneSet.errors.required\">Milestone set is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input type=\"text\" id=\"title\" formControlName=\"title\"\n class=\"form-control\" placeholder=\"Milestone title\"\n [ngClass]=\"{'is-valid': formControls.title.touched && formControls.title.valid, 'is-invalid': formControls.title.touched && formControls.title.errors}\"\n required/>\n <div *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\">Process definition</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select type=\"text\" id=\"process\" formControlName=\"processDefinitionKey\"\n class=\"form-control\" (ngModelChange)=\"getFlownodes($event.id)\"\n [ngClass]=\"{'is-valid': formControls.processDefinitionKey.touched && formControls.processDefinitionKey.valid, 'is-invalid': formControls.processDefinitionKey.touched && formControls.processDefinitionKey.errors}\"\n required>\n <option value=\"\" selected disabled>Choose a process</option>\n <option *ngFor=\"let processDefinition of processDefinitions\" [ngValue]=\"processDefinition\">{{processDefinition.name}} ({{processDefinition.key}})</option>\n </select>\n <div *ngIf=\"formControls.processDefinitionKey.touched && formControls.processDefinitionKey.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.processDefinitionKey.errors.required\">Process is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\">Task</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select type=\"text\" id=\"task\" formControlName=\"taskDefinitionKey\"\n class=\"form-control\"\n [ngClass]=\"{'is-valid': formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.valid, 'is-invalid': formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.errors}\"\n required>\n <option value=\"\" selected disabled>Choose a task</option>\n <option *ngFor=\"let taskDefinition of taskDefinitions |keyvalue\" [value]=\"taskDefinition.key\">{{taskDefinition.value}} ({{taskDefinition.key}})</option>\n </select>\n <div *ngIf=\"formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.taskDefinitionKey.errors.required\">Task is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"interval\">Interval (in days)</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input type=\"text\" id=\"interval\" formControlName=\"plannedIntervalInDays\"\n class=\"form-control\" placeholder=\"Interval (in days)\"\n [ngClass]=\"{'is-valid': formControls.plannedIntervalInDays.touched && formControls.plannedIntervalInDays.valid, 'is-invalid': formControls.plannedIntervalInDays.touched && formControls.plannedIntervalInDays.errors}\"\n required/>\n <div *ngIf=\"formControls.plannedIntervalInDays.touched && formControls.plannedIntervalInDays.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.required\">Interval is required</div>\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.pattern\">Interval is not a valid number</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"color\">Color</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n\n <input [colorPicker]=\"form.value.color\"\n (colorPickerChange)=\"form.controls.color.setValue($event)\"\n [style.background]=\"form.value.color\"\n type=\"text\" id=\"color\" formControlName=\"color\"\n class=\"form-control\" placeholder=\"Color\"\n [ngClass]=\"{'is-valid': formControls.color.touched && formControls.color.valid, 'is-invalid': formControls.color.touched && formControls.color.errors}\"\n required/>\n <div *ngIf=\"formControls.color.touched && formControls.color.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.color.errors.required\">Interval is required</div>\n <div *ngIf=\"formControls.color.errors.pattern\">Color is not a valid hex code</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
261
- styles: ["/*!\n * Copyright 2015-2020 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 */"]
262
- },] }
263
- ];
264
- MilestoneCreateComponent.ctorParameters = function () { return [
265
- { type: MilestoneService },
266
- { type: forms.FormBuilder },
267
- { type: router.Router },
268
- { type: components.AlertService },
269
- { type: process.ProcessService }
166
+ /*
167
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
168
+ *
169
+ * Licensed under EUPL, Version 1.2 (the "License");
170
+ * you may not use this file except in compliance with the License.
171
+ * You may obtain a copy of the License at
172
+ *
173
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
174
+ *
175
+ * Unless required by applicable law or agreed to in writing, software
176
+ * distributed under the License is distributed on an "AS IS" basis,
177
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
178
+ * See the License for the specific language governing permissions and
179
+ * limitations under the License.
180
+ */
181
+ var MilestoneCreateComponent = /** @class */ (function () {
182
+ function MilestoneCreateComponent(milestoneService, formBuilder, router, alertService, processService) {
183
+ this.milestoneService = milestoneService;
184
+ this.formBuilder = formBuilder;
185
+ this.router = router;
186
+ this.alertService = alertService;
187
+ this.processService = processService;
188
+ this.milestoneSets = [];
189
+ this.processDefinitions = [];
190
+ this.taskDefinitions = [];
191
+ }
192
+ Object.defineProperty(MilestoneCreateComponent.prototype, "formControls", {
193
+ get: function () {
194
+ return this.form.controls;
195
+ },
196
+ enumerable: false,
197
+ configurable: true
198
+ });
199
+ MilestoneCreateComponent.prototype.ngOnInit = function () {
200
+ this.form = this.formBuilder.group({
201
+ milestoneSet: new forms.FormControl('', forms.Validators.required),
202
+ title: new forms.FormControl('', forms.Validators.required),
203
+ processDefinitionKey: new forms.FormControl('', forms.Validators.required),
204
+ taskDefinitionKey: new forms.FormControl('', forms.Validators.required),
205
+ plannedIntervalInDays: new forms.FormControl('', [
206
+ forms.Validators.required,
207
+ forms.Validators.pattern('^[0-9]*$'),
208
+ ]),
209
+ color: new forms.FormControl('', [
210
+ forms.Validators.required,
211
+ forms.Validators.pattern('^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$'),
212
+ ]),
213
+ });
214
+ this.getMilestoneSets();
215
+ this.getMilestones();
216
+ };
217
+ MilestoneCreateComponent.prototype.reset = function () {
218
+ this.form.patchValue({
219
+ milestoneSet: '',
220
+ title: '',
221
+ processDefinitionKey: '',
222
+ taskDefinitionKey: '',
223
+ plannedIntervalInDays: '',
224
+ color: '',
225
+ });
226
+ };
227
+ MilestoneCreateComponent.prototype.getMilestoneSets = function () {
228
+ var _this = this;
229
+ this.milestoneService.getMilestoneSets().subscribe(function (milesetoneSets) {
230
+ _this.milestoneSets = milesetoneSets;
231
+ });
232
+ };
233
+ MilestoneCreateComponent.prototype.getMilestones = function () {
234
+ var _this = this;
235
+ this.processService
236
+ .getProcessDefinitions()
237
+ .subscribe(function (processDefinitions) {
238
+ _this.processDefinitions = processDefinitions;
239
+ });
240
+ };
241
+ MilestoneCreateComponent.prototype.getFlownodes = function (processDefinitionId) {
242
+ var _this = this;
243
+ if (processDefinitionId) {
244
+ this.milestoneService.getFlownodes(processDefinitionId).subscribe(function (flowNodes) {
245
+ _this.taskDefinitions = flowNodes['flowNodeMap'];
246
+ _this.form.controls.taskDefinitionKey.setValue('');
247
+ });
248
+ }
249
+ };
250
+ MilestoneCreateComponent.prototype.createMilestone = function () {
251
+ var _this = this;
252
+ var milestone = this.form.value;
253
+ milestone.processDefinitionKey = milestone.processDefinitionKey['key'];
254
+ milestone.id = null;
255
+ this.milestoneService.createMilestone(milestone).subscribe(function () {
256
+ _this.router.navigate(['/milestones']);
257
+ _this.alertService.success('New Milestone has been created');
258
+ }, function (err) {
259
+ _this.alertService.error('Error creating new milestone');
260
+ });
261
+ };
262
+ return MilestoneCreateComponent;
263
+ }());
264
+ MilestoneCreateComponent.decorators = [
265
+ { type: i0.Component, args: [{
266
+ selector: 'valtimo-milestone-create',
267
+ template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"createMilestone()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\"\n >Milestone set</label\n >\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select\n type=\"text\"\n id=\"milestoneSet\"\n formControlName=\"milestoneSet\"\n class=\"form-control\"\n [ngClass]=\"{\n 'is-valid':\n formControls.milestoneSet.touched && formControls.milestoneSet.valid,\n 'is-invalid':\n formControls.milestoneSet.touched && formControls.milestoneSet.errors\n }\"\n required\n >\n <option value=\"\" selected disabled>Choose a Milestone set</option>\n <option *ngFor=\"let milestoneSet of milestoneSets\" [value]=\"milestoneSet.id\">\n {{ milestoneSet.title }} ({{ milestoneSet.id }})\n </option>\n </select>\n <div\n *ngIf=\"formControls.milestoneSet.touched && formControls.milestoneSet.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.milestoneSet.errors.required\">\n Milestone set is required\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n type=\"text\"\n id=\"title\"\n formControlName=\"title\"\n class=\"form-control\"\n placeholder=\"Milestone title\"\n [ngClass]=\"{\n 'is-valid': formControls.title.touched && formControls.title.valid,\n 'is-invalid': formControls.title.touched && formControls.title.errors\n }\"\n required\n />\n <div\n *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\"\n >Process definition</label\n >\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select\n type=\"text\"\n id=\"process\"\n formControlName=\"processDefinitionKey\"\n class=\"form-control\"\n (ngModelChange)=\"getFlownodes($event.id)\"\n [ngClass]=\"{\n 'is-valid':\n formControls.processDefinitionKey.touched &&\n formControls.processDefinitionKey.valid,\n 'is-invalid':\n formControls.processDefinitionKey.touched &&\n formControls.processDefinitionKey.errors\n }\"\n required\n >\n <option value=\"\" selected disabled>Choose a process</option>\n <option\n *ngFor=\"let processDefinition of processDefinitions\"\n [ngValue]=\"processDefinition\"\n >\n {{ processDefinition.name }} ({{ processDefinition.key }})\n </option>\n </select>\n <div\n *ngIf=\"\n formControls.processDefinitionKey.touched &&\n formControls.processDefinitionKey.errors\n \"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.processDefinitionKey.errors.required\">\n Process is required\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\">Task</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select\n type=\"text\"\n id=\"task\"\n formControlName=\"taskDefinitionKey\"\n class=\"form-control\"\n [ngClass]=\"{\n 'is-valid':\n formControls.taskDefinitionKey.touched &&\n formControls.taskDefinitionKey.valid,\n 'is-invalid':\n formControls.taskDefinitionKey.touched &&\n formControls.taskDefinitionKey.errors\n }\"\n required\n >\n <option value=\"\" selected disabled>Choose a task</option>\n <option\n *ngFor=\"let taskDefinition of taskDefinitions | keyvalue\"\n [value]=\"taskDefinition.key\"\n >\n {{ taskDefinition.value }} ({{ taskDefinition.key }})\n </option>\n </select>\n <div\n *ngIf=\"\n formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.errors\n \"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.taskDefinitionKey.errors.required\">Task is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"interval\"\n >Interval (in days)</label\n >\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n type=\"text\"\n id=\"interval\"\n formControlName=\"plannedIntervalInDays\"\n class=\"form-control\"\n placeholder=\"Interval (in days)\"\n [ngClass]=\"{\n 'is-valid':\n formControls.plannedIntervalInDays.touched &&\n formControls.plannedIntervalInDays.valid,\n 'is-invalid':\n formControls.plannedIntervalInDays.touched &&\n formControls.plannedIntervalInDays.errors\n }\"\n required\n />\n <div\n *ngIf=\"\n formControls.plannedIntervalInDays.touched &&\n formControls.plannedIntervalInDays.errors\n \"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.required\">\n Interval is required\n </div>\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.pattern\">\n Interval is not a valid number\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"color\">Color</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n [colorPicker]=\"form.value.color\"\n (colorPickerChange)=\"form.controls.color.setValue($event)\"\n [style.background]=\"form.value.color\"\n type=\"text\"\n id=\"color\"\n formControlName=\"color\"\n class=\"form-control\"\n placeholder=\"Color\"\n [ngClass]=\"{\n 'is-valid': formControls.color.touched && formControls.color.valid,\n 'is-invalid': formControls.color.touched && formControls.color.errors\n }\"\n required\n />\n <div\n *ngIf=\"formControls.color.touched && formControls.color.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.color.errors.required\">Interval is required</div>\n <div *ngIf=\"formControls.color.errors.pattern\">Color is not a valid hex code</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">\n Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
268
+ styles: ["/*!\n * Copyright 2015-2020 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 */"]
269
+ },] }
270
+ ];
271
+ MilestoneCreateComponent.ctorParameters = function () { return [
272
+ { type: MilestoneService },
273
+ { type: forms.FormBuilder },
274
+ { type: router.Router },
275
+ { type: components.AlertService },
276
+ { type: process.ProcessService }
270
277
  ]; };
271
278
 
272
- /*
273
- * Copyright 2015-2020 Ritense BV, the Netherlands.
274
- *
275
- * Licensed under EUPL, Version 1.2 (the "License");
276
- * you may not use this file except in compliance with the License.
277
- * You may obtain a copy of the License at
278
- *
279
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
280
- *
281
- * Unless required by applicable law or agreed to in writing, software
282
- * distributed under the License is distributed on an "AS IS" basis,
283
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
284
- * See the License for the specific language governing permissions and
285
- * limitations under the License.
286
- */
287
- var MilestoneSetEditComponent = /** @class */ (function () {
288
- function MilestoneSetEditComponent(milestoneService, formBuilder, router, alertService, route) {
289
- this.milestoneService = milestoneService;
290
- this.formBuilder = formBuilder;
291
- this.router = router;
292
- this.alertService = alertService;
293
- this.route = route;
294
- }
295
- Object.defineProperty(MilestoneSetEditComponent.prototype, "formControls", {
296
- get: function () {
297
- return this.form.controls;
298
- },
299
- enumerable: false,
300
- configurable: true
301
- });
302
- MilestoneSetEditComponent.prototype.ngOnInit = function () {
303
- this.form = this.formBuilder.group({
304
- id: new forms.FormControl({ value: '', disabled: true }, forms.Validators.required),
305
- title: new forms.FormControl({}, forms.Validators.required)
306
- });
307
- this.getMilestoneSet();
308
- };
309
- MilestoneSetEditComponent.prototype.reset = function () {
310
- this.form.controls.title.setValue('');
311
- };
312
- MilestoneSetEditComponent.prototype.getMilestoneSet = function () {
313
- var _this = this;
314
- var milestoneSetId = this.route.snapshot.paramMap.get('id');
315
- this.milestoneService.getMilestoneSet(+milestoneSetId).subscribe(function (milestoneSet) {
316
- _this.form.setValue({
317
- id: milestoneSet.id,
318
- title: milestoneSet.title
319
- });
320
- });
321
- };
322
- MilestoneSetEditComponent.prototype.delete = function () {
323
- // Todo: add confirmation dialog after it's fixed
324
- this.deleteMilestoneSet();
325
- };
326
- MilestoneSetEditComponent.prototype.deleteMilestoneSet = function () {
327
- var _this = this;
328
- this.milestoneService.deleteMilestoneSet(this.form.getRawValue().id).subscribe(function () {
329
- _this.router.navigate(['/milestones']);
330
- _this.alertService.success('Milestone set has been deleted');
331
- }, function (err) {
332
- _this.router.navigate(['/milestones']);
333
- _this.alertService.error('Could not delete Milestone set. Make sure this Milestone set does not contain any milestones.');
334
- });
335
- };
336
- MilestoneSetEditComponent.prototype.updateMilestoneSet = function () {
337
- var _this = this;
338
- this.milestoneService.updateMilestoneSet(this.form.getRawValue()).subscribe(function () {
339
- _this.router.navigate(['/milestones']);
340
- _this.alertService.success('Milestone set has been updated');
341
- });
342
- };
343
- return MilestoneSetEditComponent;
344
- }());
345
- MilestoneSetEditComponent.decorators = [
346
- { type: i0.Component, args: [{
347
- selector: 'valtimo-milestone-set-edit',
348
- template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"card-body bg-light\">\n <div class=\"row py-5\">\n <div class=\"col-12\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-3 text-sm-right\"><strong>ID</strong></div>\n <div class=\"col-12 col-sm-8 col-lg-6\">{{ form.getRawValue().id }}</div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"updateMilestoneSet()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input type=\"text\" id=\"title\" formControlName=\"title\"\n class=\"form-control\" placeholder=\"Milestone set title\"\n [ngClass]=\"{'is-valid': formControls.title.touched && formControls.title.valid, 'is-invalid': formControls.title.touched && formControls.title.errors}\"\n required/>\n <div *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n <button type=\"button\" class=\"btn btn-space btn-danger\" (click)=\"delete()\">\n Delete\n </button>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
349
- styles: ["/*!\n * Copyright 2015-2020 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 */"]
350
- },] }
351
- ];
352
- MilestoneSetEditComponent.ctorParameters = function () { return [
353
- { type: MilestoneService },
354
- { type: forms.FormBuilder },
355
- { type: router.Router },
356
- { type: components.AlertService },
357
- { type: router.ActivatedRoute }
279
+ /*
280
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
281
+ *
282
+ * Licensed under EUPL, Version 1.2 (the "License");
283
+ * you may not use this file except in compliance with the License.
284
+ * You may obtain a copy of the License at
285
+ *
286
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
287
+ *
288
+ * Unless required by applicable law or agreed to in writing, software
289
+ * distributed under the License is distributed on an "AS IS" basis,
290
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
291
+ * See the License for the specific language governing permissions and
292
+ * limitations under the License.
293
+ */
294
+ var MilestoneSetEditComponent = /** @class */ (function () {
295
+ function MilestoneSetEditComponent(milestoneService, formBuilder, router, alertService, route) {
296
+ this.milestoneService = milestoneService;
297
+ this.formBuilder = formBuilder;
298
+ this.router = router;
299
+ this.alertService = alertService;
300
+ this.route = route;
301
+ }
302
+ Object.defineProperty(MilestoneSetEditComponent.prototype, "formControls", {
303
+ get: function () {
304
+ return this.form.controls;
305
+ },
306
+ enumerable: false,
307
+ configurable: true
308
+ });
309
+ MilestoneSetEditComponent.prototype.ngOnInit = function () {
310
+ this.form = this.formBuilder.group({
311
+ id: new forms.FormControl({ value: '', disabled: true }, forms.Validators.required),
312
+ title: new forms.FormControl({}, forms.Validators.required),
313
+ });
314
+ this.getMilestoneSet();
315
+ };
316
+ MilestoneSetEditComponent.prototype.reset = function () {
317
+ this.form.controls.title.setValue('');
318
+ };
319
+ MilestoneSetEditComponent.prototype.getMilestoneSet = function () {
320
+ var _this = this;
321
+ var milestoneSetId = this.route.snapshot.paramMap.get('id');
322
+ this.milestoneService
323
+ .getMilestoneSet(+milestoneSetId)
324
+ .subscribe(function (milestoneSet) {
325
+ _this.form.setValue({
326
+ id: milestoneSet.id,
327
+ title: milestoneSet.title,
328
+ });
329
+ });
330
+ };
331
+ MilestoneSetEditComponent.prototype.delete = function () {
332
+ // Todo: add confirmation dialog after it's fixed
333
+ this.deleteMilestoneSet();
334
+ };
335
+ MilestoneSetEditComponent.prototype.deleteMilestoneSet = function () {
336
+ var _this = this;
337
+ this.milestoneService.deleteMilestoneSet(this.form.getRawValue().id).subscribe(function () {
338
+ _this.router.navigate(['/milestones']);
339
+ _this.alertService.success('Milestone set has been deleted');
340
+ }, function (err) {
341
+ _this.router.navigate(['/milestones']);
342
+ _this.alertService.error('Could not delete Milestone set. Make sure this Milestone set does not contain any milestones.');
343
+ });
344
+ };
345
+ MilestoneSetEditComponent.prototype.updateMilestoneSet = function () {
346
+ var _this = this;
347
+ this.milestoneService.updateMilestoneSet(this.form.getRawValue()).subscribe(function () {
348
+ _this.router.navigate(['/milestones']);
349
+ _this.alertService.success('Milestone set has been updated');
350
+ });
351
+ };
352
+ return MilestoneSetEditComponent;
353
+ }());
354
+ MilestoneSetEditComponent.decorators = [
355
+ { type: i0.Component, args: [{
356
+ selector: 'valtimo-milestone-set-edit',
357
+ template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"card-body bg-light\">\n <div class=\"row py-5\">\n <div class=\"col-12\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-3 text-sm-right\"><strong>ID</strong></div>\n <div class=\"col-12 col-sm-8 col-lg-6\">{{ form.getRawValue().id }}</div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"updateMilestoneSet()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n type=\"text\"\n id=\"title\"\n formControlName=\"title\"\n class=\"form-control\"\n placeholder=\"Milestone set title\"\n [ngClass]=\"{\n 'is-valid': formControls.title.touched && formControls.title.valid,\n 'is-invalid': formControls.title.touched && formControls.title.errors\n }\"\n required\n />\n <div\n *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n <button type=\"button\" class=\"btn btn-space btn-danger\" (click)=\"delete()\">\n Delete\n </button>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">\n Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
358
+ styles: ["/*!\n * Copyright 2015-2020 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 */"]
359
+ },] }
360
+ ];
361
+ MilestoneSetEditComponent.ctorParameters = function () { return [
362
+ { type: MilestoneService },
363
+ { type: forms.FormBuilder },
364
+ { type: router.Router },
365
+ { type: components.AlertService },
366
+ { type: router.ActivatedRoute }
358
367
  ]; };
359
368
 
360
- /*
361
- * Copyright 2015-2020 Ritense BV, the Netherlands.
362
- *
363
- * Licensed under EUPL, Version 1.2 (the "License");
364
- * you may not use this file except in compliance with the License.
365
- * You may obtain a copy of the License at
366
- *
367
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
368
- *
369
- * Unless required by applicable law or agreed to in writing, software
370
- * distributed under the License is distributed on an "AS IS" basis,
371
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
372
- * See the License for the specific language governing permissions and
373
- * limitations under the License.
374
- */
375
- var MilestoneEditComponent = /** @class */ (function () {
376
- function MilestoneEditComponent(milestoneService, formBuilder, router, alertService, processService, route) {
377
- this.milestoneService = milestoneService;
378
- this.formBuilder = formBuilder;
379
- this.router = router;
380
- this.alertService = alertService;
381
- this.processService = processService;
382
- this.route = route;
383
- this.milestoneSets = [];
384
- this.processDefinitions = [];
385
- this.taskDefinitions = [];
386
- }
387
- Object.defineProperty(MilestoneEditComponent.prototype, "formControls", {
388
- get: function () {
389
- return this.form.controls;
390
- },
391
- enumerable: false,
392
- configurable: true
393
- });
394
- MilestoneEditComponent.prototype.ngOnInit = function () {
395
- this.form = this.formBuilder.group({
396
- id: new forms.FormControl({ value: '', disabled: true }, forms.Validators.required),
397
- milestoneSet: new forms.FormControl('', forms.Validators.required),
398
- title: new forms.FormControl('', forms.Validators.required),
399
- processDefinitionKey: new forms.FormControl('', forms.Validators.required),
400
- taskDefinitionKey: new forms.FormControl('', forms.Validators.required),
401
- plannedIntervalInDays: new forms.FormControl('', [forms.Validators.required, forms.Validators.pattern('^[0-9]*$')]),
402
- color: new forms.FormControl('', [forms.Validators.required, forms.Validators.pattern('^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$')])
403
- });
404
- this.getMilestone();
405
- this.getMilestoneSets();
406
- this.getProcessDefinitions();
407
- };
408
- MilestoneEditComponent.prototype.reset = function () {
409
- this.form.patchValue({
410
- milestoneSet: '',
411
- title: '',
412
- processDefinitionKey: '',
413
- taskDefinitionKey: '',
414
- plannedIntervalInDays: '',
415
- color: ''
416
- });
417
- };
418
- MilestoneEditComponent.prototype.getMilestone = function () {
419
- var _this = this;
420
- var milestoneId = this.route.snapshot.paramMap.get('id');
421
- this.milestoneService.getMilestone(+milestoneId)
422
- .pipe(operators.switchMap(function (milestone) {
423
- _this.form.patchValue({
424
- id: milestone.id,
425
- milestoneSet: milestone.milestoneSet.id,
426
- title: milestone.title,
427
- plannedIntervalInDays: milestone.plannedIntervalInDays,
428
- color: milestone.color,
429
- taskDefinitionKey: milestone.taskDefinitionKey,
430
- });
431
- return _this.processService.getProcessDefinition(milestone.processDefinitionKey);
432
- }))
433
- .subscribe(function (processDefinition) {
434
- _this.form.patchValue({
435
- processDefinitionKey: processDefinition
436
- });
437
- });
438
- };
439
- MilestoneEditComponent.prototype.compareProcessDefinitions = function (processDefinition1, processDefinition2) {
440
- return processDefinition1.id === processDefinition2.id;
441
- };
442
- MilestoneEditComponent.prototype.getMilestoneSets = function () {
443
- var _this = this;
444
- this.milestoneService.getMilestoneSets().subscribe(function (milesetoneSets) {
445
- _this.milestoneSets = milesetoneSets;
446
- });
447
- };
448
- MilestoneEditComponent.prototype.getProcessDefinitions = function () {
449
- var _this = this;
450
- this.processService.getProcessDefinitions().subscribe(function (processDefinitions) {
451
- _this.processDefinitions = processDefinitions;
452
- });
453
- };
454
- MilestoneEditComponent.prototype.getFlownodes = function (processDefinitionId) {
455
- var _this = this;
456
- if (processDefinitionId) {
457
- this.milestoneService.getFlownodes(processDefinitionId).subscribe(function (flowNodes) {
458
- _this.taskDefinitions = flowNodes['flowNodeMap'];
459
- });
460
- }
461
- };
462
- MilestoneEditComponent.prototype.delete = function () {
463
- // Todo: add confirmation dialog after it's fixed
464
- this.deleteMilestone();
465
- };
466
- MilestoneEditComponent.prototype.deleteMilestone = function () {
467
- var _this = this;
468
- this.milestoneService.deleteMilestone(this.form.getRawValue().id).subscribe(function () {
469
- _this.router.navigate(['/milestones']);
470
- _this.alertService.success('Milestone has been deleted');
471
- }, function (err) {
472
- _this.router.navigate(['/milestones']);
473
- _this.alertService.error('Could not delete Milestone');
474
- });
475
- };
476
- MilestoneEditComponent.prototype.updateMilestone = function () {
477
- var _this = this;
478
- var milestone = this.form.getRawValue();
479
- milestone.processDefinitionKey = milestone.processDefinitionKey['key'];
480
- this.milestoneService.updateMilestone(milestone).subscribe(function () {
481
- _this.router.navigate(['/milestones']);
482
- _this.alertService.success('Milestone has been updated');
483
- }, function (err) {
484
- _this.alertService.error('Error updating milestone');
485
- });
486
- };
487
- return MilestoneEditComponent;
488
- }());
489
- MilestoneEditComponent.decorators = [
490
- { type: i0.Component, args: [{
491
- selector: 'valtimo-milestone-edit',
492
- template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"card-body bg-light\">\n <div class=\"row py-5\">\n <div class=\"col-12\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-3 text-sm-right\"><strong>ID</strong></div>\n <div class=\"col-12 col-sm-8 col-lg-6\">{{ form.getRawValue().id }}</div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"updateMilestone()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Milestone set</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select type=\"text\" id=\"milestoneSet\" formControlName=\"milestoneSet\"\n class=\"form-control\"\n [ngClass]=\"{'is-valid': formControls.milestoneSet.touched && formControls.milestoneSet.valid, 'is-invalid': formControls.milestoneSet.touched && formControls.milestoneSet.errors}\"\n required>\n <option value=\"\" selected disabled>Choose a Milestone set</option>\n <option *ngFor=\"let milestoneSet of milestoneSets\" [value]=\"milestoneSet.id\">{{milestoneSet.title}} ({{milestoneSet.id}})</option>\n </select>\n <div *ngIf=\"formControls.milestoneSet.touched && formControls.milestoneSet.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.milestoneSet.errors.required\">Milestone set is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input type=\"text\" id=\"title\" formControlName=\"title\"\n class=\"form-control\" placeholder=\"Milestone title\"\n [ngClass]=\"{'is-valid': formControls.title.touched && formControls.title.valid, 'is-invalid': formControls.title.touched && formControls.title.errors}\"\n required/>\n <div *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\">Process definition</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select type=\"text\" id=\"process\" formControlName=\"processDefinitionKey\"\n class=\"form-control\" (ngModelChange)=\"getFlownodes($event.id)\"\n [ngClass]=\"{'is-valid': formControls.processDefinitionKey.touched && formControls.processDefinitionKey.valid, 'is-invalid': formControls.processDefinitionKey.touched && formControls.processDefinitionKey.errors}\"\n required [compareWith]=\"compareProcessDefinitions\">\n <option value=\"\" disabled>Choose a process</option>\n <option *ngFor=\"let processDefinition of processDefinitions\" [ngValue]=\"processDefinition\">{{processDefinition.name}} ({{processDefinition.key}})</option>\n </select>\n <div *ngIf=\"formControls.processDefinitionKey.touched && formControls.processDefinitionKey.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.processDefinitionKey.errors.required\">Process is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\">Task</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select type=\"text\" id=\"task\" formControlName=\"taskDefinitionKey\"\n class=\"form-control\"\n [ngClass]=\"{'is-valid': formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.valid, 'is-invalid': formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.errors}\"\n required>\n <option value=\"\" disabled>Choose a task</option>\n <option *ngFor=\"let taskDefinition of taskDefinitions |keyvalue\" [value]=\"taskDefinition.key\">{{taskDefinition.value}} ({{taskDefinition.key}})</option>\n </select>\n <div *ngIf=\"formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.taskDefinitionKey.errors.required\">Task is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"interval\">Interval (in days)</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input type=\"text\" id=\"interval\" formControlName=\"plannedIntervalInDays\"\n class=\"form-control\" placeholder=\"Interval (in days)\"\n [ngClass]=\"{'is-valid': formControls.plannedIntervalInDays.touched && formControls.plannedIntervalInDays.valid, 'is-invalid': formControls.plannedIntervalInDays.touched && formControls.plannedIntervalInDays.errors}\"\n required/>\n <div *ngIf=\"formControls.plannedIntervalInDays.touched && formControls.plannedIntervalInDays.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.required\">Interval is required</div>\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.pattern\">Interval is not a valid number</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"color\">Color</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n\n <input [colorPicker]=\"form.value.color\"\n (colorPickerChange)=\"form.controls.color.setValue($event)\"\n [style.background]=\"form.value.color\"\n type=\"text\" id=\"color\" formControlName=\"color\"\n class=\"form-control\" placeholder=\"Color\"\n [ngClass]=\"{'is-valid': formControls.color.touched && formControls.color.valid, 'is-invalid': formControls.color.touched && formControls.color.errors}\"\n required/>\n <div *ngIf=\"formControls.color.touched && formControls.color.errors\"\n class=\"invalid-feedback\">\n <div *ngIf=\"formControls.color.errors.required\">Color is required</div>\n <div *ngIf=\"formControls.color.errors.pattern\">Color is not a valid hex code</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n <button type=\"button\" class=\"btn btn-space btn-danger\" (click)=\"delete()\">\n Delete\n </button>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
493
- styles: ["/*!\n * Copyright 2015-2020 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 */"]
494
- },] }
495
- ];
496
- MilestoneEditComponent.ctorParameters = function () { return [
497
- { type: MilestoneService },
498
- { type: forms.FormBuilder },
499
- { type: router.Router },
500
- { type: components.AlertService },
501
- { type: process.ProcessService },
502
- { type: router.ActivatedRoute }
369
+ /*
370
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
371
+ *
372
+ * Licensed under EUPL, Version 1.2 (the "License");
373
+ * you may not use this file except in compliance with the License.
374
+ * You may obtain a copy of the License at
375
+ *
376
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
377
+ *
378
+ * Unless required by applicable law or agreed to in writing, software
379
+ * distributed under the License is distributed on an "AS IS" basis,
380
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
381
+ * See the License for the specific language governing permissions and
382
+ * limitations under the License.
383
+ */
384
+ var MilestoneEditComponent = /** @class */ (function () {
385
+ function MilestoneEditComponent(milestoneService, formBuilder, router, alertService, processService, route) {
386
+ this.milestoneService = milestoneService;
387
+ this.formBuilder = formBuilder;
388
+ this.router = router;
389
+ this.alertService = alertService;
390
+ this.processService = processService;
391
+ this.route = route;
392
+ this.milestoneSets = [];
393
+ this.processDefinitions = [];
394
+ this.taskDefinitions = [];
395
+ }
396
+ Object.defineProperty(MilestoneEditComponent.prototype, "formControls", {
397
+ get: function () {
398
+ return this.form.controls;
399
+ },
400
+ enumerable: false,
401
+ configurable: true
402
+ });
403
+ MilestoneEditComponent.prototype.ngOnInit = function () {
404
+ this.form = this.formBuilder.group({
405
+ id: new forms.FormControl({ value: '', disabled: true }, forms.Validators.required),
406
+ milestoneSet: new forms.FormControl('', forms.Validators.required),
407
+ title: new forms.FormControl('', forms.Validators.required),
408
+ processDefinitionKey: new forms.FormControl('', forms.Validators.required),
409
+ taskDefinitionKey: new forms.FormControl('', forms.Validators.required),
410
+ plannedIntervalInDays: new forms.FormControl('', [
411
+ forms.Validators.required,
412
+ forms.Validators.pattern('^[0-9]*$'),
413
+ ]),
414
+ color: new forms.FormControl('', [
415
+ forms.Validators.required,
416
+ forms.Validators.pattern('^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$'),
417
+ ]),
418
+ });
419
+ this.getMilestone();
420
+ this.getMilestoneSets();
421
+ this.getProcessDefinitions();
422
+ };
423
+ MilestoneEditComponent.prototype.reset = function () {
424
+ this.form.patchValue({
425
+ milestoneSet: '',
426
+ title: '',
427
+ processDefinitionKey: '',
428
+ taskDefinitionKey: '',
429
+ plannedIntervalInDays: '',
430
+ color: '',
431
+ });
432
+ };
433
+ MilestoneEditComponent.prototype.getMilestone = function () {
434
+ var _this = this;
435
+ var milestoneId = this.route.snapshot.paramMap.get('id');
436
+ this.milestoneService
437
+ .getMilestone(+milestoneId)
438
+ .pipe(operators.switchMap(function (milestone) {
439
+ _this.form.patchValue({
440
+ id: milestone.id,
441
+ milestoneSet: milestone.milestoneSet.id,
442
+ title: milestone.title,
443
+ plannedIntervalInDays: milestone.plannedIntervalInDays,
444
+ color: milestone.color,
445
+ taskDefinitionKey: milestone.taskDefinitionKey,
446
+ });
447
+ return _this.processService.getProcessDefinition(milestone.processDefinitionKey);
448
+ }))
449
+ .subscribe(function (processDefinition) {
450
+ _this.form.patchValue({
451
+ processDefinitionKey: processDefinition,
452
+ });
453
+ });
454
+ };
455
+ MilestoneEditComponent.prototype.compareProcessDefinitions = function (processDefinition1, processDefinition2) {
456
+ return processDefinition1.id === processDefinition2.id;
457
+ };
458
+ MilestoneEditComponent.prototype.getMilestoneSets = function () {
459
+ var _this = this;
460
+ this.milestoneService.getMilestoneSets().subscribe(function (milesetoneSets) {
461
+ _this.milestoneSets = milesetoneSets;
462
+ });
463
+ };
464
+ MilestoneEditComponent.prototype.getProcessDefinitions = function () {
465
+ var _this = this;
466
+ this.processService
467
+ .getProcessDefinitions()
468
+ .subscribe(function (processDefinitions) {
469
+ _this.processDefinitions = processDefinitions;
470
+ });
471
+ };
472
+ MilestoneEditComponent.prototype.getFlownodes = function (processDefinitionId) {
473
+ var _this = this;
474
+ if (processDefinitionId) {
475
+ this.milestoneService.getFlownodes(processDefinitionId).subscribe(function (flowNodes) {
476
+ _this.taskDefinitions = flowNodes['flowNodeMap'];
477
+ });
478
+ }
479
+ };
480
+ MilestoneEditComponent.prototype.delete = function () {
481
+ // Todo: add confirmation dialog after it's fixed
482
+ this.deleteMilestone();
483
+ };
484
+ MilestoneEditComponent.prototype.deleteMilestone = function () {
485
+ var _this = this;
486
+ this.milestoneService.deleteMilestone(this.form.getRawValue().id).subscribe(function () {
487
+ _this.router.navigate(['/milestones']);
488
+ _this.alertService.success('Milestone has been deleted');
489
+ }, function (err) {
490
+ _this.router.navigate(['/milestones']);
491
+ _this.alertService.error('Could not delete Milestone');
492
+ });
493
+ };
494
+ MilestoneEditComponent.prototype.updateMilestone = function () {
495
+ var _this = this;
496
+ var milestone = this.form.getRawValue();
497
+ milestone.processDefinitionKey = milestone.processDefinitionKey['key'];
498
+ this.milestoneService.updateMilestone(milestone).subscribe(function () {
499
+ _this.router.navigate(['/milestones']);
500
+ _this.alertService.success('Milestone has been updated');
501
+ }, function (err) {
502
+ _this.alertService.error('Error updating milestone');
503
+ });
504
+ };
505
+ return MilestoneEditComponent;
506
+ }());
507
+ MilestoneEditComponent.decorators = [
508
+ { type: i0.Component, args: [{
509
+ selector: 'valtimo-milestone-edit',
510
+ template: "<!--\n ~ Copyright 2015-2020 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\">\n <div class=\"container-fluid\">\n <div class=\"col-12 px-0 mb-5\">\n <valtimo-widget>\n <div class=\"card-body bg-light\">\n <div class=\"row py-5\">\n <div class=\"col-12\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-3 text-sm-right\"><strong>ID</strong></div>\n <div class=\"col-12 col-sm-8 col-lg-6\">{{ form.getRawValue().id }}</div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"bg-white p-5\">\n <form [formGroup]=\"form\" (ngSubmit)=\"updateMilestone()\">\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\"\n >Milestone set</label\n >\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select\n type=\"text\"\n id=\"milestoneSet\"\n formControlName=\"milestoneSet\"\n class=\"form-control\"\n [ngClass]=\"{\n 'is-valid':\n formControls.milestoneSet.touched && formControls.milestoneSet.valid,\n 'is-invalid':\n formControls.milestoneSet.touched && formControls.milestoneSet.errors\n }\"\n required\n >\n <option value=\"\" selected disabled>Choose a Milestone set</option>\n <option *ngFor=\"let milestoneSet of milestoneSets\" [value]=\"milestoneSet.id\">\n {{ milestoneSet.title }} ({{ milestoneSet.id }})\n </option>\n </select>\n <div\n *ngIf=\"formControls.milestoneSet.touched && formControls.milestoneSet.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.milestoneSet.errors.required\">\n Milestone set is required\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"title\">Title</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n type=\"text\"\n id=\"title\"\n formControlName=\"title\"\n class=\"form-control\"\n placeholder=\"Milestone title\"\n [ngClass]=\"{\n 'is-valid': formControls.title.touched && formControls.title.valid,\n 'is-invalid': formControls.title.touched && formControls.title.errors\n }\"\n required\n />\n <div\n *ngIf=\"formControls.title.touched && formControls.title.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.title.errors.required\">Title is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\"\n >Process definition</label\n >\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select\n type=\"text\"\n id=\"process\"\n formControlName=\"processDefinitionKey\"\n class=\"form-control\"\n (ngModelChange)=\"getFlownodes($event.id)\"\n [ngClass]=\"{\n 'is-valid':\n formControls.processDefinitionKey.touched &&\n formControls.processDefinitionKey.valid,\n 'is-invalid':\n formControls.processDefinitionKey.touched &&\n formControls.processDefinitionKey.errors\n }\"\n required\n [compareWith]=\"compareProcessDefinitions\"\n >\n <option value=\"\" disabled>Choose a process</option>\n <option\n *ngFor=\"let processDefinition of processDefinitions\"\n [ngValue]=\"processDefinition\"\n >\n {{ processDefinition.name }} ({{ processDefinition.key }})\n </option>\n </select>\n <div\n *ngIf=\"\n formControls.processDefinitionKey.touched &&\n formControls.processDefinitionKey.errors\n \"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.processDefinitionKey.errors.required\">\n Process is required\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"process\">Task</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <select\n type=\"text\"\n id=\"task\"\n formControlName=\"taskDefinitionKey\"\n class=\"form-control\"\n [ngClass]=\"{\n 'is-valid':\n formControls.taskDefinitionKey.touched &&\n formControls.taskDefinitionKey.valid,\n 'is-invalid':\n formControls.taskDefinitionKey.touched &&\n formControls.taskDefinitionKey.errors\n }\"\n required\n >\n <option value=\"\" disabled>Choose a task</option>\n <option\n *ngFor=\"let taskDefinition of taskDefinitions | keyvalue\"\n [value]=\"taskDefinition.key\"\n >\n {{ taskDefinition.value }} ({{ taskDefinition.key }})\n </option>\n </select>\n <div\n *ngIf=\"\n formControls.taskDefinitionKey.touched && formControls.taskDefinitionKey.errors\n \"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.taskDefinitionKey.errors.required\">Task is required</div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"interval\"\n >Interval (in days)</label\n >\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n type=\"text\"\n id=\"interval\"\n formControlName=\"plannedIntervalInDays\"\n class=\"form-control\"\n placeholder=\"Interval (in days)\"\n [ngClass]=\"{\n 'is-valid':\n formControls.plannedIntervalInDays.touched &&\n formControls.plannedIntervalInDays.valid,\n 'is-invalid':\n formControls.plannedIntervalInDays.touched &&\n formControls.plannedIntervalInDays.errors\n }\"\n required\n />\n <div\n *ngIf=\"\n formControls.plannedIntervalInDays.touched &&\n formControls.plannedIntervalInDays.errors\n \"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.required\">\n Interval is required\n </div>\n <div *ngIf=\"formControls.plannedIntervalInDays.errors.pattern\">\n Interval is not a valid number\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"form-group row\">\n <label class=\"col-12 col-sm-3 col-form-label text-sm-right\" for=\"color\">Color</label>\n <div class=\"col-12 col-sm-8 col-lg-6\">\n <input\n [colorPicker]=\"form.value.color\"\n (colorPickerChange)=\"form.controls.color.setValue($event)\"\n [style.background]=\"form.value.color\"\n type=\"text\"\n id=\"color\"\n formControlName=\"color\"\n class=\"form-control\"\n placeholder=\"Color\"\n [ngClass]=\"{\n 'is-valid': formControls.color.touched && formControls.color.valid,\n 'is-invalid': formControls.color.touched && formControls.color.errors\n }\"\n required\n />\n <div\n *ngIf=\"formControls.color.touched && formControls.color.errors\"\n class=\"invalid-feedback\"\n >\n <div *ngIf=\"formControls.color.errors.required\">Color is required</div>\n <div *ngIf=\"formControls.color.errors.pattern\">Color is not a valid hex code</div>\n </div>\n </div>\n </div>\n\n <div class=\"row pt-3 mt-1\">\n <div class=\"col-12 col-sm-6 text-left\">\n <a [routerLink]=\"'/milestones'\" class=\"btn btn-space btn-default\">Back</a>\n <button type=\"button\" class=\"btn btn-space btn-danger\" (click)=\"delete()\">\n Delete\n </button>\n </div>\n <div class=\"col-12 col-sm-6 text-right\">\n <button class=\"btn btn-space btn-secondary\" type=\"button\" (click)=\"reset()\">\n Reset\n </button>\n <button class=\"btn btn-space btn-primary\" type=\"submit\" [disabled]=\"form.invalid\">\n Submit\n </button>\n </div>\n </div>\n </form>\n </div>\n </valtimo-widget>\n </div>\n </div>\n</div>\n",
511
+ styles: ["/*!\n * Copyright 2015-2020 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 */"]
512
+ },] }
513
+ ];
514
+ MilestoneEditComponent.ctorParameters = function () { return [
515
+ { type: MilestoneService },
516
+ { type: forms.FormBuilder },
517
+ { type: router.Router },
518
+ { type: components.AlertService },
519
+ { type: process.ProcessService },
520
+ { type: router.ActivatedRoute }
503
521
  ]; };
504
522
 
505
- /*
506
- * Copyright 2015-2020 Ritense BV, the Netherlands.
507
- *
508
- * Licensed under EUPL, Version 1.2 (the "License");
509
- * you may not use this file except in compliance with the License.
510
- * You may obtain a copy of the License at
511
- *
512
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
513
- *
514
- * Unless required by applicable law or agreed to in writing, software
515
- * distributed under the License is distributed on an "AS IS" basis,
516
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
517
- * See the License for the specific language governing permissions and
518
- * limitations under the License.
519
- */
520
- var ɵ0 = { title: 'Milestones', roles: [contract.ROLE_ADMIN] }, ɵ1 = { title: 'Create new Milestone Set', roles: [contract.ROLE_ADMIN] }, ɵ2 = { title: 'Create new Milestone', roles: [contract.ROLE_ADMIN] }, ɵ3 = { title: 'Milestone Set details', roles: [contract.ROLE_ADMIN] }, ɵ4 = { title: 'Milestone details', roles: [contract.ROLE_ADMIN] };
521
- var routes = [
522
- {
523
- path: 'milestones',
524
- component: MilestoneComponent,
525
- canActivate: [security.AuthGuardService],
526
- data: ɵ0
527
- },
528
- {
529
- path: 'milestones/sets/create',
530
- component: MilestoneSetCreateComponent,
531
- canActivate: [security.AuthGuardService],
532
- data: ɵ1
533
- },
534
- {
535
- path: 'milestones/create',
536
- component: MilestoneCreateComponent,
537
- canActivate: [security.AuthGuardService],
538
- data: ɵ2
539
- },
540
- {
541
- path: 'milestones/sets/set/:id',
542
- component: MilestoneSetEditComponent,
543
- canActivate: [security.AuthGuardService],
544
- data: ɵ3
545
- },
546
- {
547
- path: 'milestones/milestone/:id',
548
- component: MilestoneEditComponent,
549
- canActivate: [security.AuthGuardService],
550
- data: ɵ4
551
- },
523
+ /*
524
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
525
+ *
526
+ * Licensed under EUPL, Version 1.2 (the "License");
527
+ * you may not use this file except in compliance with the License.
528
+ * You may obtain a copy of the License at
529
+ *
530
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
531
+ *
532
+ * Unless required by applicable law or agreed to in writing, software
533
+ * distributed under the License is distributed on an "AS IS" basis,
534
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
535
+ * See the License for the specific language governing permissions and
536
+ * limitations under the License.
537
+ */
538
+ var ɵ0 = { title: 'Milestones', roles: [contract.ROLE_ADMIN] }, ɵ1 = { title: 'Create new Milestone Set', roles: [contract.ROLE_ADMIN] }, ɵ2 = { title: 'Create new Milestone', roles: [contract.ROLE_ADMIN] }, ɵ3 = { title: 'Milestone Set details', roles: [contract.ROLE_ADMIN] }, ɵ4 = { title: 'Milestone details', roles: [contract.ROLE_ADMIN] };
539
+ var routes = [
540
+ {
541
+ path: 'milestones',
542
+ component: MilestoneComponent,
543
+ canActivate: [security.AuthGuardService],
544
+ data: ɵ0,
545
+ },
546
+ {
547
+ path: 'milestones/sets/create',
548
+ component: MilestoneSetCreateComponent,
549
+ canActivate: [security.AuthGuardService],
550
+ data: ɵ1,
551
+ },
552
+ {
553
+ path: 'milestones/create',
554
+ component: MilestoneCreateComponent,
555
+ canActivate: [security.AuthGuardService],
556
+ data: ɵ2,
557
+ },
558
+ {
559
+ path: 'milestones/sets/set/:id',
560
+ component: MilestoneSetEditComponent,
561
+ canActivate: [security.AuthGuardService],
562
+ data: ɵ3,
563
+ },
564
+ {
565
+ path: 'milestones/milestone/:id',
566
+ component: MilestoneEditComponent,
567
+ canActivate: [security.AuthGuardService],
568
+ data: ɵ4,
569
+ },
570
+ ];
571
+ var MilestoneRoutingModule = /** @class */ (function () {
572
+ function MilestoneRoutingModule() {
573
+ }
574
+ return MilestoneRoutingModule;
575
+ }());
576
+ MilestoneRoutingModule.decorators = [
577
+ { type: i0.NgModule, args: [{
578
+ declarations: [],
579
+ imports: [common.CommonModule, router.RouterModule.forChild(routes)],
580
+ exports: [router.RouterModule],
581
+ },] }
552
582
  ];
553
- var MilestoneRoutingModule = /** @class */ (function () {
554
- function MilestoneRoutingModule() {
555
- }
556
- return MilestoneRoutingModule;
557
- }());
558
- MilestoneRoutingModule.decorators = [
559
- { type: i0.NgModule, args: [{
560
- declarations: [],
561
- imports: [
562
- common.CommonModule,
563
- router.RouterModule.forChild(routes),
564
- ],
565
- exports: [router.RouterModule]
566
- },] }
567
- ];
568
-
569
- /*! *****************************************************************************
570
- Copyright (c) Microsoft Corporation.
571
583
 
572
- Permission to use, copy, modify, and/or distribute this software for any
573
- purpose with or without fee is hereby granted.
574
-
575
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
576
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
577
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
578
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
579
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
580
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
581
- PERFORMANCE OF THIS SOFTWARE.
582
- ***************************************************************************** */
583
- /* global Reflect, Promise */
584
- var extendStatics = function (d, b) {
585
- extendStatics = Object.setPrototypeOf ||
586
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
587
- function (d, b) { for (var p in b)
588
- if (Object.prototype.hasOwnProperty.call(b, p))
589
- d[p] = b[p]; };
590
- return extendStatics(d, b);
591
- };
592
- function __extends(d, b) {
593
- extendStatics(d, b);
594
- function __() { this.constructor = d; }
595
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
596
- }
597
- var __assign = function () {
598
- __assign = Object.assign || function __assign(t) {
599
- for (var s, i = 1, n = arguments.length; i < n; i++) {
600
- s = arguments[i];
601
- for (var p in s)
602
- if (Object.prototype.hasOwnProperty.call(s, p))
603
- t[p] = s[p];
604
- }
605
- return t;
606
- };
607
- return __assign.apply(this, arguments);
608
- };
609
- function __rest(s, e) {
610
- var t = {};
611
- for (var p in s)
612
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
613
- t[p] = s[p];
614
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
615
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
616
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
617
- t[p[i]] = s[p[i]];
618
- }
619
- return t;
620
- }
621
- function __decorate(decorators, target, key, desc) {
622
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
623
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
624
- r = Reflect.decorate(decorators, target, key, desc);
625
- else
626
- for (var i = decorators.length - 1; i >= 0; i--)
627
- if (d = decorators[i])
628
- r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
629
- return c > 3 && r && Object.defineProperty(target, key, r), r;
630
- }
631
- function __param(paramIndex, decorator) {
632
- return function (target, key) { decorator(target, key, paramIndex); };
633
- }
634
- function __metadata(metadataKey, metadataValue) {
635
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
636
- return Reflect.metadata(metadataKey, metadataValue);
637
- }
638
- function __awaiter(thisArg, _arguments, P, generator) {
639
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
640
- return new (P || (P = Promise))(function (resolve, reject) {
641
- function fulfilled(value) { try {
642
- step(generator.next(value));
643
- }
644
- catch (e) {
645
- reject(e);
646
- } }
647
- function rejected(value) { try {
648
- step(generator["throw"](value));
649
- }
650
- catch (e) {
651
- reject(e);
652
- } }
653
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
654
- step((generator = generator.apply(thisArg, _arguments || [])).next());
655
- });
656
- }
657
- function __generator(thisArg, body) {
658
- var _ = { label: 0, sent: function () { if (t[0] & 1)
659
- throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
660
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g;
661
- function verb(n) { return function (v) { return step([n, v]); }; }
662
- function step(op) {
663
- if (f)
664
- throw new TypeError("Generator is already executing.");
665
- while (_)
666
- try {
667
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
668
- return t;
669
- if (y = 0, t)
670
- op = [op[0] & 2, t.value];
671
- switch (op[0]) {
672
- case 0:
673
- case 1:
674
- t = op;
675
- break;
676
- case 4:
677
- _.label++;
678
- return { value: op[1], done: false };
679
- case 5:
680
- _.label++;
681
- y = op[1];
682
- op = [0];
683
- continue;
684
- case 7:
685
- op = _.ops.pop();
686
- _.trys.pop();
687
- continue;
688
- default:
689
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
690
- _ = 0;
691
- continue;
692
- }
693
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {
694
- _.label = op[1];
695
- break;
696
- }
697
- if (op[0] === 6 && _.label < t[1]) {
698
- _.label = t[1];
699
- t = op;
700
- break;
701
- }
702
- if (t && _.label < t[2]) {
703
- _.label = t[2];
704
- _.ops.push(op);
705
- break;
706
- }
707
- if (t[2])
708
- _.ops.pop();
709
- _.trys.pop();
710
- continue;
711
- }
712
- op = body.call(thisArg, _);
713
- }
714
- catch (e) {
715
- op = [6, e];
716
- y = 0;
717
- }
718
- finally {
719
- f = t = 0;
720
- }
721
- if (op[0] & 5)
722
- throw op[1];
723
- return { value: op[0] ? op[1] : void 0, done: true };
724
- }
725
- }
726
- var __createBinding = Object.create ? (function (o, m, k, k2) {
727
- if (k2 === undefined)
728
- k2 = k;
729
- Object.defineProperty(o, k2, { enumerable: true, get: function () { return m[k]; } });
730
- }) : (function (o, m, k, k2) {
731
- if (k2 === undefined)
732
- k2 = k;
733
- o[k2] = m[k];
734
- });
735
- function __exportStar(m, o) {
736
- for (var p in m)
737
- if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
738
- __createBinding(o, m, p);
739
- }
740
- function __values(o) {
741
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
742
- if (m)
743
- return m.call(o);
744
- if (o && typeof o.length === "number")
745
- return {
746
- next: function () {
747
- if (o && i >= o.length)
748
- o = void 0;
749
- return { value: o && o[i++], done: !o };
750
- }
751
- };
752
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
753
- }
754
- function __read(o, n) {
755
- var m = typeof Symbol === "function" && o[Symbol.iterator];
756
- if (!m)
757
- return o;
758
- var i = m.call(o), r, ar = [], e;
759
- try {
760
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
761
- ar.push(r.value);
762
- }
763
- catch (error) {
764
- e = { error: error };
765
- }
766
- finally {
767
- try {
768
- if (r && !r.done && (m = i["return"]))
769
- m.call(i);
770
- }
771
- finally {
772
- if (e)
773
- throw e.error;
774
- }
775
- }
776
- return ar;
777
- }
778
- function __spread() {
779
- for (var ar = [], i = 0; i < arguments.length; i++)
780
- ar = ar.concat(__read(arguments[i]));
781
- return ar;
782
- }
783
- function __spreadArrays() {
784
- for (var s = 0, i = 0, il = arguments.length; i < il; i++)
785
- s += arguments[i].length;
786
- for (var r = Array(s), k = 0, i = 0; i < il; i++)
787
- for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
788
- r[k] = a[j];
789
- return r;
790
- }
791
- ;
792
- function __await(v) {
793
- return this instanceof __await ? (this.v = v, this) : new __await(v);
794
- }
795
- function __asyncGenerator(thisArg, _arguments, generator) {
796
- if (!Symbol.asyncIterator)
797
- throw new TypeError("Symbol.asyncIterator is not defined.");
798
- var g = generator.apply(thisArg, _arguments || []), i, q = [];
799
- return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
800
- function verb(n) { if (g[n])
801
- i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
802
- function resume(n, v) { try {
803
- step(g[n](v));
804
- }
805
- catch (e) {
806
- settle(q[0][3], e);
807
- } }
808
- function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
809
- function fulfill(value) { resume("next", value); }
810
- function reject(value) { resume("throw", value); }
811
- function settle(f, v) { if (f(v), q.shift(), q.length)
812
- resume(q[0][0], q[0][1]); }
813
- }
814
- function __asyncDelegator(o) {
815
- var i, p;
816
- return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
817
- function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
818
- }
819
- function __asyncValues(o) {
820
- if (!Symbol.asyncIterator)
821
- throw new TypeError("Symbol.asyncIterator is not defined.");
822
- var m = o[Symbol.asyncIterator], i;
823
- return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
824
- function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
825
- function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }
826
- }
827
- function __makeTemplateObject(cooked, raw) {
828
- if (Object.defineProperty) {
829
- Object.defineProperty(cooked, "raw", { value: raw });
830
- }
831
- else {
832
- cooked.raw = raw;
833
- }
834
- return cooked;
835
- }
836
- ;
837
- var __setModuleDefault = Object.create ? (function (o, v) {
838
- Object.defineProperty(o, "default", { enumerable: true, value: v });
839
- }) : function (o, v) {
840
- o["default"] = v;
841
- };
842
- function __importStar(mod) {
843
- if (mod && mod.__esModule)
844
- return mod;
845
- var result = {};
846
- if (mod != null)
847
- for (var k in mod)
848
- if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
849
- __createBinding(result, mod, k);
850
- __setModuleDefault(result, mod);
851
- return result;
852
- }
853
- function __importDefault(mod) {
854
- return (mod && mod.__esModule) ? mod : { default: mod };
855
- }
856
- function __classPrivateFieldGet(receiver, privateMap) {
857
- if (!privateMap.has(receiver)) {
858
- throw new TypeError("attempted to get private field on non-instance");
859
- }
860
- return privateMap.get(receiver);
861
- }
862
- function __classPrivateFieldSet(receiver, privateMap, value) {
863
- if (!privateMap.has(receiver)) {
864
- throw new TypeError("attempted to set private field on non-instance");
865
- }
866
- privateMap.set(receiver, value);
867
- return value;
584
+ /*! *****************************************************************************
585
+ Copyright (c) Microsoft Corporation.
586
+
587
+ Permission to use, copy, modify, and/or distribute this software for any
588
+ purpose with or without fee is hereby granted.
589
+
590
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
591
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
592
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
593
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
594
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
595
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
596
+ PERFORMANCE OF THIS SOFTWARE.
597
+ ***************************************************************************** */
598
+ /* global Reflect, Promise */
599
+ var extendStatics = function (d, b) {
600
+ extendStatics = Object.setPrototypeOf ||
601
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
602
+ function (d, b) { for (var p in b)
603
+ if (Object.prototype.hasOwnProperty.call(b, p))
604
+ d[p] = b[p]; };
605
+ return extendStatics(d, b);
606
+ };
607
+ function __extends(d, b) {
608
+ if (typeof b !== "function" && b !== null)
609
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
610
+ extendStatics(d, b);
611
+ function __() { this.constructor = d; }
612
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
613
+ }
614
+ var __assign = function () {
615
+ __assign = Object.assign || function __assign(t) {
616
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
617
+ s = arguments[i];
618
+ for (var p in s)
619
+ if (Object.prototype.hasOwnProperty.call(s, p))
620
+ t[p] = s[p];
621
+ }
622
+ return t;
623
+ };
624
+ return __assign.apply(this, arguments);
625
+ };
626
+ function __rest(s, e) {
627
+ var t = {};
628
+ for (var p in s)
629
+ if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
630
+ t[p] = s[p];
631
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
632
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
633
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
634
+ t[p[i]] = s[p[i]];
635
+ }
636
+ return t;
637
+ }
638
+ function __decorate(decorators, target, key, desc) {
639
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
640
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
641
+ r = Reflect.decorate(decorators, target, key, desc);
642
+ else
643
+ for (var i = decorators.length - 1; i >= 0; i--)
644
+ if (d = decorators[i])
645
+ r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
646
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
647
+ }
648
+ function __param(paramIndex, decorator) {
649
+ return function (target, key) { decorator(target, key, paramIndex); };
650
+ }
651
+ function __metadata(metadataKey, metadataValue) {
652
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
653
+ return Reflect.metadata(metadataKey, metadataValue);
654
+ }
655
+ function __awaiter(thisArg, _arguments, P, generator) {
656
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
657
+ return new (P || (P = Promise))(function (resolve, reject) {
658
+ function fulfilled(value) { try {
659
+ step(generator.next(value));
660
+ }
661
+ catch (e) {
662
+ reject(e);
663
+ } }
664
+ function rejected(value) { try {
665
+ step(generator["throw"](value));
666
+ }
667
+ catch (e) {
668
+ reject(e);
669
+ } }
670
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
671
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
672
+ });
673
+ }
674
+ function __generator(thisArg, body) {
675
+ var _ = { label: 0, sent: function () { if (t[0] & 1)
676
+ throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
677
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g;
678
+ function verb(n) { return function (v) { return step([n, v]); }; }
679
+ function step(op) {
680
+ if (f)
681
+ throw new TypeError("Generator is already executing.");
682
+ while (_)
683
+ try {
684
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
685
+ return t;
686
+ if (y = 0, t)
687
+ op = [op[0] & 2, t.value];
688
+ switch (op[0]) {
689
+ case 0:
690
+ case 1:
691
+ t = op;
692
+ break;
693
+ case 4:
694
+ _.label++;
695
+ return { value: op[1], done: false };
696
+ case 5:
697
+ _.label++;
698
+ y = op[1];
699
+ op = [0];
700
+ continue;
701
+ case 7:
702
+ op = _.ops.pop();
703
+ _.trys.pop();
704
+ continue;
705
+ default:
706
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
707
+ _ = 0;
708
+ continue;
709
+ }
710
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {
711
+ _.label = op[1];
712
+ break;
713
+ }
714
+ if (op[0] === 6 && _.label < t[1]) {
715
+ _.label = t[1];
716
+ t = op;
717
+ break;
718
+ }
719
+ if (t && _.label < t[2]) {
720
+ _.label = t[2];
721
+ _.ops.push(op);
722
+ break;
723
+ }
724
+ if (t[2])
725
+ _.ops.pop();
726
+ _.trys.pop();
727
+ continue;
728
+ }
729
+ op = body.call(thisArg, _);
730
+ }
731
+ catch (e) {
732
+ op = [6, e];
733
+ y = 0;
734
+ }
735
+ finally {
736
+ f = t = 0;
737
+ }
738
+ if (op[0] & 5)
739
+ throw op[1];
740
+ return { value: op[0] ? op[1] : void 0, done: true };
741
+ }
742
+ }
743
+ var __createBinding = Object.create ? (function (o, m, k, k2) {
744
+ if (k2 === undefined)
745
+ k2 = k;
746
+ Object.defineProperty(o, k2, { enumerable: true, get: function () { return m[k]; } });
747
+ }) : (function (o, m, k, k2) {
748
+ if (k2 === undefined)
749
+ k2 = k;
750
+ o[k2] = m[k];
751
+ });
752
+ function __exportStar(m, o) {
753
+ for (var p in m)
754
+ if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
755
+ __createBinding(o, m, p);
756
+ }
757
+ function __values(o) {
758
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
759
+ if (m)
760
+ return m.call(o);
761
+ if (o && typeof o.length === "number")
762
+ return {
763
+ next: function () {
764
+ if (o && i >= o.length)
765
+ o = void 0;
766
+ return { value: o && o[i++], done: !o };
767
+ }
768
+ };
769
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
770
+ }
771
+ function __read(o, n) {
772
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
773
+ if (!m)
774
+ return o;
775
+ var i = m.call(o), r, ar = [], e;
776
+ try {
777
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
778
+ ar.push(r.value);
779
+ }
780
+ catch (error) {
781
+ e = { error: error };
782
+ }
783
+ finally {
784
+ try {
785
+ if (r && !r.done && (m = i["return"]))
786
+ m.call(i);
787
+ }
788
+ finally {
789
+ if (e)
790
+ throw e.error;
791
+ }
792
+ }
793
+ return ar;
794
+ }
795
+ /** @deprecated */
796
+ function __spread() {
797
+ for (var ar = [], i = 0; i < arguments.length; i++)
798
+ ar = ar.concat(__read(arguments[i]));
799
+ return ar;
800
+ }
801
+ /** @deprecated */
802
+ function __spreadArrays() {
803
+ for (var s = 0, i = 0, il = arguments.length; i < il; i++)
804
+ s += arguments[i].length;
805
+ for (var r = Array(s), k = 0, i = 0; i < il; i++)
806
+ for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
807
+ r[k] = a[j];
808
+ return r;
809
+ }
810
+ function __spreadArray(to, from, pack) {
811
+ if (pack || arguments.length === 2)
812
+ for (var i = 0, l = from.length, ar; i < l; i++) {
813
+ if (ar || !(i in from)) {
814
+ if (!ar)
815
+ ar = Array.prototype.slice.call(from, 0, i);
816
+ ar[i] = from[i];
817
+ }
818
+ }
819
+ return to.concat(ar || Array.prototype.slice.call(from));
820
+ }
821
+ function __await(v) {
822
+ return this instanceof __await ? (this.v = v, this) : new __await(v);
823
+ }
824
+ function __asyncGenerator(thisArg, _arguments, generator) {
825
+ if (!Symbol.asyncIterator)
826
+ throw new TypeError("Symbol.asyncIterator is not defined.");
827
+ var g = generator.apply(thisArg, _arguments || []), i, q = [];
828
+ return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
829
+ function verb(n) { if (g[n])
830
+ i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
831
+ function resume(n, v) { try {
832
+ step(g[n](v));
833
+ }
834
+ catch (e) {
835
+ settle(q[0][3], e);
836
+ } }
837
+ function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
838
+ function fulfill(value) { resume("next", value); }
839
+ function reject(value) { resume("throw", value); }
840
+ function settle(f, v) { if (f(v), q.shift(), q.length)
841
+ resume(q[0][0], q[0][1]); }
842
+ }
843
+ function __asyncDelegator(o) {
844
+ var i, p;
845
+ return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
846
+ function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
847
+ }
848
+ function __asyncValues(o) {
849
+ if (!Symbol.asyncIterator)
850
+ throw new TypeError("Symbol.asyncIterator is not defined.");
851
+ var m = o[Symbol.asyncIterator], i;
852
+ return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
853
+ function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
854
+ function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }
855
+ }
856
+ function __makeTemplateObject(cooked, raw) {
857
+ if (Object.defineProperty) {
858
+ Object.defineProperty(cooked, "raw", { value: raw });
859
+ }
860
+ else {
861
+ cooked.raw = raw;
862
+ }
863
+ return cooked;
864
+ }
865
+ ;
866
+ var __setModuleDefault = Object.create ? (function (o, v) {
867
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
868
+ }) : function (o, v) {
869
+ o["default"] = v;
870
+ };
871
+ function __importStar(mod) {
872
+ if (mod && mod.__esModule)
873
+ return mod;
874
+ var result = {};
875
+ if (mod != null)
876
+ for (var k in mod)
877
+ if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
878
+ __createBinding(result, mod, k);
879
+ __setModuleDefault(result, mod);
880
+ return result;
881
+ }
882
+ function __importDefault(mod) {
883
+ return (mod && mod.__esModule) ? mod : { default: mod };
884
+ }
885
+ function __classPrivateFieldGet(receiver, state, kind, f) {
886
+ if (kind === "a" && !f)
887
+ throw new TypeError("Private accessor was defined without a getter");
888
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
889
+ throw new TypeError("Cannot read private member from an object whose class did not declare it");
890
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
891
+ }
892
+ function __classPrivateFieldSet(receiver, state, value, kind, f) {
893
+ if (kind === "m")
894
+ throw new TypeError("Private method is not writable");
895
+ if (kind === "a" && !f)
896
+ throw new TypeError("Private accessor was defined without a setter");
897
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
898
+ throw new TypeError("Cannot write private member to an object whose class did not declare it");
899
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
868
900
  }
869
901
 
870
- var MilestoneListComponent = /** @class */ (function () {
871
- function MilestoneListComponent(milestoneService, router) {
872
- this.milestoneService = milestoneService;
873
- this.router = router;
874
- this.milestones = [];
875
- this.milestoneFields = [
876
- { key: 'id', label: 'ID' },
877
- { key: 'title', label: 'Title' },
878
- { key: 'processDefinitionKey', label: 'Process' },
879
- { key: 'taskDefinitionKey', label: 'Task' },
880
- { key: 'plannedIntervalInDays', label: 'Interval (in days)' },
881
- { key: 'color', label: 'Color' },
882
- ];
883
- }
884
- MilestoneListComponent.prototype.editMilestoneSet = function (milestoneSetId) {
885
- this.router.navigate(['milestones/sets/set', milestoneSetId]);
886
- };
887
- MilestoneListComponent.prototype.editMilestone = function (milestone) {
888
- this.router.navigate(['milestones/milestone', milestone.id]);
889
- };
890
- MilestoneListComponent.prototype.ngOnInit = function () {
891
- var _this = this;
892
- rxjs.combineLatest([this.milestoneService.getMilestones(), this.milestoneService.getMilestoneSets()])
893
- .subscribe(function (_a) {
894
- var _b = __read(_a, 2), milestones = _b[0], milestoneSets = _b[1];
895
- return _this.handleMilestoneResult(milestones, milestoneSets);
896
- });
897
- };
898
- MilestoneListComponent.prototype.handleMilestoneResult = function (milestones, milestoneSets) {
899
- var milestoneSetsMap = this.getMilestoneSetsMap(milestones, milestoneSets);
900
- this.setMilestones(milestoneSetsMap);
901
- };
902
- MilestoneListComponent.prototype.setMilestones = function (milestoneSetsMap) {
903
- this.milestones = Array.from(milestoneSetsMap.entries()).map(function (entry) {
904
- entry[0] = JSON.parse(entry[0]);
905
- return entry;
906
- });
907
- };
908
- MilestoneListComponent.prototype.getMilestoneSetsMap = function (milestones, milestoneSets) {
909
- var mapWithSets = this.addMilestoneSetsToMap(milestoneSets, this.getEmptyMap());
910
- return this.addMilestonesToMap(milestones, mapWithSets);
911
- };
912
- MilestoneListComponent.prototype.getEmptyMap = function () {
913
- return new Map();
914
- };
915
- MilestoneListComponent.prototype.addMilestoneSetsToMap = function (milestoneSets, map) {
916
- milestoneSets.forEach(function (milestoneSet) {
917
- map.set(JSON.stringify(milestoneSet), []);
918
- });
919
- return map;
920
- };
921
- MilestoneListComponent.prototype.addMilestonesToMap = function (milestones, map) {
922
- milestones.forEach(function (milestone) {
923
- var milestoneSetString = JSON.stringify(milestone.milestoneSet);
924
- var arr = map.get(milestoneSetString);
925
- arr.push(milestone);
926
- map.set(milestoneSetString, arr);
927
- });
928
- return map;
929
- };
930
- return MilestoneListComponent;
931
- }());
932
- MilestoneListComponent.decorators = [
933
- { type: i0.Component, args: [{
934
- selector: 'valtimo-milestone-list',
935
- template: "<!--\n ~ Copyright 2015-2020 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 *ngFor=\"let milestoneGroup of milestones\" class=\"mb-4\">\n <valtimo-widget>\n <h4 (click)=\"editMilestoneSet(milestoneGroup[0].id)\" class=\"milestone-title\">{{milestoneGroup[0].title}} ({{milestoneGroup[0].id}})</h4>\n <valtimo-list [items]=\"milestoneGroup[1]\" [fields]=\"milestoneFields\" (rowClicked)=\"editMilestone($event)\">\n </valtimo-list>\n </valtimo-widget>\n</div>\n",
936
- styles: ["/*!\n * Copyright 2015-2020 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 */.milestone-title{background-color:#f8f9f9;border-bottom:1px solid #dee2e6;cursor:pointer;margin:0;padding:1em}"]
937
- },] }
938
- ];
939
- MilestoneListComponent.ctorParameters = function () { return [
940
- { type: MilestoneService },
941
- { type: router.Router }
902
+ var MilestoneListComponent = /** @class */ (function () {
903
+ function MilestoneListComponent(milestoneService, router) {
904
+ this.milestoneService = milestoneService;
905
+ this.router = router;
906
+ this.milestones = [];
907
+ this.milestoneFields = [
908
+ { key: 'id', label: 'ID' },
909
+ { key: 'title', label: 'Title' },
910
+ { key: 'processDefinitionKey', label: 'Process' },
911
+ { key: 'taskDefinitionKey', label: 'Task' },
912
+ { key: 'plannedIntervalInDays', label: 'Interval (in days)' },
913
+ { key: 'color', label: 'Color' },
914
+ ];
915
+ }
916
+ MilestoneListComponent.prototype.editMilestoneSet = function (milestoneSetId) {
917
+ this.router.navigate(['milestones/sets/set', milestoneSetId]);
918
+ };
919
+ MilestoneListComponent.prototype.editMilestone = function (milestone) {
920
+ this.router.navigate(['milestones/milestone', milestone.id]);
921
+ };
922
+ MilestoneListComponent.prototype.ngOnInit = function () {
923
+ var _this = this;
924
+ rxjs.combineLatest([
925
+ this.milestoneService.getMilestones(),
926
+ this.milestoneService.getMilestoneSets(),
927
+ ]).subscribe(function (_a) {
928
+ var _b = __read(_a, 2), milestones = _b[0], milestoneSets = _b[1];
929
+ return _this.handleMilestoneResult(milestones, milestoneSets);
930
+ });
931
+ };
932
+ MilestoneListComponent.prototype.handleMilestoneResult = function (milestones, milestoneSets) {
933
+ var milestoneSetsMap = this.getMilestoneSetsMap(milestones, milestoneSets);
934
+ this.setMilestones(milestoneSetsMap);
935
+ };
936
+ MilestoneListComponent.prototype.setMilestones = function (milestoneSetsMap) {
937
+ this.milestones = Array.from(milestoneSetsMap.entries()).map(function (entry) {
938
+ entry[0] = JSON.parse(entry[0]);
939
+ return entry;
940
+ });
941
+ };
942
+ MilestoneListComponent.prototype.getMilestoneSetsMap = function (milestones, milestoneSets) {
943
+ var mapWithSets = this.addMilestoneSetsToMap(milestoneSets, this.getEmptyMap());
944
+ return this.addMilestonesToMap(milestones, mapWithSets);
945
+ };
946
+ MilestoneListComponent.prototype.getEmptyMap = function () {
947
+ return new Map();
948
+ };
949
+ MilestoneListComponent.prototype.addMilestoneSetsToMap = function (milestoneSets, map) {
950
+ milestoneSets.forEach(function (milestoneSet) {
951
+ map.set(JSON.stringify(milestoneSet), []);
952
+ });
953
+ return map;
954
+ };
955
+ MilestoneListComponent.prototype.addMilestonesToMap = function (milestones, map) {
956
+ milestones.forEach(function (milestone) {
957
+ var milestoneSetString = JSON.stringify(milestone.milestoneSet);
958
+ var arr = map.get(milestoneSetString);
959
+ arr.push(milestone);
960
+ map.set(milestoneSetString, arr);
961
+ });
962
+ return map;
963
+ };
964
+ return MilestoneListComponent;
965
+ }());
966
+ MilestoneListComponent.decorators = [
967
+ { type: i0.Component, args: [{
968
+ selector: 'valtimo-milestone-list',
969
+ template: "<!--\n ~ Copyright 2015-2020 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 *ngFor=\"let milestoneGroup of milestones\" class=\"mb-4\">\n <valtimo-widget>\n <h4 (click)=\"editMilestoneSet(milestoneGroup[0].id)\" class=\"milestone-title\">\n {{ milestoneGroup[0].title }} ({{ milestoneGroup[0].id }})\n </h4>\n <valtimo-list\n [items]=\"milestoneGroup[1]\"\n [fields]=\"milestoneFields\"\n (rowClicked)=\"editMilestone($event)\"\n >\n </valtimo-list>\n </valtimo-widget>\n</div>\n",
970
+ styles: ["/*!\n * Copyright 2015-2020 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 */.milestone-title{background-color:#f8f9f9;border-bottom:1px solid #dee2e6;cursor:pointer;margin:0;padding:1em}"]
971
+ },] }
972
+ ];
973
+ MilestoneListComponent.ctorParameters = function () { return [
974
+ { type: MilestoneService },
975
+ { type: router.Router }
942
976
  ]; };
943
977
 
944
- /*
945
- * Copyright 2015-2020 Ritense BV, the Netherlands.
946
- *
947
- * Licensed under EUPL, Version 1.2 (the "License");
948
- * you may not use this file except in compliance with the License.
949
- * You may obtain a copy of the License at
950
- *
951
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
952
- *
953
- * Unless required by applicable law or agreed to in writing, software
954
- * distributed under the License is distributed on an "AS IS" basis,
955
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
956
- * See the License for the specific language governing permissions and
957
- * limitations under the License.
958
- */
959
- var MilestoneModule = /** @class */ (function () {
960
- function MilestoneModule() {
961
- }
962
- return MilestoneModule;
963
- }());
964
- MilestoneModule.decorators = [
965
- { type: i0.NgModule, args: [{
966
- declarations: [MilestoneComponent, MilestoneSetCreateComponent, MilestoneListComponent,
967
- MilestoneCreateComponent, MilestoneEditComponent, MilestoneSetEditComponent],
968
- imports: [
969
- router.RouterModule,
970
- MilestoneRoutingModule,
971
- common.CommonModule,
972
- components.ListModule,
973
- components.WidgetModule,
974
- forms.ReactiveFormsModule,
975
- ngxColorPicker.ColorPickerModule,
976
- core.TranslateModule
977
- ],
978
- exports: [MilestoneComponent]
979
- },] }
978
+ /*
979
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
980
+ *
981
+ * Licensed under EUPL, Version 1.2 (the "License");
982
+ * you may not use this file except in compliance with the License.
983
+ * You may obtain a copy of the License at
984
+ *
985
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
986
+ *
987
+ * Unless required by applicable law or agreed to in writing, software
988
+ * distributed under the License is distributed on an "AS IS" basis,
989
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
990
+ * See the License for the specific language governing permissions and
991
+ * limitations under the License.
992
+ */
993
+ var MilestoneModule = /** @class */ (function () {
994
+ function MilestoneModule() {
995
+ }
996
+ return MilestoneModule;
997
+ }());
998
+ MilestoneModule.decorators = [
999
+ { type: i0.NgModule, args: [{
1000
+ declarations: [
1001
+ MilestoneComponent,
1002
+ MilestoneSetCreateComponent,
1003
+ MilestoneListComponent,
1004
+ MilestoneCreateComponent,
1005
+ MilestoneEditComponent,
1006
+ MilestoneSetEditComponent,
1007
+ ],
1008
+ imports: [
1009
+ router.RouterModule,
1010
+ MilestoneRoutingModule,
1011
+ common.CommonModule,
1012
+ components.ListModule,
1013
+ components.WidgetModule,
1014
+ forms.ReactiveFormsModule,
1015
+ ngxColorPicker.ColorPickerModule,
1016
+ core.TranslateModule,
1017
+ ],
1018
+ exports: [MilestoneComponent],
1019
+ },] }
980
1020
  ];
981
1021
 
982
- /*
983
- * Copyright 2015-2020 Ritense BV, the Netherlands.
984
- *
985
- * Licensed under EUPL, Version 1.2 (the "License");
986
- * you may not use this file except in compliance with the License.
987
- * You may obtain a copy of the License at
988
- *
989
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
990
- *
991
- * Unless required by applicable law or agreed to in writing, software
992
- * distributed under the License is distributed on an "AS IS" basis,
993
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
994
- * See the License for the specific language governing permissions and
995
- * limitations under the License.
1022
+ /*
1023
+ * Copyright 2015-2020 Ritense BV, the Netherlands.
1024
+ *
1025
+ * Licensed under EUPL, Version 1.2 (the "License");
1026
+ * you may not use this file except in compliance with the License.
1027
+ * You may obtain a copy of the License at
1028
+ *
1029
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1030
+ *
1031
+ * Unless required by applicable law or agreed to in writing, software
1032
+ * distributed under the License is distributed on an "AS IS" basis,
1033
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1034
+ * See the License for the specific language governing permissions and
1035
+ * limitations under the License.
996
1036
  */
997
1037
 
998
- /**
999
- * Generated bundle index. Do not edit.
1038
+ /**
1039
+ * Generated bundle index. Do not edit.
1000
1040
  */
1001
1041
 
1002
1042
  exports.MilestoneComponent = MilestoneComponent;