@valtimo/task 11.3.2 → 12.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/esm2022/lib/components/assign-user-to-task/assign-user-to-task.component.mjs +122 -0
  2. package/esm2022/lib/components/task-detail-modal/task-detail-modal.component.mjs +202 -0
  3. package/esm2022/lib/components/task-list/task-list.component.mjs +287 -0
  4. package/esm2022/lib/models/index.mjs +2 -2
  5. package/esm2022/lib/models/task-definition.model.mjs +2 -2
  6. package/esm2022/lib/models/task-list.model.mjs +8 -14
  7. package/esm2022/lib/models/task.model.mjs +2 -2
  8. package/esm2022/lib/services/index.mjs +20 -0
  9. package/esm2022/lib/services/task-list-column.service.mjs +192 -0
  10. package/esm2022/lib/services/task-list-pagination.service.mjs +74 -0
  11. package/esm2022/lib/services/task-list-sort.service.mjs +90 -0
  12. package/esm2022/lib/services/task-list.service.mjs +60 -0
  13. package/esm2022/lib/services/task.service.mjs +94 -0
  14. package/esm2022/lib/task-permissions.mjs +2 -2
  15. package/esm2022/lib/task-routing.module.mjs +7 -7
  16. package/esm2022/lib/task.module.mjs +23 -17
  17. package/esm2022/public_api.mjs +6 -6
  18. package/fesm2022/valtimo-task.mjs +749 -316
  19. package/fesm2022/valtimo-task.mjs.map +1 -1
  20. package/lib/{assign-user-to-task → components/assign-user-to-task}/assign-user-to-task.component.d.ts +7 -7
  21. package/lib/components/assign-user-to-task/assign-user-to-task.component.d.ts.map +1 -0
  22. package/lib/{task-detail-modal → components/task-detail-modal}/task-detail-modal.component.d.ts +3 -4
  23. package/lib/components/task-detail-modal/task-detail-modal.component.d.ts.map +1 -0
  24. package/lib/components/task-list/task-list.component.d.ts +65 -0
  25. package/lib/components/task-list/task-list.component.d.ts.map +1 -0
  26. package/lib/models/task-list.model.d.ts +45 -8
  27. package/lib/models/task-list.model.d.ts.map +1 -1
  28. package/lib/models/task.model.d.ts +22 -1
  29. package/lib/models/task.model.d.ts.map +1 -1
  30. package/lib/services/index.d.ts +5 -0
  31. package/lib/services/index.d.ts.map +1 -0
  32. package/lib/services/task-list-column.service.d.ts +27 -0
  33. package/lib/services/task-list-column.service.d.ts.map +1 -0
  34. package/lib/services/task-list-pagination.service.d.ts +20 -0
  35. package/lib/services/task-list-pagination.service.d.ts.map +1 -0
  36. package/lib/services/task-list-sort.service.d.ts +23 -0
  37. package/lib/services/task-list-sort.service.d.ts.map +1 -0
  38. package/lib/services/task-list.service.d.ts +23 -0
  39. package/lib/services/task-list.service.d.ts.map +1 -0
  40. package/lib/{task.service.d.ts → services/task.service.d.ts} +9 -8
  41. package/lib/services/task.service.d.ts.map +1 -0
  42. package/lib/task.module.d.ts +5 -5
  43. package/lib/task.module.d.ts.map +1 -1
  44. package/package.json +7 -6
  45. package/public_api.d.ts +4 -4
  46. package/public_api.d.ts.map +1 -1
  47. package/esm2022/lib/assign-user-to-task/assign-user-to-task.component.mjs +0 -122
  48. package/esm2022/lib/task-detail-modal/task-detail-modal.component.mjs +0 -219
  49. package/esm2022/lib/task-list/task-list.component.mjs +0 -259
  50. package/esm2022/lib/task.service.mjs +0 -72
  51. package/lib/assign-user-to-task/assign-user-to-task.component.d.ts.map +0 -1
  52. package/lib/task-detail-modal/task-detail-modal.component.d.ts.map +0 -1
  53. package/lib/task-list/task-list.component.d.ts +0 -54
  54. package/lib/task-list/task-list.component.d.ts.map +0 -1
  55. package/lib/task.service.d.ts.map +0 -1
@@ -1,38 +1,38 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Injectable, EventEmitter, Component, Input, Output, ViewEncapsulation, ViewChild, NgModule } from '@angular/core';
3
- import * as i5 from '@valtimo/security';
4
- import { InterceptorSkip, AuthGuardService } from '@valtimo/security';
2
+ import { Injectable, EventEmitter, Component, Input, Output, ViewEncapsulation, ViewChild, ChangeDetectionStrategy, NgModule } from '@angular/core';
5
3
  import * as i1 from '@angular/common/http';
6
- import { HttpClient } from '@angular/common/http';
4
+ import { HttpParams, HttpClient } from '@angular/common/http';
7
5
  import * as i2 from '@valtimo/config';
8
- import { ROLE_USER, HttpLoaderFactory } from '@valtimo/config';
9
- import * as i8 from '@angular/common';
6
+ import { BaseApiService, TaskListTab, ROLE_USER, HttpLoaderFactory } from '@valtimo/config';
7
+ import * as i5 from '@valtimo/security';
8
+ import { InterceptorSkip, AuthGuardService } from '@valtimo/security';
9
+ import * as i9 from '@angular/common';
10
10
  import { CommonModule } from '@angular/common';
11
11
  import { FormsModule } from '@angular/forms';
12
12
  import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
13
- import * as i10 from '@ng-bootstrap/ng-bootstrap';
13
+ import * as i11 from '@ng-bootstrap/ng-bootstrap';
14
14
  import { NgbModule } from '@ng-bootstrap/ng-bootstrap';
15
- import * as i8$1 from '@ngx-translate/core';
15
+ import * as i8 from '@ngx-translate/core';
16
16
  import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
17
17
  import * as i6 from '@valtimo/components';
18
- import { FormioOptionsImpl, CarbonListModule, PageHeaderModule, WidgetModule, SpinnerModule, SearchableDropdownSelectModule, CamundaFormModule, FormIoModule, ModalModule } from '@valtimo/components';
19
- import * as i2$1 from '@valtimo/form-link';
20
- import { FormLinkModule } from '@valtimo/form-link';
21
- import * as i11 from 'carbon-components-angular';
22
- import { LinkModule, TabsModule, ContentSwitcherModule } from 'carbon-components-angular';
18
+ import { ViewType, FormioOptionsImpl, CarbonListModule, PageHeaderModule, WidgetModule, SpinnerModule, SearchableDropdownSelectModule, CamundaFormModule, FormIoModule, ModalModule, RenderInPageHeaderDirectiveModule } from '@valtimo/components';
19
+ import * as i2$1 from '@valtimo/process-link';
20
+ import { ProcessLinkModule } from '@valtimo/process-link';
21
+ import * as i12 from 'carbon-components-angular';
22
+ import { LinkModule, TabsModule, ContentSwitcherModule, DropdownModule } from 'carbon-components-angular';
23
23
  import * as i1$1 from 'ngx-toastr';
24
24
  import { ToastrModule } from 'ngx-toastr';
25
- import { BehaviorSubject, Subscription, take, combineLatest, tap, distinctUntilChanged, switchMap, of, forkJoin, defaultIfEmpty } from 'rxjs';
25
+ import { BehaviorSubject, combineLatest, tap, filter, switchMap, Subscription, take as take$1, distinctUntilChanged, of } from 'rxjs';
26
+ import { map, take, filter as filter$1, distinctUntilChanged as distinctUntilChanged$1 } from 'rxjs/operators';
26
27
  import moment from 'moment';
27
- import { map, take as take$1 } from 'rxjs/operators';
28
28
  import * as i3 from '@angular/router';
29
29
  import { RouterModule } from '@angular/router';
30
30
  import * as i7 from '@valtimo/document';
31
- import * as i3$1 from 'ngx-logger';
32
- import * as i4 from '@valtimo/access-control';
31
+ import { isEqual } from 'lodash';
32
+ import * as i3$1 from '@valtimo/access-control';
33
33
 
34
34
  /*
35
- * Copyright 2015-2023 Ritense BV, the Netherlands.
35
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
36
36
  *
37
37
  * Licensed under EUPL, Version 1.2 (the "License");
38
38
  * you may not use this file except in compliance with the License.
@@ -48,7 +48,7 @@ import * as i4 from '@valtimo/access-control';
48
48
  */
49
49
 
50
50
  /*
51
- * Copyright 2015-2023 Ritense BV, the Netherlands.
51
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
52
52
  *
53
53
  * Licensed under EUPL, Version 1.2 (the "License");
54
54
  * you may not use this file except in compliance with the License.
@@ -64,7 +64,7 @@ import * as i4 from '@valtimo/access-control';
64
64
  */
65
65
 
66
66
  /*
67
- * Copyright 2015-2023 Ritense BV, the Netherlands.
67
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
68
68
  *
69
69
  * Licensed under EUPL, Version 1.2 (the "License");
70
70
  * you may not use this file except in compliance with the License.
@@ -78,21 +78,14 @@ import * as i4 from '@valtimo/access-control';
78
78
  * See the License for the specific language governing permissions and
79
79
  * limitations under the License.
80
80
  */
81
- class TaskList {
82
- constructor() {
83
- this.tasks = [];
84
- this.fields = [];
85
- this.pagination = {
86
- collectionSize: 0,
87
- page: 1,
88
- size: 10,
89
- };
90
- this.page = 0;
91
- }
92
- }
81
+ var TaskListColumnDefaultSort;
82
+ (function (TaskListColumnDefaultSort) {
83
+ TaskListColumnDefaultSort["ASC"] = "ASC";
84
+ TaskListColumnDefaultSort["DESC"] = "DESC";
85
+ })(TaskListColumnDefaultSort || (TaskListColumnDefaultSort = {}));
93
86
 
94
87
  /*
95
- * Copyright 2015-2023 Ritense BV, the Netherlands.
88
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
96
89
  *
97
90
  * Licensed under EUPL, Version 1.2 (the "License");
98
91
  * you may not use this file except in compliance with the License.
@@ -108,7 +101,7 @@ class TaskList {
108
101
  */
109
102
 
110
103
  /*
111
- * Copyright 2015-2023 Ritense BV, the Netherlands.
104
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
112
105
  *
113
106
  * Licensed under EUPL, Version 1.2 (the "License");
114
107
  * you may not use this file except in compliance with the License.
@@ -122,60 +115,487 @@ class TaskList {
122
115
  * See the License for the specific language governing permissions and
123
116
  * limitations under the License.
124
117
  */
125
- class TaskService {
126
- constructor(http, configService) {
127
- this.http = http;
118
+ class TaskService extends BaseApiService {
119
+ constructor(httpClient, configService) {
120
+ super(httpClient, configService);
121
+ this.httpClient = httpClient;
128
122
  this.configService = configService;
129
- this.valtimoEndpointUri = configService.config.valtimoApi.endpointUri;
130
123
  }
131
124
  queryTasks(params) {
132
- return this.http.get(`${this.valtimoEndpointUri}v1/task`, {
125
+ return this.httpClient.get(this.getApiUrl('/v1/task'), {
133
126
  observe: 'response',
134
127
  params,
135
128
  });
136
129
  }
130
+ queryTasksPage(params) {
131
+ return this.httpClient.get(this.getApiUrl('/v2/task'), {
132
+ params,
133
+ });
134
+ }
135
+ queryTasksPageV3(assigneeFilter = TaskListTab.ALL, pageParams, caseDefinitionName) {
136
+ let httpParams = new HttpParams()
137
+ .set('filter', assigneeFilter.toUpperCase())
138
+ .set('page', pageParams.page)
139
+ .set('size', pageParams.size);
140
+ if (pageParams.sort) {
141
+ httpParams = httpParams.append('sort', pageParams.sort);
142
+ }
143
+ if (caseDefinitionName) {
144
+ return this.httpClient.post(this.getApiUrl('/v3/task'), {
145
+ caseDefinitionName,
146
+ }, { params: httpParams });
147
+ }
148
+ return this.httpClient.post(this.getApiUrl('/v3/task'), {}, { params: httpParams });
149
+ }
137
150
  getTasks() {
138
- return this.http.get(`${this.valtimoEndpointUri}v1/task?filter=all`);
151
+ return this.httpClient.get(this.getApiUrl('/v1/task?filter=all`'));
139
152
  }
140
153
  getTask(id) {
141
- return this.http.get(this.valtimoEndpointUri + 'v1/task/' + id);
154
+ return this.httpClient.get(this.getApiUrl(`/v1/task/${id}`));
142
155
  }
143
156
  getCandidateUsers(id) {
144
- return this.http.get(this.valtimoEndpointUri + 'v2/task/' + id + '/candidate-user');
157
+ return this.httpClient.get(this.getApiUrl(`/v2/task/${id}/candidate-user`));
145
158
  }
146
159
  assignTask(id, assigneeRequest) {
147
- return this.http.post(this.valtimoEndpointUri + 'v1/task/' + id + '/assign', assigneeRequest);
160
+ return this.httpClient.post(this.getApiUrl(`/v1/task/${id}/assign`), assigneeRequest);
148
161
  }
149
162
  unassignTask(id) {
150
- return this.http.post(this.valtimoEndpointUri + 'v1/task/' + id + '/unassign', null);
163
+ return this.httpClient.post(this.getApiUrl(`/v1/task/${id}/unassign`), null);
151
164
  }
152
165
  completeTask(id, variables) {
153
- return this.http.post(this.valtimoEndpointUri + 'v1/task/' + id + '/complete', {
166
+ return this.httpClient.post(this.getApiUrl(`/v1/task/${id}/complete`), {
154
167
  variables,
155
168
  filesToDelete: [],
156
169
  });
157
170
  }
158
171
  getTaskProcessLink(taskId) {
159
- return this.http.get(`${this.valtimoEndpointUri}v2/process-link/task/${taskId}`, {
160
- headers: { [InterceptorSkip]: '' },
172
+ return this.httpClient.get(this.getApiUrl(`/v2/process-link/task/${taskId}`), {
173
+ headers: { [InterceptorSkip]: '404' },
161
174
  });
162
175
  }
163
- getTaskProcessLinkV1(taskId) {
164
- return this.http.get(`${this.valtimoEndpointUri}v1/process-link/task/${taskId}`);
176
+ getTaskListColumns(caseDefinitionName) {
177
+ return this.httpClient.get(this.getApiUrl(`/v1/case/${caseDefinitionName}/task-list-column`));
165
178
  }
166
179
  getConfigCustomTaskList() {
167
180
  return this.configService.config.customTaskList;
168
181
  }
169
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskService, deps: [{ token: i1.HttpClient }, { token: i2.ConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
170
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskService, providedIn: 'root' }); }
182
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskService, deps: [{ token: i1.HttpClient }, { token: i2.ConfigService }], target: i0.ɵɵFactoryTarget.Injectable }); }
183
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskService, providedIn: 'root' }); }
171
184
  }
172
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskService, decorators: [{
185
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskService, decorators: [{
173
186
  type: Injectable,
174
187
  args: [{ providedIn: 'root' }]
175
- }], ctorParameters: function () { return [{ type: i1.HttpClient }, { type: i2.ConfigService }]; } });
188
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.ConfigService }] });
189
+
190
+ /*
191
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
192
+ *
193
+ * Licensed under EUPL, Version 1.2 (the "License");
194
+ * you may not use this file except in compliance with the License.
195
+ * You may obtain a copy of the License at
196
+ *
197
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
198
+ *
199
+ * Unless required by applicable law or agreed to in writing, software
200
+ * distributed under the License is distributed on an "AS IS" basis,
201
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
202
+ * See the License for the specific language governing permissions and
203
+ * limitations under the License.
204
+ */
205
+ class TaskListService {
206
+ get caseDefinitionName$() {
207
+ return this._caseDefinitionName$.asObservable();
208
+ }
209
+ get selectedTaskType$() {
210
+ return this._selectedTaskType$.asObservable();
211
+ }
212
+ get selectedTaskType() {
213
+ return this._selectedTaskType$.getValue();
214
+ }
215
+ get loadingStateForCaseDefinition$() {
216
+ return this._loadingStateForCaseDefinition$.asObservable();
217
+ }
218
+ get ALL_CASES_ID() {
219
+ return this._ALL_CASES_ID;
220
+ }
221
+ constructor(taskService) {
222
+ this.taskService = taskService;
223
+ this._ALL_CASES_ID = 'ALL_CASES';
224
+ this._caseDefinitionName$ = new BehaviorSubject(null);
225
+ this._selectedTaskType$ = new BehaviorSubject(TaskListTab.MINE);
226
+ this._loadingStateForCaseDefinition$ = new BehaviorSubject(false);
227
+ }
228
+ setSelectedTaskType(type) {
229
+ this._selectedTaskType$.next(type);
230
+ }
231
+ setCaseDefinitionName(caseDefinitionName) {
232
+ this._loadingStateForCaseDefinition$.next(true);
233
+ this._caseDefinitionName$.next(caseDefinitionName);
234
+ }
235
+ setLoadingStateForCaseDefinition(loading) {
236
+ this._loadingStateForCaseDefinition$.next(loading);
237
+ }
238
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListService, deps: [{ token: TaskService }], target: i0.ɵɵFactoryTarget.Injectable }); }
239
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListService }); }
240
+ }
241
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListService, decorators: [{
242
+ type: Injectable
243
+ }], ctorParameters: () => [{ type: TaskService }] });
244
+
245
+ /*
246
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
247
+ *
248
+ * Licensed under EUPL, Version 1.2 (the "License");
249
+ * you may not use this file except in compliance with the License.
250
+ * You may obtain a copy of the License at
251
+ *
252
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
253
+ *
254
+ * Unless required by applicable law or agreed to in writing, software
255
+ * distributed under the License is distributed on an "AS IS" basis,
256
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
257
+ * See the License for the specific language governing permissions and
258
+ * limitations under the License.
259
+ */
260
+ class TaskListSortService {
261
+ get sortStateForCurrentTaskType$() {
262
+ return this._sortStateForCurrentTaskType$;
263
+ }
264
+ get sortStringForCurrentTaskType$() {
265
+ return this.sortStateForCurrentTaskType$.pipe(map(sortState => (sortState ? this.getSortString(sortState) : null)));
266
+ }
267
+ get _defaultSortState() {
268
+ return this.taskService.getConfigCustomTaskList()?.defaultSortedColumn || null;
269
+ }
270
+ constructor(taskService, taskListService) {
271
+ this.taskService = taskService;
272
+ this.taskListService = taskListService;
273
+ this._sortState$ = new BehaviorSubject({
274
+ [TaskListTab.ALL]: this._defaultSortState,
275
+ [TaskListTab.MINE]: this._defaultSortState,
276
+ [TaskListTab.OPEN]: this._defaultSortState,
277
+ });
278
+ this._sortStateForCurrentTaskType$ = combineLatest([
279
+ this.taskListService.selectedTaskType$,
280
+ this._sortState$,
281
+ ]).pipe(map(([selectedTaskType, sortStates]) => sortStates[selectedTaskType]));
282
+ }
283
+ updateSortState(taskType, updatedSortState) {
284
+ this._sortState$.pipe(take(1)).subscribe(sortState => {
285
+ this._sortState$.next({
286
+ ...sortState,
287
+ [taskType]: { ...sortState[taskType], ...updatedSortState },
288
+ });
289
+ });
290
+ }
291
+ updateSortStates(updatedSortState) {
292
+ this._sortState$.pipe(take(1)).subscribe(sortStates => {
293
+ const sortStatesCopy = { ...sortStates };
294
+ Object.keys(sortStates).forEach(taskType => {
295
+ sortStatesCopy[taskType] = { ...sortStatesCopy[taskType], ...updatedSortState };
296
+ });
297
+ this._sortState$.next(sortStatesCopy);
298
+ });
299
+ }
300
+ clearSortStates() {
301
+ this._sortState$.pipe(take(1)).subscribe(sortStates => {
302
+ const sortStatesCopy = { ...sortStates };
303
+ Object.keys(sortStates).forEach(taskType => {
304
+ sortStatesCopy[taskType] = null;
305
+ });
306
+ this._sortState$.next(sortStatesCopy);
307
+ });
308
+ }
309
+ resetDefaultSortStates() {
310
+ this._sortState$.pipe(take(1)).subscribe(sortStates => {
311
+ const sortStatesCopy = { ...sortStates };
312
+ Object.keys(sortStates).forEach(taskType => {
313
+ sortStatesCopy[taskType] = this._defaultSortState;
314
+ });
315
+ this._sortState$.next(sortStatesCopy);
316
+ });
317
+ }
318
+ getSortString(sort) {
319
+ return `${sort.state.name},${sort.state.direction}`;
320
+ }
321
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListSortService, deps: [{ token: TaskService }, { token: TaskListService }], target: i0.ɵɵFactoryTarget.Injectable }); }
322
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListSortService }); }
323
+ }
324
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListSortService, decorators: [{
325
+ type: Injectable
326
+ }], ctorParameters: () => [{ type: TaskService }, { type: TaskListService }] });
327
+
328
+ /*
329
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
330
+ *
331
+ * Licensed under EUPL, Version 1.2 (the "License");
332
+ * you may not use this file except in compliance with the License.
333
+ * You may obtain a copy of the License at
334
+ *
335
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
336
+ *
337
+ * Unless required by applicable law or agreed to in writing, software
338
+ * distributed under the License is distributed on an "AS IS" basis,
339
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
340
+ * See the License for the specific language governing permissions and
341
+ * limitations under the License.
342
+ */
343
+ class TaskListColumnService {
344
+ get hasCustomConfigTaskList() {
345
+ return !!this.taskService.getConfigCustomTaskList();
346
+ }
347
+ get fields$() {
348
+ return this._fields$.asObservable();
349
+ }
350
+ get taskListColumnsForCase$() {
351
+ return this.taskListService.caseDefinitionName$.pipe(tap(caseDefinitionName => {
352
+ if (caseDefinitionName === this.taskListService.ALL_CASES_ID) {
353
+ this.resetTaskListFields();
354
+ }
355
+ }), filter(caseDefinitionName => !!caseDefinitionName && caseDefinitionName !== this.taskListService.ALL_CASES_ID), switchMap(caseDefinitionName => this.taskService.getTaskListColumns(caseDefinitionName)), tap(taskListColumns => {
356
+ if (taskListColumns.length === 0) {
357
+ this.taskListSortService.updateSortStates({
358
+ isSorting: true,
359
+ state: {
360
+ name: this._DEFAULT_SPECIFIED_TASK_LIST_FIELDS[0].key,
361
+ direction: 'DESC',
362
+ },
363
+ });
364
+ this._fields$.next(this._DEFAULT_SPECIFIED_TASK_LIST_FIELDS);
365
+ }
366
+ else {
367
+ this._fields$.next(this.mapTaskListColumnToColumnConfig(taskListColumns));
368
+ }
369
+ }), tap(() => this.taskListService.setLoadingStateForCaseDefinition(false)));
370
+ }
371
+ constructor(taskService, taskListService, taskListSortService) {
372
+ this.taskService = taskService;
373
+ this.taskListService = taskListService;
374
+ this.taskListSortService = taskListSortService;
375
+ this._DEFAULT_TASK_LIST_FIELDS = [
376
+ {
377
+ key: 'created',
378
+ label: `task-list.fieldLabels.created`,
379
+ viewType: ViewType.TEXT,
380
+ sortable: true,
381
+ },
382
+ {
383
+ key: 'name',
384
+ label: `task-list.fieldLabels.name`,
385
+ viewType: ViewType.TEXT,
386
+ sortable: true,
387
+ },
388
+ {
389
+ key: 'valtimoAssignee.fullName',
390
+ label: `task-list.fieldLabels.valtimoAssignee.fullName`,
391
+ viewType: ViewType.TEXT,
392
+ },
393
+ {
394
+ key: 'due',
395
+ label: `task-list.fieldLabels.due`,
396
+ viewType: ViewType.TEXT,
397
+ sortable: true,
398
+ },
399
+ {
400
+ key: 'context',
401
+ label: `task-list.fieldLabels.context`,
402
+ viewType: ViewType.TEXT,
403
+ },
404
+ ];
405
+ this._DEFAULT_SPECIFIED_TASK_LIST_FIELDS = [
406
+ {
407
+ key: 'createTime',
408
+ label: `task-list.fieldLabels.created`,
409
+ viewType: ViewType.TEXT,
410
+ sortable: true,
411
+ },
412
+ {
413
+ key: 'name',
414
+ label: `task-list.fieldLabels.name`,
415
+ viewType: ViewType.TEXT,
416
+ sortable: true,
417
+ },
418
+ {
419
+ key: 'assignee',
420
+ label: `task-list.fieldLabels.valtimoAssignee.fullName`,
421
+ viewType: ViewType.TEXT,
422
+ },
423
+ {
424
+ key: 'dueDate',
425
+ label: `task-list.fieldLabels.due`,
426
+ viewType: ViewType.TEXT,
427
+ sortable: true,
428
+ },
429
+ ];
430
+ this._fields$ = new BehaviorSubject(this._DEFAULT_TASK_LIST_FIELDS);
431
+ }
432
+ resetTaskListFields() {
433
+ if (this.hasCustomConfigTaskList) {
434
+ this.setFieldsToCustomTaskListFields();
435
+ }
436
+ else {
437
+ this.setFieldsToDefaultTaskListFields();
438
+ }
439
+ this.taskListSortService.resetDefaultSortStates();
440
+ this.taskListService.setLoadingStateForCaseDefinition(false);
441
+ }
442
+ setFieldsToCustomTaskListFields() {
443
+ const customTaskListFields = this.taskService.getConfigCustomTaskList().fields;
444
+ if (customTaskListFields) {
445
+ this._fields$.next(customTaskListFields.map((column, index) => ({
446
+ key: column.propertyName,
447
+ label: `task-list.fieldLabels.${column.translationKey}`,
448
+ sortable: column.sortable,
449
+ ...(column.viewType && { viewType: column.viewType }),
450
+ ...(column.enum && { enum: column.enum }),
451
+ })));
452
+ }
453
+ }
454
+ setFieldsToDefaultTaskListFields() {
455
+ this._fields$.next(this._DEFAULT_TASK_LIST_FIELDS);
456
+ }
457
+ mapTaskListColumnToColumnConfig(taskListColumns) {
458
+ const hasDefaultSort = !!taskListColumns.find(column => column.defaultSort);
459
+ const firstSortableColumn = taskListColumns.find(column => column.sortable);
460
+ if (!hasDefaultSort && firstSortableColumn) {
461
+ this.taskListSortService.updateSortStates({
462
+ isSorting: true,
463
+ state: {
464
+ name: firstSortableColumn.key,
465
+ direction: 'DESC',
466
+ },
467
+ });
468
+ }
469
+ if (!hasDefaultSort && !firstSortableColumn) {
470
+ this.taskListSortService.clearSortStates();
471
+ }
472
+ return taskListColumns.map(column => {
473
+ if (column.defaultSort) {
474
+ this.taskListSortService.updateSortStates({
475
+ isSorting: true,
476
+ state: {
477
+ name: column.key,
478
+ direction: column.defaultSort,
479
+ },
480
+ });
481
+ }
482
+ return {
483
+ viewType: this.getViewType(column.displayType.type),
484
+ key: column.key,
485
+ label: column.title || column.key,
486
+ sortable: column.sortable,
487
+ ...(column?.displayType?.displayTypeParameters?.enum && {
488
+ enum: column?.displayType?.displayTypeParameters?.enum,
489
+ }),
490
+ ...(column?.displayType?.displayTypeParameters?.dateFormat && {
491
+ format: column?.displayType?.displayTypeParameters?.dateFormat,
492
+ }),
493
+ };
494
+ });
495
+ }
496
+ getViewType(taskListColumnColumnDisplayType) {
497
+ switch (taskListColumnColumnDisplayType) {
498
+ case 'arrayCount':
499
+ return 'relatedFiles';
500
+ case 'underscoresToSpaces':
501
+ return 'stringReplaceUnderscore';
502
+ default:
503
+ return taskListColumnColumnDisplayType;
504
+ }
505
+ }
506
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListColumnService, deps: [{ token: TaskService }, { token: TaskListService }, { token: TaskListSortService }], target: i0.ɵɵFactoryTarget.Injectable }); }
507
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListColumnService }); }
508
+ }
509
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListColumnService, decorators: [{
510
+ type: Injectable
511
+ }], ctorParameters: () => [{ type: TaskService }, { type: TaskListService }, { type: TaskListSortService }] });
512
+
513
+ /*
514
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
515
+ *
516
+ * Licensed under EUPL, Version 1.2 (the "License");
517
+ * you may not use this file except in compliance with the License.
518
+ * You may obtain a copy of the License at
519
+ *
520
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
521
+ *
522
+ * Unless required by applicable law or agreed to in writing, software
523
+ * distributed under the License is distributed on an "AS IS" basis,
524
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
525
+ * See the License for the specific language governing permissions and
526
+ * limitations under the License.
527
+ */
528
+ class TaskListPaginationService {
529
+ get paginationForCurrentTaskType$() {
530
+ return this._paginationForCurrentTaskType$;
531
+ }
532
+ get paginationForCurrentTaskTypeForList$() {
533
+ return this._paginationForCurrentTaskType$.pipe(map(pagination => ({ ...pagination, page: pagination?.page + 1 || 1 })));
534
+ }
535
+ constructor(taskListService) {
536
+ this.taskListService = taskListService;
537
+ this._pagination$ = new BehaviorSubject({
538
+ [TaskListTab.ALL]: this.getDefaultPagination(),
539
+ [TaskListTab.MINE]: this.getDefaultPagination(),
540
+ [TaskListTab.OPEN]: this.getDefaultPagination(),
541
+ });
542
+ this._paginationForCurrentTaskType$ = combineLatest([
543
+ this.taskListService.selectedTaskType$,
544
+ this._pagination$,
545
+ ]).pipe(map(([selectedTaskType, pagination]) => pagination[selectedTaskType]));
546
+ }
547
+ updateTaskPagination(taskType, updatedPagination) {
548
+ this._pagination$.pipe(take(1)).subscribe(pagination => {
549
+ const currentPagination = pagination[taskType];
550
+ this._pagination$.next({
551
+ ...pagination,
552
+ [taskType]: { ...currentPagination, ...updatedPagination },
553
+ });
554
+ });
555
+ }
556
+ getLastAvailablePage(page, size, collectionSize) {
557
+ if (this.isNumber(page) && this.isNumber(size) && this.isNumber(collectionSize) && page !== 0) {
558
+ const amountOfPages = Math.ceil(collectionSize / size);
559
+ if (page + 1 > amountOfPages) {
560
+ return amountOfPages - 1;
561
+ }
562
+ }
563
+ return page;
564
+ }
565
+ isNumber(value) {
566
+ return typeof value === 'number';
567
+ }
568
+ getDefaultPagination() {
569
+ return {
570
+ page: 0,
571
+ size: 10,
572
+ };
573
+ }
574
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListPaginationService, deps: [{ token: TaskListService }], target: i0.ɵɵFactoryTarget.Injectable }); }
575
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListPaginationService }); }
576
+ }
577
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListPaginationService, decorators: [{
578
+ type: Injectable
579
+ }], ctorParameters: () => [{ type: TaskListService }] });
176
580
 
177
581
  /*
178
- * Copyright 2015-2023 Ritense BV, the Netherlands.
582
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
583
+ *
584
+ * Licensed under EUPL, Version 1.2 (the "License");
585
+ * you may not use this file except in compliance with the License.
586
+ * You may obtain a copy of the License at
587
+ *
588
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
589
+ *
590
+ * Unless required by applicable law or agreed to in writing, software
591
+ * distributed under the License is distributed on an "AS IS" basis,
592
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
593
+ * See the License for the specific language governing permissions and
594
+ * limitations under the License.
595
+ */
596
+
597
+ /*
598
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
179
599
  *
180
600
  * Licensed under EUPL, Version 1.2 (the "License");
181
601
  * you may not use this file except in compliance with the License.
@@ -193,45 +613,45 @@ class AssignUserToTaskComponent {
193
613
  constructor(taskService) {
194
614
  this.taskService = taskService;
195
615
  this.assignmentOfTaskChanged = new EventEmitter();
196
- this.assignedEmailOnServer$ = new BehaviorSubject(null);
616
+ this.assignedIdOnServer$ = new BehaviorSubject(null);
197
617
  this.assignedUserFullName$ = new BehaviorSubject(null);
198
618
  this.candidateUsersForTask$ = new BehaviorSubject(undefined);
199
619
  this.disabled$ = new BehaviorSubject(true);
200
- this.userEmailToAssign = null;
620
+ this.userIdToAssign = null;
201
621
  this._subscriptions = new Subscription();
202
622
  }
203
623
  ngOnInit() {
204
624
  this._subscriptions.add(this.taskService.getCandidateUsers(this.taskId).subscribe(candidateUsers => {
205
625
  this.candidateUsersForTask$.next(candidateUsers);
206
- if (this.assigneeEmail) {
207
- this.assignedEmailOnServer$.next(this.assigneeEmail);
208
- this.userEmailToAssign = this.assigneeEmail;
209
- this.assignedUserFullName$.next(this.getAssignedUserName(candidateUsers, this.assigneeEmail));
626
+ if (this.assigneeId) {
627
+ this.assignedIdOnServer$.next(this.assigneeId);
628
+ this.userIdToAssign = this.assigneeId;
629
+ this.assignedUserFullName$.next(this.getAssignedUserName(candidateUsers, this.assigneeId));
210
630
  }
211
631
  this.enable();
212
632
  }));
213
633
  }
214
634
  ngOnChanges(changes) {
215
- this.candidateUsersForTask$.pipe(take(1)).subscribe(candidateUsers => {
216
- const currentUserEmail = changes.assigneeEmail?.currentValue || this.assigneeEmail;
217
- this.assignedEmailOnServer$.next(currentUserEmail || null);
218
- this.userEmailToAssign = currentUserEmail || null;
219
- this.assignedUserFullName$.next(this.getAssignedUserName(candidateUsers ?? [], currentUserEmail));
635
+ this.candidateUsersForTask$.pipe(take$1(1)).subscribe(candidateUsers => {
636
+ const currentUserId = changes.assigneeId?.currentValue || this.assigneeId;
637
+ this.assignedIdOnServer$.next(currentUserId || null);
638
+ this.userIdToAssign = currentUserId || null;
639
+ this.assignedUserFullName$.next(this.getAssignedUserName(candidateUsers ?? [], currentUserId));
220
640
  });
221
641
  }
222
642
  ngOnDestroy() {
223
643
  this._subscriptions.unsubscribe();
224
644
  }
225
- assignTask(userEmail) {
645
+ assignTask(userId) {
226
646
  this.disable();
227
647
  combineLatest([
228
648
  this.candidateUsersForTask$,
229
- this.taskService.assignTask(this.taskId, { assignee: userEmail }),
649
+ this.taskService.assignTask(this.taskId, { assignee: userId }),
230
650
  ])
231
- .pipe(take(1), tap(([candidateUsers]) => {
232
- this.userEmailToAssign = userEmail;
233
- this.assignedEmailOnServer$.next(userEmail);
234
- this.assignedUserFullName$.next(this.getAssignedUserName(candidateUsers ?? [], userEmail));
651
+ .pipe(take$1(1), tap(([candidateUsers]) => {
652
+ this.userIdToAssign = userId;
653
+ this.assignedIdOnServer$.next(userId);
654
+ this.assignedUserFullName$.next(this.getAssignedUserName(candidateUsers ?? [], userId));
235
655
  this.emitChange();
236
656
  this.enable();
237
657
  }))
@@ -248,23 +668,23 @@ class AssignUserToTaskComponent {
248
668
  }))
249
669
  .subscribe();
250
670
  }
251
- getAssignedUserName(users, userEmail) {
252
- if (users && userEmail) {
253
- const findUser = users.find(user => user.email === userEmail);
254
- return findUser ? findUser.label : userEmail;
671
+ getAssignedUserName(users, userId) {
672
+ if (users && userId) {
673
+ const findUser = users.find(user => user.id === userId);
674
+ return findUser ? findUser.label : userId;
255
675
  }
256
- return userEmail || '-';
676
+ return userId || '-';
257
677
  }
258
678
  mapUsersForDropdown(users) {
259
679
  return (users &&
260
680
  users
261
681
  .map(user => ({ ...user, lastName: user.lastName?.split(' ').splice(-1)[0] || '' }))
262
682
  .sort((a, b) => a.lastName.localeCompare(b.lastName))
263
- .map(user => ({ text: user.label, id: user.email })));
683
+ .map(user => ({ text: user.label, id: user.id })));
264
684
  }
265
685
  clear() {
266
- this.assignedEmailOnServer$.next(null);
267
- this.userEmailToAssign = null;
686
+ this.assignedIdOnServer$.next(null);
687
+ this.userIdToAssign = null;
268
688
  }
269
689
  emitChange() {
270
690
  this.assignmentOfTaskChanged.emit();
@@ -275,22 +695,22 @@ class AssignUserToTaskComponent {
275
695
  disable() {
276
696
  this.disabled$.next(true);
277
697
  }
278
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AssignUserToTaskComponent, deps: [{ token: TaskService }], target: i0.ɵɵFactoryTarget.Component }); }
279
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: AssignUserToTaskComponent, selector: "valtimo-assign-user-to-task", inputs: { taskId: "taskId", assigneeEmail: "assigneeEmail" }, outputs: { assignmentOfTaskChanged: "assignmentOfTaskChanged" }, usesOnChanges: true, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n candidateUsers: candidateUsersForTask$ | async,\n disabled: disabled$ | async,\n emailOnServer: assignedEmailOnServer$ | async\n } as obs\"\n>\n <div class=\"container-fluid\">\n <div class=\"row mt-2 mb-2\">\n <div class=\"col-12 pl-0 d-flex flex-row align-items-center\">\n <valtimo-searchable-dropdown-select\n *ngIf=\"obs.candidateUsers; else loading\"\n [style]=\"'underlinedText'\"\n [items]=\"mapUsersForDropdown(obs.candidateUsers)\"\n [buttonText]=\"'assignTask.header' | translate\"\n [searchText]=\"'interface.typeToSearch' | translate\"\n [noResultsText]=\"'interface.noSearchResults' | translate\"\n [disabled]=\"obs.disabled\"\n [selectedText]=\"'assignTask.assignedTo' | translate\"\n [selectedTextValue]=\"assignedUserFullName$ | async\"\n [clearSelectionButtonTitle]=\"'assignTask.remove' | translate\"\n [hasSelection]=\"userEmailToAssign === obs.emailOnServer && obs.emailOnServer !== null\"\n [width]=\"250\"\n (itemSelected)=\"assignTask($event)\"\n (clearSelection)=\"unassignTask()\"\n >\n </valtimo-searchable-dropdown-select>\n </div>\n </div>\n </div>\n</ng-container>\n\n<ng-template #loading>\n <h5>\n <b>{{ 'assignTask.fetchingUsers' | translate }}</b>\n </h5>\n</ng-template>\n", styles: ["/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.container-fluid{color:#959595}i{font-size:13px}\n"], dependencies: [{ kind: "directive", type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.SearchableDropdownSelectComponent, selector: "valtimo-searchable-dropdown-select", inputs: ["style", "items", "buttonText", "searchText", "noResultsText", "disabled", "selectedText", "selectedTextValue", "clearSelectionButtonTitle", "hasSelection", "width", "hasPermission"], outputs: ["itemSelected", "clearSelection"] }, { kind: "pipe", type: i8.AsyncPipe, name: "async" }, { kind: "pipe", type: i8$1.TranslatePipe, name: "translate" }] }); }
698
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: AssignUserToTaskComponent, deps: [{ token: TaskService }], target: i0.ɵɵFactoryTarget.Component }); }
699
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.3", type: AssignUserToTaskComponent, selector: "valtimo-assign-user-to-task", inputs: { taskId: "taskId", assigneeId: "assigneeId" }, outputs: { assignmentOfTaskChanged: "assignmentOfTaskChanged" }, usesOnChanges: true, ngImport: i0, template: "<!--\n ~ Copyright 2015-2024 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<ng-container\n *ngIf=\"{\n candidateUsers: candidateUsersForTask$ | async,\n disabled: disabled$ | async,\n idOnServer: assignedIdOnServer$ | async\n } as obs\"\n>\n <div class=\"container-fluid\">\n <div class=\"row mt-2 mb-2\">\n <div class=\"col-12 pl-0 d-flex flex-row align-items-center\">\n <valtimo-searchable-dropdown-select\n *ngIf=\"obs.candidateUsers; else loading\"\n [style]=\"'underlinedText'\"\n [items]=\"mapUsersForDropdown(obs.candidateUsers)\"\n [buttonText]=\"'assignTask.header' | translate\"\n [searchText]=\"'interface.typeToSearch' | translate\"\n [noResultsText]=\"'interface.noSearchResults' | translate\"\n [disabled]=\"obs.disabled\"\n [selectedText]=\"'assignTask.assignedTo' | translate\"\n [selectedTextValue]=\"assignedUserFullName$ | async\"\n [clearSelectionButtonTitle]=\"'assignTask.remove' | translate\"\n [hasSelection]=\"userIdToAssign === obs.idOnServer && obs.idOnServer !== null\"\n [width]=\"250\"\n (itemSelected)=\"assignTask($event)\"\n (clearSelection)=\"unassignTask()\"\n >\n </valtimo-searchable-dropdown-select>\n </div>\n </div>\n </div>\n</ng-container>\n\n<ng-template #loading>\n <h5>\n <b>{{ 'assignTask.fetchingUsers' | translate }}</b>\n </h5>\n</ng-template>\n", styles: [".container-fluid{color:#959595}i{font-size:13px}\n/*!\n * Copyright 2015-2024 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i9.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.SearchableDropdownSelectComponent, selector: "valtimo-searchable-dropdown-select", inputs: ["style", "items", "buttonText", "searchText", "noResultsText", "disabled", "selectedText", "selectedTextValue", "clearSelectionButtonTitle", "hasSelection", "width", "hasPermission", "showClearSelection"], outputs: ["itemSelected", "clearSelection"] }, { kind: "pipe", type: i9.AsyncPipe, name: "async" }, { kind: "pipe", type: i8.TranslatePipe, name: "translate" }] }); }
280
700
  }
281
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AssignUserToTaskComponent, decorators: [{
701
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: AssignUserToTaskComponent, decorators: [{
282
702
  type: Component,
283
- args: [{ selector: 'valtimo-assign-user-to-task', template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n candidateUsers: candidateUsersForTask$ | async,\n disabled: disabled$ | async,\n emailOnServer: assignedEmailOnServer$ | async\n } as obs\"\n>\n <div class=\"container-fluid\">\n <div class=\"row mt-2 mb-2\">\n <div class=\"col-12 pl-0 d-flex flex-row align-items-center\">\n <valtimo-searchable-dropdown-select\n *ngIf=\"obs.candidateUsers; else loading\"\n [style]=\"'underlinedText'\"\n [items]=\"mapUsersForDropdown(obs.candidateUsers)\"\n [buttonText]=\"'assignTask.header' | translate\"\n [searchText]=\"'interface.typeToSearch' | translate\"\n [noResultsText]=\"'interface.noSearchResults' | translate\"\n [disabled]=\"obs.disabled\"\n [selectedText]=\"'assignTask.assignedTo' | translate\"\n [selectedTextValue]=\"assignedUserFullName$ | async\"\n [clearSelectionButtonTitle]=\"'assignTask.remove' | translate\"\n [hasSelection]=\"userEmailToAssign === obs.emailOnServer && obs.emailOnServer !== null\"\n [width]=\"250\"\n (itemSelected)=\"assignTask($event)\"\n (clearSelection)=\"unassignTask()\"\n >\n </valtimo-searchable-dropdown-select>\n </div>\n </div>\n </div>\n</ng-container>\n\n<ng-template #loading>\n <h5>\n <b>{{ 'assignTask.fetchingUsers' | translate }}</b>\n </h5>\n</ng-template>\n", styles: ["/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.container-fluid{color:#959595}i{font-size:13px}\n"] }]
284
- }], ctorParameters: function () { return [{ type: TaskService }]; }, propDecorators: { taskId: [{
703
+ args: [{ selector: 'valtimo-assign-user-to-task', template: "<!--\n ~ Copyright 2015-2024 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<ng-container\n *ngIf=\"{\n candidateUsers: candidateUsersForTask$ | async,\n disabled: disabled$ | async,\n idOnServer: assignedIdOnServer$ | async\n } as obs\"\n>\n <div class=\"container-fluid\">\n <div class=\"row mt-2 mb-2\">\n <div class=\"col-12 pl-0 d-flex flex-row align-items-center\">\n <valtimo-searchable-dropdown-select\n *ngIf=\"obs.candidateUsers; else loading\"\n [style]=\"'underlinedText'\"\n [items]=\"mapUsersForDropdown(obs.candidateUsers)\"\n [buttonText]=\"'assignTask.header' | translate\"\n [searchText]=\"'interface.typeToSearch' | translate\"\n [noResultsText]=\"'interface.noSearchResults' | translate\"\n [disabled]=\"obs.disabled\"\n [selectedText]=\"'assignTask.assignedTo' | translate\"\n [selectedTextValue]=\"assignedUserFullName$ | async\"\n [clearSelectionButtonTitle]=\"'assignTask.remove' | translate\"\n [hasSelection]=\"userIdToAssign === obs.idOnServer && obs.idOnServer !== null\"\n [width]=\"250\"\n (itemSelected)=\"assignTask($event)\"\n (clearSelection)=\"unassignTask()\"\n >\n </valtimo-searchable-dropdown-select>\n </div>\n </div>\n </div>\n</ng-container>\n\n<ng-template #loading>\n <h5>\n <b>{{ 'assignTask.fetchingUsers' | translate }}</b>\n </h5>\n</ng-template>\n", styles: [".container-fluid{color:#959595}i{font-size:13px}\n/*!\n * Copyright 2015-2024 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"] }]
704
+ }], ctorParameters: () => [{ type: TaskService }], propDecorators: { taskId: [{
285
705
  type: Input
286
- }], assigneeEmail: [{
706
+ }], assigneeId: [{
287
707
  type: Input
288
708
  }], assignmentOfTaskChanged: [{
289
709
  type: Output
290
710
  }] } });
291
711
 
292
712
  /*
293
- * Copyright 2015-2023 Ritense BV, the Netherlands.
713
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
294
714
  *
295
715
  * Licensed under EUPL, Version 1.2 (the "License");
296
716
  * you may not use this file except in compliance with the License.
@@ -383,7 +803,7 @@ class TaskDetailModalComponent {
383
803
  this.formIoFormData$.next(submission.data);
384
804
  }
385
805
  combineLatest([this.processLinkId$, this.taskProcessLinkType$, this.task$])
386
- .pipe(take$1(1))
806
+ .pipe(take(1))
387
807
  .subscribe(([processLinkId, taskProcessLinkType, task]) => {
388
808
  if (taskProcessLinkType === 'form') {
389
809
  if (processLinkId) {
@@ -402,7 +822,7 @@ class TaskDetailModalComponent {
402
822
  });
403
823
  }
404
824
  completeTask() {
405
- this.task$.pipe(take$1(1)).subscribe(task => {
825
+ this.task$.pipe(take(1)).subscribe(task => {
406
826
  this.toastr.success(`${task.name} ${this.translateService.instant('taskDetail.taskCompleted')}`);
407
827
  this.modal.hide();
408
828
  this.task$.next(null);
@@ -430,29 +850,12 @@ class TaskDetailModalComponent {
430
850
  }
431
851
  this.loading$.next(false);
432
852
  }
433
- else {
434
- this.getLegacyTaskProcessLink(taskId);
435
- }
436
853
  },
437
854
  error: _ => {
438
- this.getLegacyTaskProcessLink(taskId);
855
+ this.loading$.next(false);
439
856
  },
440
857
  });
441
858
  }
442
- getLegacyTaskProcessLink(taskId) {
443
- this.taskService.getTaskProcessLinkV1(taskId).subscribe(resV1 => {
444
- switch (resV1?.type) {
445
- case 'form':
446
- this.taskProcessLinkType$.next('form');
447
- break;
448
- case 'form-flow':
449
- this.taskProcessLinkType$.next('form-flow');
450
- this.formFlowInstanceId$.next(resV1.properties.formFlowInstanceId);
451
- break;
452
- }
453
- this.loading$.next(false);
454
- });
455
- }
456
859
  resetTaskProcessLinkType() {
457
860
  this.taskProcessLinkType$.next(null);
458
861
  this.processLinkId$.next(null);
@@ -471,13 +874,13 @@ class TaskDetailModalComponent {
471
874
  this.stateService.setDocumentDefinitionName(documentDefinitionName);
472
875
  });
473
876
  }
474
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskDetailModalComponent, deps: [{ token: i1$1.ToastrService }, { token: i2$1.ProcessLinkService }, { token: i3.Router }, { token: TaskService }, { token: i5.UserProviderService }, { token: i6.ValtimoModalService }, { token: i6.FormIoStateService }, { token: i7.DocumentService }, { token: i8$1.TranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
475
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TaskDetailModalComponent, selector: "valtimo-task-detail-modal", outputs: { formSubmit: "formSubmit", assignmentOfTaskChanged: "assignmentOfTaskChanged" }, viewQueries: [{ propertyName: "form", first: true, predicate: ["form"], descendants: true }, { propertyName: "formFlow", first: true, predicate: ["formFlow"], descendants: true }, { propertyName: "modal", first: true, predicate: ["taskDetailModal"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-modal\n #taskDetailModal\n *ngIf=\"{\n loading: loading$ | async,\n page: page$ | async,\n task: task$ | async,\n formDefinition: formDefinition$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async\n } as obs\"\n elementId=\"taskDetailModal\"\n [title]=\"obs.page?.title\"\n [subtitle]=\"obs.page?.subtitle\"\n [templateBelowSubtitle]=\"assignUserToTask\"\n>\n <div body *ngIf=\"obs.formDefinition && obs.processLinkIsForm\">\n <valtimo-form-io\n #form\n [form]=\"obs.formDefinition\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n </div>\n <div body *ngIf=\"obs.processLinkIsFormFlow\">\n <valtimo-form-flow\n #formFlow\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask()\"\n ></valtimo-form-flow>\n </div>\n <div body *ngIf=\"obs.loading\">\n <div class=\"text-black mb-0 p-3 text-center\">\n {{ 'formManagement.loading' | translate }}\n </div>\n </div>\n <div\n body\n *ngIf=\"\n obs.loading === false && !obs.formDefinition && !obs.formFlowInstanceId && !obs.errorMessage\n \"\n >\n <div class=\"bg-warning text-black mb-0 p-3 text-center\">\n {{\n (isAdmin$ | async)\n ? ('formManagement.noFormDefinitionFoundAdmin' | translate)\n : ('formManagement.noFormDefinitionFoundUser' | translate)\n }}\n </div>\n </div>\n <div body *ngIf=\"obs.errorMessage\">\n <div class=\"bg-danger text-black mb-0 p-3 text-center\">\n {{ obs.errorMessage }}\n </div>\n </div>\n <div footer>\n <div class=\"mb-0 p-3 text-center\" *ngIf=\"!!obs.formDefinition\">\n <button\n class=\"btn btn-secondary btn-space\"\n type=\"button\"\n (click)=\"gotoProcessLinkScreen()\"\n id=\"process-link-button\"\n >\n {{ 'formManagement.gotoProcessLinksButton' | translate }}\n </button>\n </div>\n </div>\n</valtimo-modal>\n\n<ng-template #assignUserToTask>\n <ng-container *ngIf=\"task$ | async as task\">\n <valtimo-assign-user-to-task\n *ngIf=\"task && assignmentOfTaskChanged\"\n [taskId]=\"task.id\"\n [assigneeEmail]=\"task.assignee\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n </ng-container>\n</ng-template>\n", styles: ["/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */#taskDetailModal .formio-component-submit{text-align:right}\n"], dependencies: [{ kind: "directive", type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.FormioComponent, selector: "valtimo-form-io", inputs: ["options", "submission", "form", "readOnly", "formRefresh$"], outputs: ["submit", "change"] }, { kind: "component", type: i6.ModalComponent, selector: "valtimo-modal", inputs: ["elementId", "title", "subtitle", "templateBelowSubtitle", "showFooter"] }, { kind: "component", type: i2$1.FormFlowComponent, selector: "valtimo-form-flow", inputs: ["formIoFormData", "formFlowInstanceId"], outputs: ["formFlowComplete"] }, { kind: "component", type: AssignUserToTaskComponent, selector: "valtimo-assign-user-to-task", inputs: ["taskId", "assigneeEmail"], outputs: ["assignmentOfTaskChanged"] }, { kind: "pipe", type: i8.AsyncPipe, name: "async" }, { kind: "pipe", type: i8$1.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None }); }
877
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskDetailModalComponent, deps: [{ token: i1$1.ToastrService }, { token: i2$1.ProcessLinkService }, { token: i3.Router }, { token: TaskService }, { token: i5.UserProviderService }, { token: i6.ValtimoModalService }, { token: i6.FormIoStateService }, { token: i7.DocumentService }, { token: i8.TranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
878
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.3", type: TaskDetailModalComponent, selector: "valtimo-task-detail-modal", outputs: { formSubmit: "formSubmit", assignmentOfTaskChanged: "assignmentOfTaskChanged" }, viewQueries: [{ propertyName: "form", first: true, predicate: ["form"], descendants: true }, { propertyName: "formFlow", first: true, predicate: ["formFlow"], descendants: true }, { propertyName: "modal", first: true, predicate: ["taskDetailModal"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2024 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-modal\n #taskDetailModal\n *ngIf=\"{\n loading: loading$ | async,\n page: page$ | async,\n task: task$ | async,\n formDefinition: formDefinition$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async\n } as obs\"\n elementId=\"taskDetailModal\"\n [title]=\"obs.page?.title\"\n [subtitle]=\"obs.page?.subtitle\"\n [templateBelowSubtitle]=\"assignUserToTask\"\n>\n <div body *ngIf=\"obs.formDefinition && obs.processLinkIsForm\">\n <valtimo-form-io\n #form\n [form]=\"obs.formDefinition\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n </div>\n <div body *ngIf=\"obs.processLinkIsFormFlow\">\n <valtimo-form-flow\n #formFlow\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask()\"\n ></valtimo-form-flow>\n </div>\n <div body *ngIf=\"obs.loading\">\n <div class=\"text-black mb-0 p-3 text-center\">\n {{ 'formManagement.loading' | translate }}\n </div>\n </div>\n <div\n body\n *ngIf=\"\n obs.loading === false && !obs.formDefinition && !obs.formFlowInstanceId && !obs.errorMessage\n \"\n >\n <div class=\"bg-warning text-black mb-0 p-3 text-center\">\n {{\n (isAdmin$ | async)\n ? ('formManagement.noFormDefinitionFoundAdmin' | translate)\n : ('formManagement.noFormDefinitionFoundUser' | translate)\n }}\n </div>\n </div>\n <div body *ngIf=\"obs.errorMessage\">\n <div class=\"bg-danger text-black mb-0 p-3 text-center\">\n {{ obs.errorMessage }}\n </div>\n </div>\n <div footer>\n <div class=\"mb-0 p-3 text-center\" *ngIf=\"!!obs.formDefinition\">\n <button\n class=\"btn btn-secondary btn-space\"\n type=\"button\"\n (click)=\"gotoProcessLinkScreen()\"\n id=\"process-link-button\"\n >\n {{ 'formManagement.gotoProcessLinksButton' | translate }}\n </button>\n </div>\n </div>\n</valtimo-modal>\n\n<ng-template #assignUserToTask>\n <ng-container *ngIf=\"task$ | async as task\">\n <valtimo-assign-user-to-task\n *ngIf=\"task && assignmentOfTaskChanged\"\n [taskId]=\"task.id\"\n [assigneeId]=\"task.assignee\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n </ng-container>\n</ng-template>\n", styles: ["#taskDetailModal .formio-component-submit{text-align:right}\n/*!\n * Copyright 2015-2024 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i9.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.FormioComponent, selector: "valtimo-form-io", inputs: ["options", "submission", "form", "readOnly", "formRefresh$"], outputs: ["submit", "change"] }, { kind: "component", type: i6.ModalComponent, selector: "valtimo-modal", inputs: ["elementId", "title", "subtitle", "templateBelowSubtitle", "showFooter"] }, { kind: "component", type: i2$1.FormFlowComponent, selector: "valtimo-form-flow", inputs: ["formIoFormData", "formFlowInstanceId"], outputs: ["formFlowComplete"] }, { kind: "component", type: AssignUserToTaskComponent, selector: "valtimo-assign-user-to-task", inputs: ["taskId", "assigneeId"], outputs: ["assignmentOfTaskChanged"] }, { kind: "pipe", type: i9.AsyncPipe, name: "async" }, { kind: "pipe", type: i8.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None }); }
476
879
  }
477
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskDetailModalComponent, decorators: [{
880
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskDetailModalComponent, decorators: [{
478
881
  type: Component,
479
- args: [{ selector: 'valtimo-task-detail-modal', encapsulation: ViewEncapsulation.None, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-modal\n #taskDetailModal\n *ngIf=\"{\n loading: loading$ | async,\n page: page$ | async,\n task: task$ | async,\n formDefinition: formDefinition$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async\n } as obs\"\n elementId=\"taskDetailModal\"\n [title]=\"obs.page?.title\"\n [subtitle]=\"obs.page?.subtitle\"\n [templateBelowSubtitle]=\"assignUserToTask\"\n>\n <div body *ngIf=\"obs.formDefinition && obs.processLinkIsForm\">\n <valtimo-form-io\n #form\n [form]=\"obs.formDefinition\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n </div>\n <div body *ngIf=\"obs.processLinkIsFormFlow\">\n <valtimo-form-flow\n #formFlow\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask()\"\n ></valtimo-form-flow>\n </div>\n <div body *ngIf=\"obs.loading\">\n <div class=\"text-black mb-0 p-3 text-center\">\n {{ 'formManagement.loading' | translate }}\n </div>\n </div>\n <div\n body\n *ngIf=\"\n obs.loading === false && !obs.formDefinition && !obs.formFlowInstanceId && !obs.errorMessage\n \"\n >\n <div class=\"bg-warning text-black mb-0 p-3 text-center\">\n {{\n (isAdmin$ | async)\n ? ('formManagement.noFormDefinitionFoundAdmin' | translate)\n : ('formManagement.noFormDefinitionFoundUser' | translate)\n }}\n </div>\n </div>\n <div body *ngIf=\"obs.errorMessage\">\n <div class=\"bg-danger text-black mb-0 p-3 text-center\">\n {{ obs.errorMessage }}\n </div>\n </div>\n <div footer>\n <div class=\"mb-0 p-3 text-center\" *ngIf=\"!!obs.formDefinition\">\n <button\n class=\"btn btn-secondary btn-space\"\n type=\"button\"\n (click)=\"gotoProcessLinkScreen()\"\n id=\"process-link-button\"\n >\n {{ 'formManagement.gotoProcessLinksButton' | translate }}\n </button>\n </div>\n </div>\n</valtimo-modal>\n\n<ng-template #assignUserToTask>\n <ng-container *ngIf=\"task$ | async as task\">\n <valtimo-assign-user-to-task\n *ngIf=\"task && assignmentOfTaskChanged\"\n [taskId]=\"task.id\"\n [assigneeEmail]=\"task.assignee\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n </ng-container>\n</ng-template>\n", styles: ["/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */#taskDetailModal .formio-component-submit{text-align:right}\n"] }]
480
- }], ctorParameters: function () { return [{ type: i1$1.ToastrService }, { type: i2$1.ProcessLinkService }, { type: i3.Router }, { type: TaskService }, { type: i5.UserProviderService }, { type: i6.ValtimoModalService }, { type: i6.FormIoStateService }, { type: i7.DocumentService }, { type: i8$1.TranslateService }]; }, propDecorators: { form: [{
882
+ args: [{ selector: 'valtimo-task-detail-modal', encapsulation: ViewEncapsulation.None, template: "<!--\n ~ Copyright 2015-2024 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-modal\n #taskDetailModal\n *ngIf=\"{\n loading: loading$ | async,\n page: page$ | async,\n task: task$ | async,\n formDefinition: formDefinition$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async\n } as obs\"\n elementId=\"taskDetailModal\"\n [title]=\"obs.page?.title\"\n [subtitle]=\"obs.page?.subtitle\"\n [templateBelowSubtitle]=\"assignUserToTask\"\n>\n <div body *ngIf=\"obs.formDefinition && obs.processLinkIsForm\">\n <valtimo-form-io\n #form\n [form]=\"obs.formDefinition\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n </div>\n <div body *ngIf=\"obs.processLinkIsFormFlow\">\n <valtimo-form-flow\n #formFlow\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask()\"\n ></valtimo-form-flow>\n </div>\n <div body *ngIf=\"obs.loading\">\n <div class=\"text-black mb-0 p-3 text-center\">\n {{ 'formManagement.loading' | translate }}\n </div>\n </div>\n <div\n body\n *ngIf=\"\n obs.loading === false && !obs.formDefinition && !obs.formFlowInstanceId && !obs.errorMessage\n \"\n >\n <div class=\"bg-warning text-black mb-0 p-3 text-center\">\n {{\n (isAdmin$ | async)\n ? ('formManagement.noFormDefinitionFoundAdmin' | translate)\n : ('formManagement.noFormDefinitionFoundUser' | translate)\n }}\n </div>\n </div>\n <div body *ngIf=\"obs.errorMessage\">\n <div class=\"bg-danger text-black mb-0 p-3 text-center\">\n {{ obs.errorMessage }}\n </div>\n </div>\n <div footer>\n <div class=\"mb-0 p-3 text-center\" *ngIf=\"!!obs.formDefinition\">\n <button\n class=\"btn btn-secondary btn-space\"\n type=\"button\"\n (click)=\"gotoProcessLinkScreen()\"\n id=\"process-link-button\"\n >\n {{ 'formManagement.gotoProcessLinksButton' | translate }}\n </button>\n </div>\n </div>\n</valtimo-modal>\n\n<ng-template #assignUserToTask>\n <ng-container *ngIf=\"task$ | async as task\">\n <valtimo-assign-user-to-task\n *ngIf=\"task && assignmentOfTaskChanged\"\n [taskId]=\"task.id\"\n [assigneeId]=\"task.assignee\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n </ng-container>\n</ng-template>\n", styles: ["#taskDetailModal .formio-component-submit{text-align:right}\n/*!\n * Copyright 2015-2024 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"] }]
883
+ }], ctorParameters: () => [{ type: i1$1.ToastrService }, { type: i2$1.ProcessLinkService }, { type: i3.Router }, { type: TaskService }, { type: i5.UserProviderService }, { type: i6.ValtimoModalService }, { type: i6.FormIoStateService }, { type: i7.DocumentService }, { type: i8.TranslateService }], propDecorators: { form: [{
481
884
  type: ViewChild,
482
885
  args: ['form']
483
886
  }], formFlow: [{
@@ -493,7 +896,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
493
896
  }] } });
494
897
 
495
898
  /*
496
- * Copyright 2015-2023 Ritense BV, the Netherlands.
899
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
497
900
  *
498
901
  * Licensed under EUPL, Version 1.2 (the "License");
499
902
  * you may not use this file except in compliance with the License.
@@ -531,7 +934,7 @@ const CAN_VIEW_CASE_PERMISSION = {
531
934
  };
532
935
 
533
936
  /*
534
- * Copyright 2015-2023 Ritense BV, the Netherlands.
937
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
535
938
  *
536
939
  * Licensed under EUPL, Version 1.2 (the "License");
537
940
  * you may not use this file except in compliance with the License.
@@ -547,231 +950,255 @@ const CAN_VIEW_CASE_PERMISSION = {
547
950
  */
548
951
  moment.locale(localStorage.getItem('langKey') || '');
549
952
  class TaskListComponent {
550
- constructor(configService, documentService, logger, permissionService, router, taskService, translateService) {
953
+ constructor(configService, documentService, permissionService, router, taskService, taskListService, translateService, taskListColumnService, taskListPaginationService, taskListSortService) {
551
954
  this.configService = configService;
552
955
  this.documentService = documentService;
553
- this.logger = logger;
554
956
  this.permissionService = permissionService;
555
957
  this.router = router;
556
958
  this.taskService = taskService;
959
+ this.taskListService = taskListService;
557
960
  this.translateService = translateService;
558
- this.tasks = {
559
- mine: new TaskList(),
560
- open: new TaskList(),
561
- all: new TaskList(),
562
- };
563
- this.visibleTabs = null;
564
- this.currentTaskType = 'mine';
565
- this.listTitle = null;
566
- this.listDescription = null;
567
- this.sortState = null;
961
+ this.taskListColumnService = taskListColumnService;
962
+ this.taskListPaginationService = taskListPaginationService;
963
+ this.taskListSortService = taskListSortService;
964
+ this.selectedTaskType$ = this.taskListService.selectedTaskType$;
965
+ this.fields$ = this.taskListColumnService.fields$;
568
966
  this.loadingTasks$ = new BehaviorSubject(true);
569
- this.activeTab$ = new BehaviorSubject('');
570
- this.visibleTabs = this.configService.config?.visibleTaskListTabs || null;
571
- if (this.visibleTabs) {
572
- this.currentTaskType = this.visibleTabs[0];
573
- }
574
- this.setDefaultSorting();
967
+ this.visibleTabs$ = new BehaviorSubject(null);
968
+ this._enableLoadingAnimation$ = new BehaviorSubject(true);
969
+ this.cachedTasks$ = new BehaviorSubject(null);
970
+ this.paginationForCurrentTaskTypeForList$ = this.taskListPaginationService.paginationForCurrentTaskTypeForList$;
971
+ this.sortStateForCurrentTaskType$ = this.taskListSortService.sortStateForCurrentTaskType$;
972
+ this._reload$ = new BehaviorSubject(true);
973
+ this.tasks$ = combineLatest([
974
+ this.taskListService.loadingStateForCaseDefinition$,
975
+ this.selectedTaskType$,
976
+ this.taskListPaginationService.paginationForCurrentTaskType$,
977
+ this.taskListSortService.sortStringForCurrentTaskType$,
978
+ this.taskListService.caseDefinitionName$,
979
+ this._enableLoadingAnimation$,
980
+ this._reload$,
981
+ ]).pipe(filter$1(([loadingStateForCaseDefinition]) => loadingStateForCaseDefinition === false), map(([_, selectedTaskType, paginationForSelectedTaskType, sortStringForSelectedTaskType, caseDefinitionName, enableLoadingAnimation, reload,]) => this.getTaskListParams(paginationForSelectedTaskType, sortStringForSelectedTaskType, selectedTaskType, caseDefinitionName, enableLoadingAnimation, reload)), distinctUntilChanged$1((previous, current) => isEqual(previous.params, current.params)), tap(({ enableLoadingAnimation }) => {
982
+ if (enableLoadingAnimation)
983
+ this.loadingTasks$.next(true);
984
+ }), switchMap(({ params }) => combineLatest([
985
+ this.taskService.queryTasksPageV3(params.selectedTaskType, params.params, params.caseDefinitionName),
986
+ of(!!params.caseDefinitionName),
987
+ ])), switchMap(([tasksResult, isSpecified]) => this.getTaskListPermissionsRequest(tasksResult, isSpecified)), map(([isSpecified, taskResult, canViewTaskPermissions, canViewCasePermissions]) => {
988
+ this.updateTaskListPaginationAfterResponse(Number(taskResult.totalElements));
989
+ return this.mapTasksForList(isSpecified, taskResult, canViewTaskPermissions, canViewCasePermissions);
990
+ }), tap(tasks => {
991
+ this.cachedTasks$.next(tasks);
992
+ this.loadingTasks$.next(false);
993
+ this.disableLoadingAnimation();
994
+ }));
995
+ this.loadingCaseListItems$ = new BehaviorSubject(true);
996
+ this._selectedCaseDefinitionId$ = new BehaviorSubject(this.taskListService.ALL_CASES_ID);
997
+ this.caseListItems$ = combineLatest([
998
+ this.documentService.getAllDefinitions(),
999
+ this._selectedCaseDefinitionId$,
1000
+ this.translateService.stream('key'),
1001
+ ]).pipe(map(([documentDefinitionRes, selectedCaseDefinitionId]) => [
1002
+ {
1003
+ content: this.translateService.instant('task-list.allCases'),
1004
+ id: this.taskListService.ALL_CASES_ID,
1005
+ selected: selectedCaseDefinitionId === this.taskListService.ALL_CASES_ID,
1006
+ },
1007
+ ...documentDefinitionRes.content.map(documentDefinition => ({
1008
+ id: documentDefinition.id.name,
1009
+ content: documentDefinition?.schema?.title,
1010
+ selected: documentDefinition.id.name === selectedCaseDefinitionId,
1011
+ })),
1012
+ ]), tap(() => this.loadingCaseListItems$.next(false)));
1013
+ this.taskListColumnsForCase$ = this.taskListColumnService.taskListColumnsForCase$;
1014
+ this._DEFAULT_TASK_LIST_TABS = [
1015
+ TaskListTab.MINE,
1016
+ TaskListTab.OPEN,
1017
+ TaskListTab.ALL,
1018
+ ];
575
1019
  }
576
- ngOnDestroy() {
577
- this.closeTranslationSubscription();
1020
+ ngOnInit() {
1021
+ this.taskListColumnService.resetTaskListFields();
1022
+ this.setVisibleTabs();
578
1023
  }
579
1024
  paginationClicked(page, type) {
580
- this.tasks[type].page = page - 1;
581
- this.tasks[type].pagination.page = page;
582
- this.getTasks(type);
1025
+ this.taskListPaginationService.updateTaskPagination(type, { page: page - 1 });
583
1026
  }
584
- paginationSet(size) {
585
- this.tasks.mine.pagination.size =
586
- this.tasks.all.pagination.size =
587
- this.tasks.open.pagination.size =
588
- size;
589
- this.getTasks(this.currentTaskType);
1027
+ paginationSet(newSize) {
1028
+ combineLatest([
1029
+ this.taskListPaginationService.paginationForCurrentTaskType$,
1030
+ this.taskListService.selectedTaskType$,
1031
+ ])
1032
+ .pipe(take(1))
1033
+ .subscribe(([pagination, selectedTaskType]) => {
1034
+ this.taskListPaginationService.updateTaskPagination(selectedTaskType, {
1035
+ size: Number(newSize),
1036
+ page: this.taskListPaginationService.getLastAvailablePage(pagination.page, Number(newSize), pagination.collectionSize),
1037
+ });
1038
+ });
590
1039
  }
591
1040
  tabChange(tab) {
592
- this.clearPagination(this.currentTaskType);
593
- this.getTasks(tab);
594
- }
595
- showTask(task) {
596
- this.router.navigate(['tasks', task.id]);
597
- }
598
- getTasks(type) {
599
- this.loadingTasks$.next(true);
600
- this.activeTab$.next(type);
601
- let params;
602
- this.closeTranslationSubscription();
603
- this._translationSubscription = combineLatest([
604
- this.translateService.stream(`task-list.${type}.title`),
605
- this.translateService.stream(`task-list.${type}.description`),
606
- ]).subscribe(([title, description]) => {
607
- this.listTitle = title;
608
- this.listDescription = description;
609
- });
610
- switch (type) {
611
- case 'mine':
612
- params = {
613
- page: this.tasks.mine.page,
614
- size: this.tasks.mine.pagination.size,
615
- filter: 'mine',
616
- };
617
- this.currentTaskType = 'mine';
618
- break;
619
- case 'open':
620
- params = {
621
- page: this.tasks.open.page,
622
- size: this.tasks.open.pagination.size,
623
- filter: 'open',
624
- };
625
- this.currentTaskType = 'open';
626
- break;
627
- case 'all':
628
- params = { page: this.tasks.all.page, size: this.tasks.open.pagination.size, filter: 'all' };
629
- this.currentTaskType = 'all';
630
- break;
631
- default:
632
- this.logger.fatal('Unreachable case');
633
- }
634
- if (this.sortState) {
635
- params.sort = this.getSortString(this.sortState);
636
- }
637
- this.taskService
638
- .queryTasks(params)
639
- .pipe(switchMap(tasksResult => combineLatest([
640
- of(tasksResult),
641
- forkJoin(tasksResult.body.map(task => this.permissionService
642
- .requestPermission(CAN_VIEW_TASK_PERMISSION, {
643
- resource: TASK_DETAIL_PERMISSION_RESOURCE.task,
644
- identifier: task.id,
645
- })
646
- .pipe(take$1(1)))).pipe(defaultIfEmpty(null)),
647
- forkJoin(tasksResult.body.map(task => this.permissionService
648
- .requestPermission(CAN_VIEW_CASE_PERMISSION, {
649
- resource: TASK_DETAIL_PERMISSION_RESOURCE.jsonSchemaDocument,
650
- identifier: task.businessKey,
651
- })
652
- .pipe(take$1(1)))).pipe(defaultIfEmpty(null)),
653
- ])))
654
- .subscribe(([tasksResult, taskPermissions, taskCasePermissions]) => {
655
- this.tasks[type].pagination = {
656
- ...this.tasks[type].pagination,
657
- collectionSize: tasksResult.headers.get('x-total-count'),
658
- };
659
- this.tasks[type].tasks = tasksResult.body;
660
- this.tasks[type].tasks.map((task, taskIndex) => {
661
- task.created = moment(task.created).format('DD MMM YYYY HH:mm');
662
- if (task.due) {
663
- task.due = moment(task.due).format('DD MMM YYYY HH:mm');
664
- }
665
- task.locked = !taskPermissions[taskIndex];
666
- task.caseLocked = !taskCasePermissions[taskIndex];
667
- });
668
- if (this.taskService.getConfigCustomTaskList()) {
669
- this.customTaskListFields(type);
1041
+ this.taskListService.selectedTaskType$.pipe(take(1)).subscribe(selectedTaskType => {
1042
+ if (selectedTaskType !== tab) {
1043
+ this.enableLoadingAnimation();
1044
+ this.taskListService.setSelectedTaskType(tab);
1045
+ this.taskListPaginationService.updateTaskPagination(tab, { page: 0 });
670
1046
  }
671
- else {
672
- this.defaultTaskListFields(type);
673
- }
674
- this.loadingTasks$.next(false);
675
1047
  });
676
1048
  }
677
1049
  openRelatedCase(event, index) {
678
1050
  event.stopPropagation();
679
- const tasks = this.tasks[this.currentTaskType].tasks;
680
- const currentTask = tasks && tasks[index];
681
- if (currentTask && !currentTask.caseLocked) {
682
- this.documentService
683
- .getDocument(currentTask.businessKey)
684
- .pipe(take$1(1))
685
- .subscribe(document => {
686
- this.router.navigate([
687
- `/dossiers/${document.definitionId?.name}/document/${currentTask.businessKey}`,
688
- ]);
689
- });
1051
+ this.cachedTasks$.pipe(take(1)).subscribe(cachedTasks => {
1052
+ const currentTask = cachedTasks && cachedTasks[index];
1053
+ if (currentTask && !currentTask.caseLocked) {
1054
+ this.documentService
1055
+ .getDocument(currentTask.businessKey)
1056
+ .pipe(take(1))
1057
+ .subscribe(document => {
1058
+ this.router.navigate([
1059
+ `/dossiers/${document.definitionId?.name}/document/${currentTask.businessKey}`,
1060
+ ]);
1061
+ });
1062
+ }
1063
+ });
1064
+ }
1065
+ rowOpenTaskClick(task) {
1066
+ return !task.endTime && !task.locked ? this._taskDetail.openTaskDetails(task) : false;
1067
+ }
1068
+ sortChanged(sortState) {
1069
+ this.taskListSortService.updateSortState(this.taskListService.selectedTaskType, sortState);
1070
+ }
1071
+ setCaseDefinition(definition) {
1072
+ if (definition.item.id) {
1073
+ this.loadingTasks$.next(true);
1074
+ this.taskListService.setCaseDefinitionName(definition.item.id);
690
1075
  }
691
1076
  }
692
- defaultTaskListFields(type) {
693
- this.closeTranslationSubscription();
694
- this._translationSubscription = combineLatest([
695
- this.translateService.stream(`task-list.fieldLabels.created`),
696
- this.translateService.stream(`task-list.fieldLabels.name`),
697
- this.translateService.stream(`task-list.fieldLabels.valtimoAssignee.fullName`),
698
- this.translateService.stream(`task-list.fieldLabels.due`),
699
- this.translateService.stream(`task-list.fieldLabels.context`),
700
- ]).subscribe(([created, name, assignee, due, context]) => {
701
- this.tasks[type].fields = [
702
- {
703
- key: 'created',
704
- label: created,
705
- },
706
- {
707
- key: 'name',
708
- label: name,
709
- },
710
- {
711
- key: 'valtimoAssignee.fullName',
712
- label: assignee,
713
- },
714
- {
715
- key: 'due',
716
- label: due,
717
- },
718
- {
719
- key: 'context',
720
- label: context,
721
- },
722
- ];
723
- });
1077
+ reload() {
1078
+ this.enableLoadingAnimation();
1079
+ this._reload$.next(!this._reload$.getValue());
724
1080
  }
725
- customTaskListFields(type) {
726
- const customTaskListFields = this.taskService.getConfigCustomTaskList().fields;
727
- this.closeTranslationSubscription();
728
- this._translationSubscription = combineLatest(customTaskListFields.map(column => this.translateService.stream(`task-list.fieldLabels.${column.translationKey}`))).subscribe(labels => {
729
- this.tasks[type].fields = customTaskListFields.map((column, index) => ({
730
- key: column.propertyName,
731
- label: labels[index],
732
- sortable: column.sortable,
733
- ...(column.viewType && { viewType: column.viewType }),
734
- ...(column.enum && { enum: column.enum }),
735
- }));
1081
+ updateTaskListPaginationAfterResponse(newCollectionSize) {
1082
+ this.taskListPaginationService.paginationForCurrentTaskType$
1083
+ .pipe(take(1))
1084
+ .subscribe(currentPagination => {
1085
+ this.taskListPaginationService.updateTaskPagination(this.taskListService.selectedTaskType, {
1086
+ collectionSize: Number(newCollectionSize),
1087
+ page: this.taskListPaginationService.getLastAvailablePage(currentPagination.page, currentPagination.size, newCollectionSize),
1088
+ });
736
1089
  });
737
1090
  }
738
- rowOpenTaskClick(task) {
739
- if (!task.endTime && !task.locked) {
740
- this.taskDetail.openTaskDetails(task);
1091
+ setVisibleTabs() {
1092
+ const visibleTabs = this.configService.config?.visibleTaskListTabs;
1093
+ if (visibleTabs) {
1094
+ this.visibleTabs$.next(visibleTabs);
1095
+ this.taskListService.setSelectedTaskType(visibleTabs[0]);
741
1096
  }
742
1097
  else {
743
- return false;
1098
+ this.visibleTabs$.next(this._DEFAULT_TASK_LIST_TABS);
1099
+ this.taskListService.setSelectedTaskType(this._DEFAULT_TASK_LIST_TABS[0]);
744
1100
  }
745
1101
  }
746
- setDefaultSorting() {
747
- this.sortState = this.taskService.getConfigCustomTaskList()?.defaultSortedColumn || null;
1102
+ disableLoadingAnimation() {
1103
+ this._enableLoadingAnimation$.next(false);
748
1104
  }
749
- sortChanged(sortState) {
750
- this.sortState = sortState;
751
- this.getTasks(this.currentTaskType);
1105
+ enableLoadingAnimation() {
1106
+ this._enableLoadingAnimation$.next(true);
752
1107
  }
753
- getSortString(sort) {
754
- return `${sort.state.name},${sort.state.direction}`;
1108
+ getTaskListParams(paginationForSelectedTaskType, sortStringForSelectedTaskType, selectedTaskType, caseDefinitionName, enableLoadingAnimation, reload) {
1109
+ const params = {
1110
+ ...paginationForSelectedTaskType,
1111
+ ...(sortStringForSelectedTaskType && { sort: sortStringForSelectedTaskType }),
1112
+ };
1113
+ delete params.collectionSize;
1114
+ return {
1115
+ params: {
1116
+ reload,
1117
+ selectedTaskType,
1118
+ params,
1119
+ ...(caseDefinitionName &&
1120
+ caseDefinitionName !== this.taskListService.ALL_CASES_ID && { caseDefinitionName }),
1121
+ },
1122
+ enableLoadingAnimation,
1123
+ };
755
1124
  }
756
- clearPagination(type) {
757
- this.tasks[type].page = 0;
1125
+ getTaskListPermissionsRequest(tasksResult, isSpecified) {
1126
+ const taskResults = tasksResult.content;
1127
+ const hasTaskResults = Array.isArray(taskResults) && taskResults.length > 0;
1128
+ return combineLatest([
1129
+ of(isSpecified),
1130
+ of(tasksResult),
1131
+ hasTaskResults
1132
+ ? combineLatest(taskResults.map(task => this.permissionService.requestPermission(CAN_VIEW_TASK_PERMISSION, {
1133
+ resource: TASK_DETAIL_PERMISSION_RESOURCE.task,
1134
+ identifier: !isSpecified ? task.id : task.id,
1135
+ })))
1136
+ : of(null),
1137
+ hasTaskResults
1138
+ ? combineLatest(taskResults.map(task => this.permissionService.requestPermission(CAN_VIEW_CASE_PERMISSION, {
1139
+ resource: TASK_DETAIL_PERMISSION_RESOURCE.jsonSchemaDocument,
1140
+ identifier: task.businessKey,
1141
+ })))
1142
+ : of(null),
1143
+ ]);
758
1144
  }
759
- closeTranslationSubscription() {
760
- this._translationSubscription?.unsubscribe();
1145
+ mapTasksForList(isSpecified, tasks, canViewTaskPermissions, canViewCasePermissions) {
1146
+ const MOMENT_FORMAT = 'DD MMM YYYY HH:mm';
1147
+ if (isSpecified) {
1148
+ return tasks.content.map((specifiedTask, specifiedTaskIndex) => specifiedTask.items.reduce((acc, curr) => ({
1149
+ id: specifiedTask.id,
1150
+ businessKey: specifiedTask.businessKey,
1151
+ processInstanceId: specifiedTask.processInstanceId,
1152
+ name: specifiedTask.name,
1153
+ ...(moment(specifiedTask.created).isValid() && {
1154
+ created: moment(specifiedTask.created).format(MOMENT_FORMAT),
1155
+ }),
1156
+ ...(canViewTaskPermissions && { locked: !canViewTaskPermissions[specifiedTaskIndex] }),
1157
+ ...(canViewCasePermissions && {
1158
+ caseLocked: !canViewCasePermissions[specifiedTaskIndex],
1159
+ }),
1160
+ ...acc,
1161
+ [curr.key]: curr.value,
1162
+ }), {}));
1163
+ }
1164
+ return tasks?.content?.map((task, taskIndex) => {
1165
+ const createdDate = moment(task.created);
1166
+ const dueDate = moment(task.due);
1167
+ const taskCopy = { ...task };
1168
+ if (task.due && dueDate.isValid())
1169
+ taskCopy.due = dueDate.format(MOMENT_FORMAT);
1170
+ if (createdDate.isValid())
1171
+ taskCopy.created = createdDate.format(MOMENT_FORMAT);
1172
+ if (canViewTaskPermissions)
1173
+ taskCopy.locked = !canViewTaskPermissions[taskIndex];
1174
+ if (canViewCasePermissions)
1175
+ taskCopy.caseLocked = !canViewCasePermissions[taskIndex];
1176
+ return taskCopy;
1177
+ });
761
1178
  }
762
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskListComponent, deps: [{ token: i2.ConfigService }, { token: i7.DocumentService }, { token: i3$1.NGXLogger }, { token: i4.PermissionService }, { token: i3.Router }, { token: TaskService }, { token: i8$1.TranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
763
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TaskListComponent, selector: "valtimo-task-list", viewQueries: [{ propertyName: "taskDetail", first: true, predicate: ["taskDetail"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n class=\"main-content\"\n *ngIf=\"{loadingTasks: loadingTasks$ | async, activeTab: activeTab$ | async} as obs\"\n>\n <div class=\"container-fluid\">\n <ng-container\n *ngTemplateOutlet=\"tasksList; context: {show: !obs.loadingTasks, activeTab: obs.activeTab}\"\n ></ng-container>\n\n <ng-container\n *ngTemplateOutlet=\"\n tasksListLoading;\n context: {show: obs.loadingTasks, activeTab: obs.activeTab}\n \"\n ></ng-container>\n\n <valtimo-task-detail-modal\n #taskDetail\n (formSubmit)=\"getTasks(currentTaskType)\"\n (assignmentOfTaskChanged)=\"getTasks(currentTaskType)\"\n ></valtimo-task-detail-modal>\n </div>\n</div>\n\n<ng-template #configuredTabs let-activeTab=\"activeTab\">\n <cds-tabs type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n *ngFor=\"let tab of visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"activeTab === tab\"\n (selected)=\"tabChange(tab)\"\n ></cds-tab>\n </cds-tabs>\n</ng-template>\n\n<ng-template #caseLink let-data=\"data\">\n <div *ngIf=\"tasks[currentTaskType].tasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link--disabled\"\n cdsLink\n href=\"javascript:void(0)\"\n ngbTooltip=\"{{ 'task-list.caseLocked' | translate }}\"\n (click)=\"$event.stopPropagation()\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n <div *ngIf=\"!tasks[currentTaskType].tasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link\"\n cdsLink\n href=\"javascript:void(0)\"\n (click)=\"openRelatedCase($event, data.index)\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n</ng-template>\n\n<ng-template #tasksList let-show=\"show\" let-activeTab=\"activeTab\">\n <valtimo-carbon-list\n [ngClass]=\"{'hide-tasks-list': !show}\"\n [fields]=\"tasks[currentTaskType].fields\"\n [header]=\"false\"\n [items]=\"tasks[currentTaskType].tasks\"\n [lastColumnTemplate]=\"caseLink\"\n [pagination]=\"tasks[currentTaskType].pagination\"\n paginationIdentifier=\"taskList\"\n lockedTooltipTranslationKey=\"task-list.rowLocked\"\n (paginationClicked)=\"paginationClicked($event, currentTaskType)\"\n (paginationSet)=\"paginationSet($event)\"\n (rowClicked)=\"rowOpenTaskClick($event)\"\n (sortChanged)=\"sortChanged($event)\"\n >\n <div tabs>\n <cds-tabs\n *ngIf=\"visibleTabs === null; else configuredTabs; context: {activeTab: activeTab}\"\n type=\"contained\"\n class=\"valtimo-carbon-list__tabs\"\n >\n <cds-tab\n [heading]=\"'task-list.mine.title' | translate\"\n (selected)=\"tabChange('mine')\"\n [active]=\"activeTab === 'mine'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.open.title' | translate\"\n (selected)=\"tabChange('open')\"\n [active]=\"activeTab === 'open'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.all.title' | translate\"\n (selected)=\"tabChange('all')\"\n [active]=\"activeTab === 'all'\"\n >\n </cds-tab>\n </cds-tabs>\n </div>\n\n <valtimo-no-results\n [description]=\"'task-list.' + currentTaskType + '.noResultsDescription' | translate\"\n [title]=\"'task-list.' + currentTaskType + '.noResultsTitle' | translate\"\n >\n </valtimo-no-results>\n </valtimo-carbon-list>\n</ng-template>\n\n<ng-template #tasksListLoading let-show=\"show\" let-activeTab=\"activeTab\">\n <valtimo-carbon-list [ngClass]=\"{'hide-tasks-list': !show}\" [loading]=\"true\">\n <div tabs>\n <cds-tabs *ngIf=\"visibleTabs === null\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab [heading]=\"'task-list.mine.title' | translate\" [active]=\"activeTab === 'mine'\">\n </cds-tab>\n\n <cds-tab [heading]=\"'task-list.open.title' | translate\" [active]=\"activeTab === 'open'\">\n </cds-tab>\n\n <cds-tab [heading]=\"'task-list.all.title' | translate\" [active]=\"activeTab === 'all'\">\n </cds-tab>\n </cds-tabs>\n\n <cds-tabs type=\"contained\" class=\"valtimo-carbon-list__tabs\" *ngIf=\"visibleTabs\">\n <cds-tab\n *ngFor=\"let tab of visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"activeTab === tab\"\n ></cds-tab>\n </cds-tabs>\n </div>\n </valtimo-carbon-list>\n</ng-template>\n", styles: ["/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.hide-tasks-list{display:none}.cds--link--disabled{cursor:not-allowed;pointer-events:auto!important;outline:0!important}\n"], dependencies: [{ kind: "directive", type: i8.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i8.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i6.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "actions", "actionItems", "header", "hideColumnHeader", "initialSortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow"] }, { kind: "component", type: i6.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title"] }, { kind: "directive", type: i10.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "triggers", "container", "disableTooltip", "tooltipClass", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "directive", type: i11.Link, selector: "[cdsLink], [ibmLink]", inputs: ["inline", "disabled"] }, { kind: "component", type: i11.Tabs, selector: "cds-tabs, ibm-tabs", inputs: ["position", "cacheActive", "followFocus", "isNavigation", "ariaLabel", "ariaLabelledby", "type", "theme", "skeleton"] }, { kind: "component", type: i11.Tab, selector: "cds-tab, ibm-tab", inputs: ["heading", "title", "context", "active", "disabled", "tabIndex", "id", "cacheActive"], outputs: ["selected"] }, { kind: "component", type: TaskDetailModalComponent, selector: "valtimo-task-detail-modal", outputs: ["formSubmit", "assignmentOfTaskChanged"] }, { kind: "pipe", type: i8.AsyncPipe, name: "async" }, { kind: "pipe", type: i8$1.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None }); }
1179
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListComponent, deps: [{ token: i2.ConfigService }, { token: i7.DocumentService }, { token: i3$1.PermissionService }, { token: i3.Router }, { token: TaskService }, { token: TaskListService }, { token: i8.TranslateService }, { token: TaskListColumnService }, { token: TaskListPaginationService }, { token: TaskListSortService }], target: i0.ɵɵFactoryTarget.Component }); }
1180
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.3", type: TaskListComponent, selector: "valtimo-task-list", providers: [
1181
+ TaskListService,
1182
+ TaskListColumnService,
1183
+ TaskListPaginationService,
1184
+ TaskListSortService,
1185
+ ], viewQueries: [{ propertyName: "_taskDetail", first: true, predicate: ["taskDetail"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2024 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n loading: loadingTasks$ | async,\n selectedTaskType: selectedTaskType$ | async,\n tasks: tasks$ | async,\n fields: fields$ | async,\n visibleTabs: visibleTabs$ | async,\n pagination: paginationForCurrentTaskTypeForList$ | async,\n taskListColumnsForCase: taskListColumnsForCase$ | async,\n sortState: sortStateForCurrentTaskType$ | async\n } as obs\"\n class=\"main-content\"\n>\n <div class=\"container-fluid\">\n <ng-container\n *ngTemplateOutlet=\"\n tasksList;\n context: {\n obs: obs\n }\n \"\n ></ng-container>\n\n <ng-container\n *ngTemplateOutlet=\"\n tasksListLoading;\n context: {\n obs: obs\n }\n \"\n ></ng-container>\n\n <valtimo-task-detail-modal\n #taskDetail\n (formSubmit)=\"reload()\"\n (assignmentOfTaskChanged)=\"reload()\"\n ></valtimo-task-detail-modal>\n </div>\n</div>\n\n<ng-template #configuredTabs let-selectedTaskType=\"selectedTaskType\" let-visibleTabs=\"visibleTabs\">\n <cds-tabs *ngIf=\"visibleTabs\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n *ngFor=\"let tab of visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"selectedTaskType === tab\"\n (selected)=\"tabChange(tab)\"\n ></cds-tab>\n </cds-tabs>\n</ng-template>\n\n<ng-template #caseLink let-data=\"data\">\n <ng-container *ngIf=\"cachedTasks$ | async as cachedTasks\">\n <div *ngIf=\"cachedTasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link--disabled\"\n cdsLink\n href=\"javascript:void(0)\"\n ngbTooltip=\"{{ 'task-list.caseLocked' | translate }}\"\n (click)=\"$event.stopPropagation()\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n <div *ngIf=\"!cachedTasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link\"\n cdsLink\n href=\"javascript:void(0)\"\n (click)=\"openRelatedCase($event, data.index)\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #tasksList let-obs=\"obs\">\n <valtimo-carbon-list\n *ngIf=\"!obs.loading\"\n [fields]=\"obs.fields\"\n [header]=\"false\"\n [items]=\"obs.tasks\"\n [lastColumnTemplate]=\"caseLink\"\n [pagination]=\"obs.pagination\"\n paginationIdentifier=\"taskList\"\n lockedTooltipTranslationKey=\"task-list.rowLocked\"\n [initialSortState]=\"obs.sortState\"\n (paginationClicked)=\"paginationClicked($event, obs.selectedTaskType)\"\n (paginationSet)=\"paginationSet($event)\"\n (rowClicked)=\"rowOpenTaskClick($event)\"\n (sortChanged)=\"sortChanged($event)\"\n >\n <div tabs>\n <ng-container *ngIf=\"obs.visibleTabs\">\n <ng-container\n *ngTemplateOutlet=\"\n configuredTabs;\n context: {selectedTaskType: obs.selectedTaskType, visibleTabs: obs.visibleTabs}\n \"\n ></ng-container>\n </ng-container>\n </div>\n\n <valtimo-no-results\n [description]=\"'task-list.' + obs.selectedTaskType + '.noResultsDescription' | translate\"\n [title]=\"'task-list.' + obs.selectedTaskType + '.noResultsTitle' | translate\"\n >\n </valtimo-no-results>\n </valtimo-carbon-list>\n</ng-template>\n\n<ng-template #tasksListLoading let-obs=\"obs\">\n <valtimo-carbon-list *ngIf=\"obs.loading\" [loading]=\"true\">\n <div tabs>\n <cds-tabs *ngIf=\"!obs.visibleTabs\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n [heading]=\"'task-list.mine.title' | translate\"\n [active]=\"obs.selectedTaskType === 'mine'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.open.title' | translate\"\n [active]=\"obs.selectedTaskType === 'open'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.all.title' | translate\"\n [active]=\"obs.selectedTaskType === 'all'\"\n >\n </cds-tab>\n </cds-tabs>\n\n <cds-tabs *ngIf=\"obs.visibleTabs\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n *ngFor=\"let tab of obs.visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"obs.selectedTaskType === tab\"\n ></cds-tab>\n </cds-tabs>\n </div>\n </valtimo-carbon-list>\n</ng-template>\n\n<ng-container renderInPageHeader [fullWidth]=\"true\">\n <ng-template>\n <cds-dropdown\n class=\"case-definition-selection\"\n *ngIf=\"{\n loadingCaseListItems: loadingCaseListItems$ | async,\n caseListItems: caseListItems$ | async\n } as obs\"\n [disabled]=\"obs.loadingCaseListItems || (obs.caseListItems || []).length === 1\"\n [skeleton]=\"obs.loadingCaseListItems\"\n (selected)=\"setCaseDefinition($event)\"\n >\n <cds-dropdown-list\n [items]=\"obs.caseListItems || []\"\n ></cds-dropdown-list></cds-dropdown></ng-template\n></ng-container>\n", styles: [".cds--link--disabled{cursor:not-allowed;pointer-events:auto!important;outline:0!important}.case-definition-selection{display:flex;width:250px}\n/*!\n * Copyright 2015-2024 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i9.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i9.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i9.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i6.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "actions", "actionItems", "header", "hideColumnHeader", "initialSortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "component", type: i6.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title"] }, { kind: "directive", type: i11.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "triggers", "container", "disableTooltip", "tooltipClass", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "directive", type: i12.Link, selector: "[cdsLink], [ibmLink]", inputs: ["inline", "disabled"] }, { kind: "component", type: i12.Tabs, selector: "cds-tabs, ibm-tabs", inputs: ["position", "cacheActive", "followFocus", "isNavigation", "ariaLabel", "ariaLabelledby", "type", "theme", "skeleton"] }, { kind: "component", type: i12.Tab, selector: "cds-tab, ibm-tab", inputs: ["heading", "title", "context", "active", "disabled", "tabIndex", "id", "cacheActive"], outputs: ["selected"] }, { kind: "directive", type: i6.RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }, { kind: "component", type: i12.Dropdown, selector: "cds-dropdown, ibm-dropdown", inputs: ["id", "label", "helperText", "placeholder", "displayValue", "clearText", "size", "type", "theme", "disabled", "skeleton", "inline", "disableArrowKeys", "invalid", "invalidText", "warn", "warnText", "appendInline", "scrollableContainer", "itemValueKey", "selectionFeedback", "menuButtonLabel", "selectedLabel", "dropUp"], outputs: ["selected", "onClose", "close"] }, { kind: "component", type: i12.DropdownList, selector: "cds-dropdown-list, ibm-dropdown-list", inputs: ["ariaLabel", "items", "listTpl", "type", "showTitles"], outputs: ["select", "scroll", "blurIntent"] }, { kind: "component", type: TaskDetailModalComponent, selector: "valtimo-task-detail-modal", outputs: ["formSubmit", "assignmentOfTaskChanged"] }, { kind: "pipe", type: i9.AsyncPipe, name: "async" }, { kind: "pipe", type: i8.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
764
1186
  }
765
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskListComponent, decorators: [{
1187
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskListComponent, decorators: [{
766
1188
  type: Component,
767
- args: [{ selector: 'valtimo-task-list', encapsulation: ViewEncapsulation.None, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n class=\"main-content\"\n *ngIf=\"{loadingTasks: loadingTasks$ | async, activeTab: activeTab$ | async} as obs\"\n>\n <div class=\"container-fluid\">\n <ng-container\n *ngTemplateOutlet=\"tasksList; context: {show: !obs.loadingTasks, activeTab: obs.activeTab}\"\n ></ng-container>\n\n <ng-container\n *ngTemplateOutlet=\"\n tasksListLoading;\n context: {show: obs.loadingTasks, activeTab: obs.activeTab}\n \"\n ></ng-container>\n\n <valtimo-task-detail-modal\n #taskDetail\n (formSubmit)=\"getTasks(currentTaskType)\"\n (assignmentOfTaskChanged)=\"getTasks(currentTaskType)\"\n ></valtimo-task-detail-modal>\n </div>\n</div>\n\n<ng-template #configuredTabs let-activeTab=\"activeTab\">\n <cds-tabs type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n *ngFor=\"let tab of visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"activeTab === tab\"\n (selected)=\"tabChange(tab)\"\n ></cds-tab>\n </cds-tabs>\n</ng-template>\n\n<ng-template #caseLink let-data=\"data\">\n <div *ngIf=\"tasks[currentTaskType].tasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link--disabled\"\n cdsLink\n href=\"javascript:void(0)\"\n ngbTooltip=\"{{ 'task-list.caseLocked' | translate }}\"\n (click)=\"$event.stopPropagation()\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n <div *ngIf=\"!tasks[currentTaskType].tasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link\"\n cdsLink\n href=\"javascript:void(0)\"\n (click)=\"openRelatedCase($event, data.index)\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n</ng-template>\n\n<ng-template #tasksList let-show=\"show\" let-activeTab=\"activeTab\">\n <valtimo-carbon-list\n [ngClass]=\"{'hide-tasks-list': !show}\"\n [fields]=\"tasks[currentTaskType].fields\"\n [header]=\"false\"\n [items]=\"tasks[currentTaskType].tasks\"\n [lastColumnTemplate]=\"caseLink\"\n [pagination]=\"tasks[currentTaskType].pagination\"\n paginationIdentifier=\"taskList\"\n lockedTooltipTranslationKey=\"task-list.rowLocked\"\n (paginationClicked)=\"paginationClicked($event, currentTaskType)\"\n (paginationSet)=\"paginationSet($event)\"\n (rowClicked)=\"rowOpenTaskClick($event)\"\n (sortChanged)=\"sortChanged($event)\"\n >\n <div tabs>\n <cds-tabs\n *ngIf=\"visibleTabs === null; else configuredTabs; context: {activeTab: activeTab}\"\n type=\"contained\"\n class=\"valtimo-carbon-list__tabs\"\n >\n <cds-tab\n [heading]=\"'task-list.mine.title' | translate\"\n (selected)=\"tabChange('mine')\"\n [active]=\"activeTab === 'mine'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.open.title' | translate\"\n (selected)=\"tabChange('open')\"\n [active]=\"activeTab === 'open'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.all.title' | translate\"\n (selected)=\"tabChange('all')\"\n [active]=\"activeTab === 'all'\"\n >\n </cds-tab>\n </cds-tabs>\n </div>\n\n <valtimo-no-results\n [description]=\"'task-list.' + currentTaskType + '.noResultsDescription' | translate\"\n [title]=\"'task-list.' + currentTaskType + '.noResultsTitle' | translate\"\n >\n </valtimo-no-results>\n </valtimo-carbon-list>\n</ng-template>\n\n<ng-template #tasksListLoading let-show=\"show\" let-activeTab=\"activeTab\">\n <valtimo-carbon-list [ngClass]=\"{'hide-tasks-list': !show}\" [loading]=\"true\">\n <div tabs>\n <cds-tabs *ngIf=\"visibleTabs === null\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab [heading]=\"'task-list.mine.title' | translate\" [active]=\"activeTab === 'mine'\">\n </cds-tab>\n\n <cds-tab [heading]=\"'task-list.open.title' | translate\" [active]=\"activeTab === 'open'\">\n </cds-tab>\n\n <cds-tab [heading]=\"'task-list.all.title' | translate\" [active]=\"activeTab === 'all'\">\n </cds-tab>\n </cds-tabs>\n\n <cds-tabs type=\"contained\" class=\"valtimo-carbon-list__tabs\" *ngIf=\"visibleTabs\">\n <cds-tab\n *ngFor=\"let tab of visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"activeTab === tab\"\n ></cds-tab>\n </cds-tabs>\n </div>\n </valtimo-carbon-list>\n</ng-template>\n", styles: ["/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.hide-tasks-list{display:none}.cds--link--disabled{cursor:not-allowed;pointer-events:auto!important;outline:0!important}\n"] }]
768
- }], ctorParameters: function () { return [{ type: i2.ConfigService }, { type: i7.DocumentService }, { type: i3$1.NGXLogger }, { type: i4.PermissionService }, { type: i3.Router }, { type: TaskService }, { type: i8$1.TranslateService }]; }, propDecorators: { taskDetail: [{
1189
+ args: [{ selector: 'valtimo-task-list', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
1190
+ TaskListService,
1191
+ TaskListColumnService,
1192
+ TaskListPaginationService,
1193
+ TaskListSortService,
1194
+ ], template: "<!--\n ~ Copyright 2015-2024 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n loading: loadingTasks$ | async,\n selectedTaskType: selectedTaskType$ | async,\n tasks: tasks$ | async,\n fields: fields$ | async,\n visibleTabs: visibleTabs$ | async,\n pagination: paginationForCurrentTaskTypeForList$ | async,\n taskListColumnsForCase: taskListColumnsForCase$ | async,\n sortState: sortStateForCurrentTaskType$ | async\n } as obs\"\n class=\"main-content\"\n>\n <div class=\"container-fluid\">\n <ng-container\n *ngTemplateOutlet=\"\n tasksList;\n context: {\n obs: obs\n }\n \"\n ></ng-container>\n\n <ng-container\n *ngTemplateOutlet=\"\n tasksListLoading;\n context: {\n obs: obs\n }\n \"\n ></ng-container>\n\n <valtimo-task-detail-modal\n #taskDetail\n (formSubmit)=\"reload()\"\n (assignmentOfTaskChanged)=\"reload()\"\n ></valtimo-task-detail-modal>\n </div>\n</div>\n\n<ng-template #configuredTabs let-selectedTaskType=\"selectedTaskType\" let-visibleTabs=\"visibleTabs\">\n <cds-tabs *ngIf=\"visibleTabs\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n *ngFor=\"let tab of visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"selectedTaskType === tab\"\n (selected)=\"tabChange(tab)\"\n ></cds-tab>\n </cds-tabs>\n</ng-template>\n\n<ng-template #caseLink let-data=\"data\">\n <ng-container *ngIf=\"cachedTasks$ | async as cachedTasks\">\n <div *ngIf=\"cachedTasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link--disabled\"\n cdsLink\n href=\"javascript:void(0)\"\n ngbTooltip=\"{{ 'task-list.caseLocked' | translate }}\"\n (click)=\"$event.stopPropagation()\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n <div *ngIf=\"!cachedTasks[data.index].caseLocked\">\n <a\n class=\"float-left cds--link\"\n cdsLink\n href=\"javascript:void(0)\"\n (click)=\"openRelatedCase($event, data.index)\"\n >\n {{ 'task-list.goToCase' | translate }}\n </a>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #tasksList let-obs=\"obs\">\n <valtimo-carbon-list\n *ngIf=\"!obs.loading\"\n [fields]=\"obs.fields\"\n [header]=\"false\"\n [items]=\"obs.tasks\"\n [lastColumnTemplate]=\"caseLink\"\n [pagination]=\"obs.pagination\"\n paginationIdentifier=\"taskList\"\n lockedTooltipTranslationKey=\"task-list.rowLocked\"\n [initialSortState]=\"obs.sortState\"\n (paginationClicked)=\"paginationClicked($event, obs.selectedTaskType)\"\n (paginationSet)=\"paginationSet($event)\"\n (rowClicked)=\"rowOpenTaskClick($event)\"\n (sortChanged)=\"sortChanged($event)\"\n >\n <div tabs>\n <ng-container *ngIf=\"obs.visibleTabs\">\n <ng-container\n *ngTemplateOutlet=\"\n configuredTabs;\n context: {selectedTaskType: obs.selectedTaskType, visibleTabs: obs.visibleTabs}\n \"\n ></ng-container>\n </ng-container>\n </div>\n\n <valtimo-no-results\n [description]=\"'task-list.' + obs.selectedTaskType + '.noResultsDescription' | translate\"\n [title]=\"'task-list.' + obs.selectedTaskType + '.noResultsTitle' | translate\"\n >\n </valtimo-no-results>\n </valtimo-carbon-list>\n</ng-template>\n\n<ng-template #tasksListLoading let-obs=\"obs\">\n <valtimo-carbon-list *ngIf=\"obs.loading\" [loading]=\"true\">\n <div tabs>\n <cds-tabs *ngIf=\"!obs.visibleTabs\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n [heading]=\"'task-list.mine.title' | translate\"\n [active]=\"obs.selectedTaskType === 'mine'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.open.title' | translate\"\n [active]=\"obs.selectedTaskType === 'open'\"\n >\n </cds-tab>\n\n <cds-tab\n [heading]=\"'task-list.all.title' | translate\"\n [active]=\"obs.selectedTaskType === 'all'\"\n >\n </cds-tab>\n </cds-tabs>\n\n <cds-tabs *ngIf=\"obs.visibleTabs\" type=\"contained\" class=\"valtimo-carbon-list__tabs\">\n <cds-tab\n *ngFor=\"let tab of obs.visibleTabs\"\n [heading]=\"'task-list.' + tab + '.title' | translate\"\n [active]=\"obs.selectedTaskType === tab\"\n ></cds-tab>\n </cds-tabs>\n </div>\n </valtimo-carbon-list>\n</ng-template>\n\n<ng-container renderInPageHeader [fullWidth]=\"true\">\n <ng-template>\n <cds-dropdown\n class=\"case-definition-selection\"\n *ngIf=\"{\n loadingCaseListItems: loadingCaseListItems$ | async,\n caseListItems: caseListItems$ | async\n } as obs\"\n [disabled]=\"obs.loadingCaseListItems || (obs.caseListItems || []).length === 1\"\n [skeleton]=\"obs.loadingCaseListItems\"\n (selected)=\"setCaseDefinition($event)\"\n >\n <cds-dropdown-list\n [items]=\"obs.caseListItems || []\"\n ></cds-dropdown-list></cds-dropdown></ng-template\n></ng-container>\n", styles: [".cds--link--disabled{cursor:not-allowed;pointer-events:auto!important;outline:0!important}.case-definition-selection{display:flex;width:250px}\n/*!\n * Copyright 2015-2024 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"] }]
1195
+ }], ctorParameters: () => [{ type: i2.ConfigService }, { type: i7.DocumentService }, { type: i3$1.PermissionService }, { type: i3.Router }, { type: TaskService }, { type: TaskListService }, { type: i8.TranslateService }, { type: TaskListColumnService }, { type: TaskListPaginationService }, { type: TaskListSortService }], propDecorators: { _taskDetail: [{
769
1196
  type: ViewChild,
770
1197
  args: ['taskDetail']
771
1198
  }] } });
772
1199
 
773
1200
  /*
774
- * Copyright 2015-2023 Ritense BV, the Netherlands.
1201
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
775
1202
  *
776
1203
  * Licensed under EUPL, Version 1.2 (the "License");
777
1204
  * you may not use this file except in compliance with the License.
@@ -794,11 +1221,11 @@ const routes = [
794
1221
  },
795
1222
  ];
796
1223
  class TaskRoutingModule {
797
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
798
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: TaskRoutingModule, imports: [CommonModule, i3.RouterModule], exports: [RouterModule] }); }
799
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskRoutingModule, imports: [CommonModule, RouterModule.forChild(routes), RouterModule] }); }
1224
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1225
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.3", ngImport: i0, type: TaskRoutingModule, imports: [CommonModule, i3.RouterModule], exports: [RouterModule] }); }
1226
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskRoutingModule, imports: [CommonModule, RouterModule.forChild(routes), RouterModule] }); }
800
1227
  }
801
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskRoutingModule, decorators: [{
1228
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskRoutingModule, decorators: [{
802
1229
  type: NgModule,
803
1230
  args: [{
804
1231
  declarations: [],
@@ -808,7 +1235,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
808
1235
  }] });
809
1236
 
810
1237
  /*
811
- * Copyright 2015-2023 Ritense BV, the Netherlands.
1238
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
812
1239
  *
813
1240
  * Licensed under EUPL, Version 1.2 (the "License");
814
1241
  * you may not use this file except in compliance with the License.
@@ -823,8 +1250,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
823
1250
  * limitations under the License.
824
1251
  */
825
1252
  class TaskModule {
826
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
827
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: TaskModule, declarations: [TaskListComponent, TaskDetailModalComponent, AssignUserToTaskComponent], imports: [CommonModule,
1253
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1254
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.3", ngImport: i0, type: TaskModule, declarations: [TaskListComponent, TaskDetailModalComponent, AssignUserToTaskComponent], imports: [CommonModule,
828
1255
  TaskRoutingModule,
829
1256
  CarbonListModule,
830
1257
  PageHeaderModule,
@@ -833,14 +1260,16 @@ class TaskModule {
833
1260
  SearchableDropdownSelectModule,
834
1261
  CamundaFormModule,
835
1262
  BrowserAnimationsModule,
836
- FormsModule, i1$1.ToastrModule, i8$1.TranslateModule, NgbModule,
1263
+ FormsModule, i1$1.ToastrModule, i8.TranslateModule, NgbModule,
837
1264
  FormIoModule,
838
1265
  ModalModule,
839
1266
  LinkModule,
840
- FormLinkModule,
1267
+ ProcessLinkModule,
841
1268
  TabsModule,
842
- ContentSwitcherModule], exports: [TaskListComponent, TaskDetailModalComponent, AssignUserToTaskComponent] }); }
843
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskModule, imports: [CommonModule,
1269
+ ContentSwitcherModule,
1270
+ RenderInPageHeaderDirectiveModule,
1271
+ DropdownModule], exports: [TaskListComponent, TaskDetailModalComponent, AssignUserToTaskComponent] }); }
1272
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskModule, imports: [CommonModule,
844
1273
  TaskRoutingModule,
845
1274
  CarbonListModule,
846
1275
  PageHeaderModule,
@@ -865,11 +1294,13 @@ class TaskModule {
865
1294
  FormIoModule,
866
1295
  ModalModule,
867
1296
  LinkModule,
868
- FormLinkModule,
1297
+ ProcessLinkModule,
869
1298
  TabsModule,
870
- ContentSwitcherModule] }); }
1299
+ ContentSwitcherModule,
1300
+ RenderInPageHeaderDirectiveModule,
1301
+ DropdownModule] }); }
871
1302
  }
872
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TaskModule, decorators: [{
1303
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.3", ngImport: i0, type: TaskModule, decorators: [{
873
1304
  type: NgModule,
874
1305
  args: [{
875
1306
  declarations: [TaskListComponent, TaskDetailModalComponent, AssignUserToTaskComponent],
@@ -899,16 +1330,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
899
1330
  FormIoModule,
900
1331
  ModalModule,
901
1332
  LinkModule,
902
- FormLinkModule,
1333
+ ProcessLinkModule,
903
1334
  TabsModule,
904
1335
  ContentSwitcherModule,
1336
+ RenderInPageHeaderDirectiveModule,
1337
+ DropdownModule,
905
1338
  ],
906
1339
  exports: [TaskListComponent, TaskDetailModalComponent, AssignUserToTaskComponent],
907
1340
  }]
908
1341
  }] });
909
1342
 
910
1343
  /*
911
- * Copyright 2015-2023 Ritense BV, the Netherlands.
1344
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
912
1345
  *
913
1346
  * Licensed under EUPL, Version 1.2 (the "License");
914
1347
  * you may not use this file except in compliance with the License.
@@ -930,5 +1363,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
930
1363
  * Generated bundle index. Do not edit.
931
1364
  */
932
1365
 
933
- export { AssignUserToTaskComponent, CAN_ASSIGN_TASK_PERMISSION, CAN_VIEW_CASE_PERMISSION, CAN_VIEW_TASK_PERMISSION, TASK_DETAIL_PERMISSION_RESOURCE, TaskDetailModalComponent, TaskList, TaskListComponent, TaskModule, TaskService };
1366
+ export { AssignUserToTaskComponent, CAN_ASSIGN_TASK_PERMISSION, CAN_VIEW_CASE_PERMISSION, CAN_VIEW_TASK_PERMISSION, TASK_DETAIL_PERMISSION_RESOURCE, TaskDetailModalComponent, TaskListColumnDefaultSort, TaskListComponent, TaskModule, TaskService };
934
1367
  //# sourceMappingURL=valtimo-task.mjs.map