@valtimo/task 13.17.0 → 13.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/valtimo-task.mjs +325 -109
- package/fesm2022/valtimo-task.mjs.map +1 -1
- package/lib/components/assign-user-to-task/assign-user-to-task.component.d.ts +20 -3
- package/lib/components/assign-user-to-task/assign-user-to-task.component.d.ts.map +1 -1
- package/lib/components/set-task-due-date/set-task-due-date.component.d.ts +18 -5
- package/lib/components/set-task-due-date/set-task-due-date.component.d.ts.map +1 -1
- package/lib/components/task-detail-content/task-detail-content.component.d.ts +3 -1
- package/lib/components/task-detail-content/task-detail-content.component.d.ts.map +1 -1
- package/lib/components/task-detail-modal/task-detail-modal.component.d.ts +6 -2
- package/lib/components/task-detail-modal/task-detail-modal.component.d.ts.map +1 -1
- package/lib/components/task-list/task-list.component.d.ts +3 -1
- package/lib/components/task-list/task-list.component.d.ts.map +1 -1
- package/lib/models/task.model.d.ts +3 -0
- package/lib/models/task.model.d.ts.map +1 -1
- package/lib/services/task-list.service.d.ts +1 -0
- package/lib/services/task-list.service.d.ts.map +1 -1
- package/lib/task.module.d.ts +1 -1
- package/lib/task.module.d.ts.map +1 -1
- package/lib/utils/task-enrichment.utils.d.ts +9 -0
- package/lib/utils/task-enrichment.utils.d.ts.map +1 -0
- package/package.json +1 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, EventEmitter, Input, Output, Component, ViewContainerRef, ViewChild, Optional, Inject, ChangeDetectionStrategy, signal, ViewEncapsulation, HostListener, NgModule } from '@angular/core';
|
|
3
3
|
import * as i9 from '@valtimo/components';
|
|
4
|
-
import { ViewType,
|
|
4
|
+
import { ViewType, RemoveClassnamesDirective, FormioOptionsImpl, FormIoModule, ConfirmationModalModule, TooltipModule, runAfterCarbonModalClosed, CarbonListModule, PageHeaderModule, WidgetModule, SpinnerModule, CamundaFormModule, RenderInPageHeaderDirective, SearchFieldsModule, ValtimoCdsModalDirective } from '@valtimo/components';
|
|
5
5
|
import { BehaviorSubject, combineLatest, tap, filter, switchMap, of, map as map$1, catchError, Subject, Subscription, take as take$1, distinctUntilChanged, EMPTY } from 'rxjs';
|
|
6
6
|
import * as i11 from '@angular/common';
|
|
7
7
|
import { CommonModule } from '@angular/common';
|
|
8
|
-
import * as i4 from '@ngx-translate/core';
|
|
8
|
+
import * as i4$1 from '@ngx-translate/core';
|
|
9
9
|
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
|
|
10
|
-
import * as
|
|
11
|
-
import { ButtonModule, ToggletipModule, IconModule, LayerModule,
|
|
12
|
-
import { UserFollow16, RecentlyViewed16, CalendarAdd16, FolderDetailsReference16 } from '@carbon/icons';
|
|
10
|
+
import * as i3 from 'carbon-components-angular';
|
|
11
|
+
import { ButtonModule, ToggletipModule, IconModule, LayerModule, ComboBoxModule, LoadingModule, NotificationModule, ModalModule, DatePickerModule, LinkModule, TabsModule, ContentSwitcherModule, DropdownModule, TooltipModule as TooltipModule$1 } from 'carbon-components-angular';
|
|
12
|
+
import { UserFollow16, UserRole16, Edit16, RecentlyViewed16, CalendarAdd16, FolderDetailsReference16 } from '@carbon/icons';
|
|
13
13
|
import { map, take, filter as filter$1, startWith, distinctUntilChanged as distinctUntilChanged$1, switchMap as switchMap$1, catchError as catchError$1 } from 'rxjs/operators';
|
|
14
14
|
import * as i1 from '@angular/common/http';
|
|
15
15
|
import { HttpParams, HttpHeaders, HttpClient } from '@angular/common/http';
|
|
@@ -18,19 +18,20 @@ import { BaseApiService, TaskListTab, InterceptorSkip, FORM_VIEW_MODEL_TOKEN, RO
|
|
|
18
18
|
import { omit, isEqual } from 'lodash';
|
|
19
19
|
import * as i1$2 from '@angular/router';
|
|
20
20
|
import { RouterModule } from '@angular/router';
|
|
21
|
+
import * as i4 from '@valtimo/security';
|
|
22
|
+
import { AuthGuardService } from '@valtimo/security';
|
|
21
23
|
import * as i14 from 'carbon-components-angular/dropdown';
|
|
22
24
|
import * as i7 from '@valtimo/process-link';
|
|
23
25
|
import { FORM_CUSTOM_COMPONENT_TOKEN, ProcessLinkModule, formSizeToCarbonModalSizeMap } from '@valtimo/process-link';
|
|
24
|
-
import * as i2
|
|
25
|
-
import * as i4$
|
|
26
|
-
import * as i3 from '@valtimo/access-control';
|
|
26
|
+
import * as i2 from '@valtimo/document';
|
|
27
|
+
import * as i4$2 from 'ngx-logger';
|
|
28
|
+
import * as i3$1 from '@valtimo/access-control';
|
|
27
29
|
import moment from 'moment';
|
|
28
30
|
import * as i6 from '@valtimo/sse';
|
|
29
31
|
import * as i12 from '@ng-bootstrap/ng-bootstrap';
|
|
30
32
|
import { NgbModule } from '@ng-bootstrap/ng-bootstrap';
|
|
31
33
|
import { FormsModule } from '@angular/forms';
|
|
32
34
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
33
|
-
import { AuthGuardService } from '@valtimo/security';
|
|
34
35
|
|
|
35
36
|
/*
|
|
36
37
|
* Copyright 2015-2025 Ritense BV, the Netherlands.
|
|
@@ -157,6 +158,9 @@ class TaskListService {
|
|
|
157
158
|
get selectedTaskType$() {
|
|
158
159
|
return this._selectedTaskType$.asObservable();
|
|
159
160
|
}
|
|
161
|
+
get caseDefinitionKey() {
|
|
162
|
+
return this._caseDefinitionKey$.getValue();
|
|
163
|
+
}
|
|
160
164
|
get selectedTaskType() {
|
|
161
165
|
return this._selectedTaskType$.getValue();
|
|
162
166
|
}
|
|
@@ -770,7 +774,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
770
774
|
*/
|
|
771
775
|
|
|
772
776
|
/*
|
|
773
|
-
* Copyright 2015-
|
|
777
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
774
778
|
*
|
|
775
779
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
776
780
|
* you may not use this file except in compliance with the License.
|
|
@@ -795,12 +799,13 @@ class AssignUserToTaskComponent {
|
|
|
795
799
|
this.canAssignUserToTaskSet$.next(true);
|
|
796
800
|
this.canAssignUserToTask$.next(value);
|
|
797
801
|
}
|
|
798
|
-
constructor(taskService, iconService, elementRef, renderer2,
|
|
802
|
+
constructor(taskService, cdsThemeService, iconService, elementRef, renderer2, userProviderService) {
|
|
799
803
|
this.taskService = taskService;
|
|
804
|
+
this.cdsThemeService = cdsThemeService;
|
|
800
805
|
this.iconService = iconService;
|
|
801
806
|
this.elementRef = elementRef;
|
|
802
807
|
this.renderer2 = renderer2;
|
|
803
|
-
this.
|
|
808
|
+
this.userProviderService = userProviderService;
|
|
804
809
|
this.assignmentOfTaskChanged = new EventEmitter();
|
|
805
810
|
this.canAssignUserToTaskSet$ = new BehaviorSubject(false);
|
|
806
811
|
this.canAssignUserToTask$ = new BehaviorSubject(false);
|
|
@@ -810,16 +815,21 @@ class AssignUserToTaskComponent {
|
|
|
810
815
|
this._candidateUsersForTask$ = new BehaviorSubject(undefined);
|
|
811
816
|
this._selectedUserId$ = new BehaviorSubject(null);
|
|
812
817
|
this.selectedUserId$ = this._selectedUserId$.asObservable();
|
|
813
|
-
this.candidateUsersForTask$ =
|
|
818
|
+
this.candidateUsersForTask$ = this._candidateUsersForTask$.pipe(map(users => this.mapUsersForDropdown(users)));
|
|
819
|
+
this.editCandidateUsersForTask$ = combineLatest([
|
|
814
820
|
this._candidateUsersForTask$,
|
|
815
|
-
this.
|
|
816
|
-
]).pipe(map(([users,
|
|
821
|
+
this.assignedIdOnServer$,
|
|
822
|
+
]).pipe(map(([users, assignedId]) => this.mapUsersForDropdown(users, assignedId)));
|
|
823
|
+
this.toggletipView$ = new BehaviorSubject('choice');
|
|
824
|
+
this.editToggletipOpen$ = new BehaviorSubject(false);
|
|
817
825
|
this.mouseIsOverAssignee$ = new BehaviorSubject(false);
|
|
826
|
+
this.showComboBox$ = new BehaviorSubject(true);
|
|
818
827
|
this.open$ = new Subject();
|
|
819
828
|
this.disabled$ = new BehaviorSubject(true);
|
|
820
|
-
this.toggletipTheme$ = this.cdsThemeService.
|
|
829
|
+
this.toggletipTheme$ = this.cdsThemeService.toggletipTheme$;
|
|
830
|
+
this.toggletipDropdownTheme$ = this.cdsThemeService.toggletipDropdownTheme$;
|
|
821
831
|
this._subscriptions = new Subscription();
|
|
822
|
-
this.iconService.registerAll([UserFollow16]);
|
|
832
|
+
this.iconService.registerAll([UserFollow16, UserRole16, Edit16]);
|
|
823
833
|
}
|
|
824
834
|
ngOnInit() {
|
|
825
835
|
this.openHideElementSubscription();
|
|
@@ -827,8 +837,11 @@ class AssignUserToTaskComponent {
|
|
|
827
837
|
ngOnChanges(changes) {
|
|
828
838
|
this._candidateUsersForTask$.pipe(take$1(1)).subscribe(candidateUsers => {
|
|
829
839
|
const currentUserId = changes.assigneeId?.currentValue || this.assigneeId;
|
|
830
|
-
|
|
831
|
-
|
|
840
|
+
const resolvedId = candidateUsers?.length
|
|
841
|
+
? this.resolveUserId(candidateUsers, currentUserId)
|
|
842
|
+
: currentUserId;
|
|
843
|
+
this.assignedIdOnServer$.next(resolvedId || null);
|
|
844
|
+
this._selectedUserId$.next(resolvedId || null);
|
|
832
845
|
this._assignedUserFullName$.next(this.getAssignedUserName(candidateUsers ?? [], currentUserId));
|
|
833
846
|
});
|
|
834
847
|
}
|
|
@@ -861,15 +874,16 @@ class AssignUserToTaskComponent {
|
|
|
861
874
|
this.taskService
|
|
862
875
|
.unassignTask(this._taskId)
|
|
863
876
|
.pipe(tap(() => {
|
|
877
|
+
this.closeToggletip();
|
|
864
878
|
this.emitChange();
|
|
865
879
|
this.enable();
|
|
866
|
-
this.
|
|
880
|
+
this.resetState();
|
|
867
881
|
}))
|
|
868
882
|
.subscribe();
|
|
869
883
|
}
|
|
870
884
|
getAssignedUserName(users, userId) {
|
|
871
885
|
if (users && userId) {
|
|
872
|
-
const findUser =
|
|
886
|
+
const findUser = this.findUserByIdOrUsername(users, userId);
|
|
873
887
|
return findUser ? findUser.label : userId;
|
|
874
888
|
}
|
|
875
889
|
return userId || '-';
|
|
@@ -888,16 +902,80 @@ class AssignUserToTaskComponent {
|
|
|
888
902
|
return;
|
|
889
903
|
this._selectedUserId$.next(event.id);
|
|
890
904
|
}
|
|
891
|
-
|
|
905
|
+
onComboBoxClear() {
|
|
906
|
+
this._selectedUserId$.next(null);
|
|
907
|
+
}
|
|
908
|
+
onAssignToMe() {
|
|
909
|
+
this.userProviderService
|
|
910
|
+
.getUserSubject()
|
|
911
|
+
.pipe(take$1(1))
|
|
912
|
+
.subscribe((currentUser) => {
|
|
913
|
+
if (currentUser?.id) {
|
|
914
|
+
this.assignTask(currentUser.id);
|
|
915
|
+
}
|
|
916
|
+
});
|
|
917
|
+
}
|
|
918
|
+
onAssignToOtherUser() {
|
|
919
|
+
this.toggletipView$.next('dropdown');
|
|
920
|
+
this._selectedUserId$.next(null);
|
|
921
|
+
}
|
|
922
|
+
onOpenAssignToggletip() {
|
|
923
|
+
this.toggletipView$.next('choice');
|
|
924
|
+
this._selectedUserId$.next(null);
|
|
925
|
+
}
|
|
926
|
+
onOpenEditToggletip() {
|
|
927
|
+
this.editToggletipOpen$.next(true);
|
|
928
|
+
this._selectedUserId$.next(null);
|
|
929
|
+
this.resetComboBox();
|
|
930
|
+
}
|
|
931
|
+
onCloseEditToggletip() {
|
|
932
|
+
this.editToggletipOpen$.next(false);
|
|
933
|
+
}
|
|
934
|
+
resetState() {
|
|
892
935
|
this.assignedIdOnServer$.next(null);
|
|
893
936
|
this._selectedUserId$.next(null);
|
|
937
|
+
this._assignedUserFullName$.next(null);
|
|
938
|
+
this.toggletipView$.next('choice');
|
|
939
|
+
}
|
|
940
|
+
findUserByIdOrUsername(users, identifier) {
|
|
941
|
+
return (users.find(user => user.id === identifier) || users.find(user => user.userName === identifier));
|
|
942
|
+
}
|
|
943
|
+
resolveUserId(users, identifier) {
|
|
944
|
+
const user = this.findUserByIdOrUsername(users, identifier);
|
|
945
|
+
return user ? user.id : identifier;
|
|
894
946
|
}
|
|
895
947
|
mapUsersForDropdown(users, selectedUserId) {
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
948
|
+
if (!users)
|
|
949
|
+
return [];
|
|
950
|
+
return this.sortUsersWithCurrentUserFirst(users).map(user => ({
|
|
951
|
+
content: user.label,
|
|
952
|
+
id: user.id,
|
|
953
|
+
selected: selectedUserId ? user.id === selectedUserId : false,
|
|
954
|
+
}));
|
|
955
|
+
}
|
|
956
|
+
sortUsersWithCurrentUserFirst(users) {
|
|
957
|
+
let currentUserId = null;
|
|
958
|
+
this.userProviderService
|
|
959
|
+
.getUserSubject()
|
|
960
|
+
.pipe(take$1(1))
|
|
961
|
+
.subscribe((user) => {
|
|
962
|
+
currentUserId = user?.id || null;
|
|
963
|
+
});
|
|
964
|
+
return users
|
|
965
|
+
.map(user => ({ ...user, lastName: user.lastName?.split(' ').splice(-1)[0] || '' }))
|
|
966
|
+
.sort((a, b) => {
|
|
967
|
+
if (currentUserId) {
|
|
968
|
+
if (a.id === currentUserId)
|
|
969
|
+
return -1;
|
|
970
|
+
if (b.id === currentUserId)
|
|
971
|
+
return 1;
|
|
972
|
+
}
|
|
973
|
+
return a.lastName.localeCompare(b.lastName);
|
|
974
|
+
});
|
|
975
|
+
}
|
|
976
|
+
resetComboBox() {
|
|
977
|
+
this.showComboBox$.next(false);
|
|
978
|
+
setTimeout(() => this.showComboBox$.next(true));
|
|
901
979
|
}
|
|
902
980
|
emitChange() {
|
|
903
981
|
this.assignmentOfTaskChanged.emit();
|
|
@@ -909,7 +987,7 @@ class AssignUserToTaskComponent {
|
|
|
909
987
|
this.disabled$.next(true);
|
|
910
988
|
}
|
|
911
989
|
closeToggletip() {
|
|
912
|
-
|
|
990
|
+
this.editToggletipOpen$.next(false);
|
|
913
991
|
this.open$.next(true);
|
|
914
992
|
setTimeout(() => this.open$.next(false));
|
|
915
993
|
}
|
|
@@ -921,8 +999,9 @@ class AssignUserToTaskComponent {
|
|
|
921
999
|
this.taskService.getCandidateUsers(taskId).subscribe(candidateUsers => {
|
|
922
1000
|
this._candidateUsersForTask$.next(candidateUsers);
|
|
923
1001
|
if (this.assigneeId) {
|
|
924
|
-
this.
|
|
925
|
-
this.
|
|
1002
|
+
const resolvedId = this.resolveUserId(candidateUsers, this.assigneeId);
|
|
1003
|
+
this.assignedIdOnServer$.next(resolvedId);
|
|
1004
|
+
this._selectedUserId$.next(resolvedId);
|
|
926
1005
|
this._assignedUserFullName$.next(this.getAssignedUserName(candidateUsers, this.assigneeId));
|
|
927
1006
|
}
|
|
928
1007
|
this.enable();
|
|
@@ -930,12 +1009,8 @@ class AssignUserToTaskComponent {
|
|
|
930
1009
|
});
|
|
931
1010
|
}
|
|
932
1011
|
openHideElementSubscription() {
|
|
933
|
-
this._subscriptions.add(combineLatest([
|
|
934
|
-
|
|
935
|
-
this.assignedIdOnServer$,
|
|
936
|
-
this.canAssignUserToTask$,
|
|
937
|
-
]).subscribe(([selectedUserId, idOnServer, canAssignUserToTask]) => {
|
|
938
|
-
if (!canAssignUserToTask && !(selectedUserId === idOnServer && idOnServer !== null)) {
|
|
1012
|
+
this._subscriptions.add(combineLatest([this.assignedIdOnServer$, this.canAssignUserToTask$]).subscribe(([idOnServer, canAssignUserToTask]) => {
|
|
1013
|
+
if (!canAssignUserToTask && idOnServer === null) {
|
|
939
1014
|
this.renderer2.setStyle(this.elementRef.nativeElement, 'display', 'none');
|
|
940
1015
|
}
|
|
941
1016
|
else {
|
|
@@ -943,24 +1018,22 @@ class AssignUserToTaskComponent {
|
|
|
943
1018
|
}
|
|
944
1019
|
}));
|
|
945
1020
|
}
|
|
946
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: AssignUserToTaskComponent, deps: [{ token: TaskService }, { token:
|
|
947
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: AssignUserToTaskComponent, isStandalone: true, selector: "valtimo-assign-user-to-task", inputs: { taskId: "taskId", assigneeId: "assigneeId", canAssignUserToTask: "canAssignUserToTask" }, outputs: { assignmentOfTaskChanged: "assignmentOfTaskChanged" }, usesOnChanges: true, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"\n (canAssignUserToTaskSet$ | async) && {\n candidateUsers: candidateUsersForTask$ | async,\n disabled: disabled$ | async,\n idOnServer: assignedIdOnServer$ | async,\n mouseIsOverAssignee: mouseIsOverAssignee$ | async,\n assignedUserFullName: assignedUserFullName$ | async,\n selectedUserId: selectedUserId$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n } as obs\n \"\n>\n <ng-container\n *ngIf=\"{hasSelection: obs.selectedUserId === obs.idOnServer && obs.idOnServer !== null} as vars\"\n >\n <div\n class=\"assign-user-container\"\n *ngIf=\"obs.canAssignUserToTask || (!obs.canAssignUserToTask && vars.hasSelection)\"\n (mouseenter)=\"onMouseEnterAssignee()\"\n (mouseleave)=\"onMouseLeaveAssignee()\"\n >\n <div\n class=\"assignee-text element\"\n [ngClass]=\"{\n active: obs.canAssignUserToTask\n ? vars.hasSelection && !obs.mouseIsOverAssignee\n : vars.hasSelection,\n }\"\n >\n <span class=\"bold\">{{ 'assignTask.assignedTo' | translate }}</span>\n\n \n\n <span class=\"name\">{{ obs.assignedUserFullName }}</span>\n </div>\n\n <button\n *ngIf=\"obs.canAssignUserToTask\"\n cdsButton=\"ghost\"\n class=\"element remove-button\"\n [ngClass]=\"{active: vars.hasSelection && obs.mouseIsOverAssignee}\"\n [disabled]=\"obs.disabled\"\n size=\"sm\"\n (click)=\"unassignTask()\"\n >\n {{ 'assignTask.remove' | translate }}\n </button>\n\n <cds-toggletip\n align=\"bottom\"\n class=\"element main\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: !vars.hasSelection}\"\n (onOpen)=\"clear()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"tertiary\"\n size=\"sm\"\n class=\"set-assignee-button\"\n >\n {{ 'assignTask.buttonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n\n <div\n cdsToggletipContent\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"assign-task-popover-content\"\n >\n <cds-combo-box\n *ngIf=\"!vars.hasSelection\"\n [label]=\"'assignTask.comboboxLabel' | translate\"\n [placeholder]=\"'assignTask.placeholder' | translate\"\n [appendInline]=\"true\"\n [dropUp]=\"false\"\n [cdsLayer]=\"1\"\n [items]=\"obs?.candidateUsers || []\"\n [disabled]=\"obs.disabled\"\n (selected)=\"onUserSelect($event)\"\n (clear)=\"clear()\"\n >\n <cds-dropdown-list onclick=\"event.stopPropagation()\"></cds-dropdown-list>\n </cds-combo-box>\n\n <button\n cdsButton\n class=\"submit-task-button\"\n [disabled]=\"!obs.selectedUserId || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'assignTask.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n </div>\n </cds-toggletip>\n </div>\n </ng-container>\n</ng-container>\n", styles: [":host ::ng-deep .cds--popover-content{max-inline-size:unset}.assign-user-container{display:flex;align-items:center;justify-content:center;position:relative;font-weight:400;font-size:14px;line-height:18px;letter-spacing:.16px;color:var(--cds-link-01)}.assign-user-container .bold{font-weight:700;flex-shrink:0}.assign-user-container .name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.remove-button{width:100%}.assignee-text{display:flex;justify-content:flex-start;align-items:center;width:100%}.element{opacity:0;visibility:hidden;position:absolute;transition:opacity .3s ease-in-out}.element.active{opacity:1;visibility:visible}.element.main{position:relative}.assign-task-popover-content{width:400px;max-inline-size:400px;display:flex;flex-direction:column;gap:16px}.assign-task-popover-content .cds--btn{width:100%;max-width:unset}.set-assignee-button{width:250px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i11.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: SearchableDropdownSelectModule }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i2.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: ToggletipModule }, { kind: "component", type: i2.Toggletip, selector: "cds-toggletip, ibm-toggletip", inputs: ["id", "isOpen"] }, { kind: "directive", type: i2.ToggletipButton, selector: "[cdsToggletipButton], [ibmToggletipButton]", inputs: ["ariaLabel"] }, { kind: "directive", type: i2.ToggletipContent, selector: "[cdsToggletipContent], [ibmToggletipContent]" }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i2.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "ngmodule", type: LayerModule }, { kind: "directive", type: i2.LayerDirective, selector: "[cdsLayer], [ibmLayer]", inputs: ["ibmLayer", "cdsLayer"], exportAs: ["layer"] }, { kind: "ngmodule", type: DatePickerModule }, { kind: "ngmodule", type: ComboBoxModule }, { kind: "component", type: i2.ComboBox, selector: "cds-combo-box, ibm-combo-box", inputs: ["placeholder", "openMenuAria", "closeMenuAria", "clearSelectionsTitle", "clearSelectionsAria", "clearSelectionTitle", "clearSelectionAria", "id", "labelId", "items", "type", "size", "itemValueKey", "label", "hideLabel", "helperText", "appendInline", "invalid", "invalidText", "warn", "warnText", "maxLength", "theme", "selectionFeedback", "autocomplete", "dropUp", "disabled", "readonly", "fluid"], outputs: ["selected", "submit", "close", "search", "clear"] }, { kind: "component", type: i14.DropdownList, selector: "cds-dropdown-list, ibm-dropdown-list", inputs: ["ariaLabel", "items", "listTpl", "type", "showTitles"], outputs: ["select", "scroll", "blurIntent"] }, { kind: "directive", type: RemoveClassnamesDirective, selector: "[removeClassnames]", inputs: ["removeClassnames"] }] }); }
|
|
1021
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: AssignUserToTaskComponent, deps: [{ token: TaskService }, { token: i9.CdsThemeService }, { token: i3.IconService }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i4.UserProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1022
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: AssignUserToTaskComponent, isStandalone: true, selector: "valtimo-assign-user-to-task", inputs: { taskId: "taskId", assigneeId: "assigneeId", canAssignUserToTask: "canAssignUserToTask" }, outputs: { assignmentOfTaskChanged: "assignmentOfTaskChanged" }, usesOnChanges: true, ngImport: i0, template: "<!--\n ~ Copyright 2015-2026 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 (canAssignUserToTaskSet$ | async) && {\n candidateUsers: candidateUsersForTask$ | async,\n editCandidateUsers: editCandidateUsersForTask$ | async,\n disabled: disabled$ | async,\n idOnServer: assignedIdOnServer$ | async,\n mouseIsOverAssignee: mouseIsOverAssignee$ | async,\n assignedUserFullName: assignedUserFullName$ | async,\n selectedUserId: selectedUserId$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n toggletipView: toggletipView$ | async,\n showComboBox: showComboBox$ | async,\n editToggletipOpen: editToggletipOpen$ | async,\n } as obs\n \"\n>\n <ng-container *ngIf=\"{isAssigned: obs.idOnServer !== null} as vars\">\n <div\n class=\"assign-user-container\"\n *ngIf=\"obs.canAssignUserToTask || (!obs.canAssignUserToTask && vars.isAssigned)\"\n (mouseenter)=\"onMouseEnterAssignee()\"\n (mouseleave)=\"onMouseLeaveAssignee()\"\n >\n <div\n class=\"assignee-text element\"\n [ngClass]=\"{\n active: obs.canAssignUserToTask\n ? vars.isAssigned && !obs.mouseIsOverAssignee && !obs.editToggletipOpen\n : vars.isAssigned,\n }\"\n >\n <span class=\"bold\">{{ 'assignTask.assignedTo' | translate }}</span>\n \n <span class=\"name\">{{ obs.assignedUserFullName }}</span>\n </div>\n\n <cds-toggletip\n *ngIf=\"obs.canAssignUserToTask\"\n align=\"bottom\"\n class=\"element\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: vars.isAssigned && (obs.mouseIsOverAssignee || obs.editToggletipOpen)}\"\n (onOpen)=\"onOpenEditToggletip()\"\n (onClose)=\"onCloseEditToggletip()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"ghost\"\n size=\"sm\"\n class=\"click-to-edit-button\"\n >\n {{ 'assignTask.clickToEdit' | translate }}\n </button>\n\n <div cdsToggletipContent class=\"assign-task-popover-content\">\n <cds-combo-box\n *ngIf=\"obs.showComboBox\"\n [attr.data-carbon-theme]=\"toggletipDropdownTheme$ | async\"\n [label]=\"'assignTask.comboboxLabel' | translate\"\n [placeholder]=\"'assignTask.placeholder' | translate\"\n [appendInline]=\"true\"\n [dropUp]=\"false\"\n [cdsLayer]=\"1\"\n [items]=\"obs?.editCandidateUsers || []\"\n [disabled]=\"obs.disabled\"\n itemValueKey=\"id\"\n (selected)=\"onUserSelect($event)\"\n (clear)=\"onComboBoxClear()\"\n >\n <cds-dropdown-list onclick=\"event.stopPropagation()\"></cds-dropdown-list>\n </cds-combo-box>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [cdsLayer]=\"1\"\n class=\"submit-task-button\"\n [disabled]=\"!obs.selectedUserId || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'assignTask.submitButtonText' | translate }}\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n\n <button\n cdsButton=\"danger--tertiary\"\n [cdsLayer]=\"1\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [disabled]=\"obs.disabled\"\n (click)=\"unassignTask()\"\n >\n {{ 'assignTask.remove' | translate }}\n </button>\n </div>\n </cds-toggletip>\n\n <cds-toggletip\n align=\"bottom\"\n class=\"element main\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: !vars.isAssigned}\"\n (onOpen)=\"onOpenAssignToggletip()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"tertiary\"\n size=\"sm\"\n class=\"assign-button\"\n >\n {{ 'assignTask.buttonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n\n <div cdsToggletipContent class=\"assign-task-popover-content\">\n <ng-container *ngIf=\"obs.toggletipView === 'choice'\">\n <button\n cdsButton=\"secondary\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"choice-button\"\n [disabled]=\"obs.disabled\"\n [cdsLayer]=\"1\"\n (click)=\"onAssignToMe()\"\n >\n {{ 'assignTask.assignToMe' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--role\" size=\"16\"></svg>\n </button>\n\n <button\n cdsButton=\"secondary\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"choice-button\"\n [disabled]=\"obs.disabled\"\n [cdsLayer]=\"1\"\n (click)=\"onAssignToOtherUser(); $event.stopPropagation()\"\n >\n {{ 'assignTask.assignToOtherUser' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <ng-container *ngIf=\"obs.toggletipView === 'dropdown'\">\n <cds-combo-box\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [label]=\"'assignTask.comboboxLabel' | translate\"\n [placeholder]=\"'assignTask.placeholder' | translate\"\n [appendInline]=\"true\"\n [dropUp]=\"false\"\n [cdsLayer]=\"1\"\n [items]=\"obs?.candidateUsers || []\"\n [disabled]=\"obs.disabled\"\n (selected)=\"onUserSelect($event)\"\n (clear)=\"onAssignToOtherUser()\"\n >\n <cds-dropdown-list onclick=\"event.stopPropagation()\"></cds-dropdown-list>\n </cds-combo-box>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"submit-task-button\"\n [disabled]=\"!obs.selectedUserId || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'assignTask.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n </ng-container>\n </div>\n </cds-toggletip>\n </div>\n </ng-container>\n</ng-container>\n", styles: [":host ::ng-deep .cds--popover-content{max-inline-size:unset}.assign-user-container{display:flex;align-items:center;justify-content:center;position:relative;font-weight:400;font-size:14px;line-height:18px;letter-spacing:.16px;color:var(--cds-link-01)}.assign-user-container .bold{font-weight:700;flex-shrink:0}.assign-user-container .name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.assignee-text{display:flex;justify-content:flex-start;align-items:center;width:100%}.element{opacity:0;visibility:hidden;position:absolute;width:100%;transition:opacity .3s ease-in-out}.element.active{opacity:1;visibility:visible}.element.main{position:relative;width:auto}.assign-task-popover-content{width:400px;max-inline-size:400px;display:flex;flex-direction:column;gap:16px}.assign-task-popover-content .cds--btn,.choice-button{width:100%;max-width:unset}.assign-button{width:250px}.click-to-edit-button{width:100%}\n/*!\n * Copyright 2015-2026 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i11.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i3.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: ToggletipModule }, { kind: "component", type: i3.Toggletip, selector: "cds-toggletip, ibm-toggletip", inputs: ["id", "isOpen"] }, { kind: "directive", type: i3.ToggletipButton, selector: "[cdsToggletipButton], [ibmToggletipButton]", inputs: ["ariaLabel"] }, { kind: "directive", type: i3.ToggletipContent, selector: "[cdsToggletipContent], [ibmToggletipContent]" }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i3.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "ngmodule", type: LayerModule }, { kind: "directive", type: i3.LayerDirective, selector: "[cdsLayer], [ibmLayer]", inputs: ["ibmLayer", "cdsLayer"], exportAs: ["layer"] }, { kind: "ngmodule", type: ComboBoxModule }, { kind: "component", type: i3.ComboBox, selector: "cds-combo-box, ibm-combo-box", inputs: ["placeholder", "openMenuAria", "closeMenuAria", "clearSelectionsTitle", "clearSelectionsAria", "clearSelectionTitle", "clearSelectionAria", "id", "labelId", "items", "type", "size", "itemValueKey", "label", "hideLabel", "helperText", "appendInline", "invalid", "invalidText", "warn", "warnText", "maxLength", "theme", "selectionFeedback", "autocomplete", "dropUp", "disabled", "readonly", "fluid"], outputs: ["selected", "submit", "close", "search", "clear"] }, { kind: "component", type: i14.DropdownList, selector: "cds-dropdown-list, ibm-dropdown-list", inputs: ["ariaLabel", "items", "listTpl", "type", "showTitles"], outputs: ["select", "scroll", "blurIntent"] }, { kind: "directive", type: RemoveClassnamesDirective, selector: "[removeClassnames]", inputs: ["removeClassnames"] }] }); }
|
|
948
1023
|
}
|
|
949
1024
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: AssignUserToTaskComponent, decorators: [{
|
|
950
1025
|
type: Component,
|
|
951
1026
|
args: [{ selector: 'valtimo-assign-user-to-task', standalone: true, imports: [
|
|
952
1027
|
CommonModule,
|
|
953
1028
|
TranslateModule,
|
|
954
|
-
SearchableDropdownSelectModule,
|
|
955
1029
|
ButtonModule,
|
|
956
1030
|
ToggletipModule,
|
|
957
1031
|
IconModule,
|
|
958
1032
|
LayerModule,
|
|
959
|
-
DatePickerModule,
|
|
960
1033
|
ComboBoxModule,
|
|
961
1034
|
RemoveClassnamesDirective,
|
|
962
|
-
], template: "<!--\n ~ Copyright 2015-
|
|
963
|
-
}], ctorParameters: () => [{ type: TaskService }, { type:
|
|
1035
|
+
], template: "<!--\n ~ Copyright 2015-2026 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 (canAssignUserToTaskSet$ | async) && {\n candidateUsers: candidateUsersForTask$ | async,\n editCandidateUsers: editCandidateUsersForTask$ | async,\n disabled: disabled$ | async,\n idOnServer: assignedIdOnServer$ | async,\n mouseIsOverAssignee: mouseIsOverAssignee$ | async,\n assignedUserFullName: assignedUserFullName$ | async,\n selectedUserId: selectedUserId$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n toggletipView: toggletipView$ | async,\n showComboBox: showComboBox$ | async,\n editToggletipOpen: editToggletipOpen$ | async,\n } as obs\n \"\n>\n <ng-container *ngIf=\"{isAssigned: obs.idOnServer !== null} as vars\">\n <div\n class=\"assign-user-container\"\n *ngIf=\"obs.canAssignUserToTask || (!obs.canAssignUserToTask && vars.isAssigned)\"\n (mouseenter)=\"onMouseEnterAssignee()\"\n (mouseleave)=\"onMouseLeaveAssignee()\"\n >\n <div\n class=\"assignee-text element\"\n [ngClass]=\"{\n active: obs.canAssignUserToTask\n ? vars.isAssigned && !obs.mouseIsOverAssignee && !obs.editToggletipOpen\n : vars.isAssigned,\n }\"\n >\n <span class=\"bold\">{{ 'assignTask.assignedTo' | translate }}</span>\n \n <span class=\"name\">{{ obs.assignedUserFullName }}</span>\n </div>\n\n <cds-toggletip\n *ngIf=\"obs.canAssignUserToTask\"\n align=\"bottom\"\n class=\"element\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: vars.isAssigned && (obs.mouseIsOverAssignee || obs.editToggletipOpen)}\"\n (onOpen)=\"onOpenEditToggletip()\"\n (onClose)=\"onCloseEditToggletip()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"ghost\"\n size=\"sm\"\n class=\"click-to-edit-button\"\n >\n {{ 'assignTask.clickToEdit' | translate }}\n </button>\n\n <div cdsToggletipContent class=\"assign-task-popover-content\">\n <cds-combo-box\n *ngIf=\"obs.showComboBox\"\n [attr.data-carbon-theme]=\"toggletipDropdownTheme$ | async\"\n [label]=\"'assignTask.comboboxLabel' | translate\"\n [placeholder]=\"'assignTask.placeholder' | translate\"\n [appendInline]=\"true\"\n [dropUp]=\"false\"\n [cdsLayer]=\"1\"\n [items]=\"obs?.editCandidateUsers || []\"\n [disabled]=\"obs.disabled\"\n itemValueKey=\"id\"\n (selected)=\"onUserSelect($event)\"\n (clear)=\"onComboBoxClear()\"\n >\n <cds-dropdown-list onclick=\"event.stopPropagation()\"></cds-dropdown-list>\n </cds-combo-box>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [cdsLayer]=\"1\"\n class=\"submit-task-button\"\n [disabled]=\"!obs.selectedUserId || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'assignTask.submitButtonText' | translate }}\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n\n <button\n cdsButton=\"danger--tertiary\"\n [cdsLayer]=\"1\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [disabled]=\"obs.disabled\"\n (click)=\"unassignTask()\"\n >\n {{ 'assignTask.remove' | translate }}\n </button>\n </div>\n </cds-toggletip>\n\n <cds-toggletip\n align=\"bottom\"\n class=\"element main\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: !vars.isAssigned}\"\n (onOpen)=\"onOpenAssignToggletip()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"tertiary\"\n size=\"sm\"\n class=\"assign-button\"\n >\n {{ 'assignTask.buttonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n\n <div cdsToggletipContent class=\"assign-task-popover-content\">\n <ng-container *ngIf=\"obs.toggletipView === 'choice'\">\n <button\n cdsButton=\"secondary\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"choice-button\"\n [disabled]=\"obs.disabled\"\n [cdsLayer]=\"1\"\n (click)=\"onAssignToMe()\"\n >\n {{ 'assignTask.assignToMe' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--role\" size=\"16\"></svg>\n </button>\n\n <button\n cdsButton=\"secondary\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"choice-button\"\n [disabled]=\"obs.disabled\"\n [cdsLayer]=\"1\"\n (click)=\"onAssignToOtherUser(); $event.stopPropagation()\"\n >\n {{ 'assignTask.assignToOtherUser' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <ng-container *ngIf=\"obs.toggletipView === 'dropdown'\">\n <cds-combo-box\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [label]=\"'assignTask.comboboxLabel' | translate\"\n [placeholder]=\"'assignTask.placeholder' | translate\"\n [appendInline]=\"true\"\n [dropUp]=\"false\"\n [cdsLayer]=\"1\"\n [items]=\"obs?.candidateUsers || []\"\n [disabled]=\"obs.disabled\"\n (selected)=\"onUserSelect($event)\"\n (clear)=\"onAssignToOtherUser()\"\n >\n <cds-dropdown-list onclick=\"event.stopPropagation()\"></cds-dropdown-list>\n </cds-combo-box>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"submit-task-button\"\n [disabled]=\"!obs.selectedUserId || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'assignTask.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"user--follow\" size=\"16\"></svg>\n </button>\n </ng-container>\n </div>\n </cds-toggletip>\n </div>\n </ng-container>\n</ng-container>\n", styles: [":host ::ng-deep .cds--popover-content{max-inline-size:unset}.assign-user-container{display:flex;align-items:center;justify-content:center;position:relative;font-weight:400;font-size:14px;line-height:18px;letter-spacing:.16px;color:var(--cds-link-01)}.assign-user-container .bold{font-weight:700;flex-shrink:0}.assign-user-container .name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.assignee-text{display:flex;justify-content:flex-start;align-items:center;width:100%}.element{opacity:0;visibility:hidden;position:absolute;width:100%;transition:opacity .3s ease-in-out}.element.active{opacity:1;visibility:visible}.element.main{position:relative;width:auto}.assign-task-popover-content{width:400px;max-inline-size:400px;display:flex;flex-direction:column;gap:16px}.assign-task-popover-content .cds--btn,.choice-button{width:100%;max-width:unset}.assign-button{width:250px}.click-to-edit-button{width:100%}\n/*!\n * Copyright 2015-2026 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"] }]
|
|
1036
|
+
}], ctorParameters: () => [{ type: TaskService }, { type: i9.CdsThemeService }, { type: i3.IconService }, { type: i0.ElementRef }, { type: i0.Renderer2 }, { type: i4.UserProviderService }], propDecorators: { taskId: [{
|
|
964
1037
|
type: Input
|
|
965
1038
|
}], assigneeId: [{
|
|
966
1039
|
type: Input
|
|
@@ -1013,6 +1086,40 @@ const CAN_MODIFY_TASK_PERMISSION = {
|
|
|
1013
1086
|
resource: TASK_DETAIL_PERMISSION_RESOURCE.task,
|
|
1014
1087
|
};
|
|
1015
1088
|
|
|
1089
|
+
/*
|
|
1090
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
1091
|
+
*
|
|
1092
|
+
* Licensed under EUPL, Version 1.2 (the "License");
|
|
1093
|
+
* you may not use this file except in compliance with the License.
|
|
1094
|
+
* You may obtain a copy of the License at
|
|
1095
|
+
*
|
|
1096
|
+
* https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
|
|
1097
|
+
*
|
|
1098
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1099
|
+
* distributed under the License is distributed on an "AS IS" basis,
|
|
1100
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1101
|
+
* See the License for the specific language governing permissions and
|
|
1102
|
+
* limitations under the License.
|
|
1103
|
+
*/
|
|
1104
|
+
/**
|
|
1105
|
+
* Enriches a task with assignee and due date from a process link result,
|
|
1106
|
+
* only filling in fields that are missing on the task itself.
|
|
1107
|
+
* Returns a new task object if any fields were enriched, or the original task if unchanged.
|
|
1108
|
+
*/
|
|
1109
|
+
function enrichTaskFromProcessLink(task, processLink) {
|
|
1110
|
+
if (!processLink)
|
|
1111
|
+
return task;
|
|
1112
|
+
const needsAssignee = processLink.assignee && !task.assignee;
|
|
1113
|
+
const needsDue = processLink.due && !task.due;
|
|
1114
|
+
if (!needsAssignee && !needsDue)
|
|
1115
|
+
return task;
|
|
1116
|
+
return {
|
|
1117
|
+
...task,
|
|
1118
|
+
...(needsAssignee && { assignee: processLink.assignee }),
|
|
1119
|
+
...(needsDue && { due: processLink.due }),
|
|
1120
|
+
};
|
|
1121
|
+
}
|
|
1122
|
+
|
|
1016
1123
|
/*
|
|
1017
1124
|
* Copyright 2015-2025 Ritense BV, the Netherlands.
|
|
1018
1125
|
*
|
|
@@ -1041,12 +1148,14 @@ class TaskDetailContentComponent {
|
|
|
1041
1148
|
set taskAndProcessLink(value) {
|
|
1042
1149
|
if (!value)
|
|
1043
1150
|
return;
|
|
1044
|
-
|
|
1151
|
+
const task = enrichTaskFromProcessLink(value.task, value.processLinkActivityResult);
|
|
1152
|
+
this.loadTaskDetails(task, value.processLinkActivityResult);
|
|
1045
1153
|
}
|
|
1046
1154
|
set modalClosed(closed) {
|
|
1047
1155
|
// save form flow data on modal closed
|
|
1048
1156
|
if (this.formFlow)
|
|
1049
1157
|
this.formFlow.saveData();
|
|
1158
|
+
this.taskInstanceId$.next(null);
|
|
1050
1159
|
if (closed) {
|
|
1051
1160
|
this.closeModalEvent.emit();
|
|
1052
1161
|
}
|
|
@@ -1074,6 +1183,7 @@ class TaskDetailContentComponent {
|
|
|
1074
1183
|
this.closeModalEvent = new EventEmitter();
|
|
1075
1184
|
this.formSubmit = new EventEmitter();
|
|
1076
1185
|
this.activeChange = new EventEmitter();
|
|
1186
|
+
this.taskUpdated = new EventEmitter();
|
|
1077
1187
|
this.canAssignUserToTask$ = new BehaviorSubject(false);
|
|
1078
1188
|
this.errorMessage$ = new BehaviorSubject(null);
|
|
1079
1189
|
this.formDefinition$ = new BehaviorSubject(null);
|
|
@@ -1224,6 +1334,7 @@ class TaskDetailContentComponent {
|
|
|
1224
1334
|
getTaskProcessLink(taskId) {
|
|
1225
1335
|
this.taskService.getTaskProcessLink(taskId).subscribe({
|
|
1226
1336
|
next: res => {
|
|
1337
|
+
this.updateTaskFromProcessLink(res);
|
|
1227
1338
|
this.setTaskProcessLink(res);
|
|
1228
1339
|
},
|
|
1229
1340
|
error: _ => {
|
|
@@ -1231,6 +1342,16 @@ class TaskDetailContentComponent {
|
|
|
1231
1342
|
},
|
|
1232
1343
|
});
|
|
1233
1344
|
}
|
|
1345
|
+
updateTaskFromProcessLink(processLinkResult) {
|
|
1346
|
+
const currentTask = this.task$.getValue();
|
|
1347
|
+
if (!currentTask)
|
|
1348
|
+
return;
|
|
1349
|
+
const enrichedTask = enrichTaskFromProcessLink(currentTask, processLinkResult);
|
|
1350
|
+
if (enrichedTask !== currentTask) {
|
|
1351
|
+
this.task$.next(enrichedTask);
|
|
1352
|
+
this.taskUpdated.emit(enrichedTask);
|
|
1353
|
+
}
|
|
1354
|
+
}
|
|
1234
1355
|
setTaskProcessLink(processLinkResult) {
|
|
1235
1356
|
if (processLinkResult !== null) {
|
|
1236
1357
|
switch (processLinkResult?.type) {
|
|
@@ -1406,8 +1527,8 @@ class TaskDetailContentComponent {
|
|
|
1406
1527
|
this.stateService.setCaseDefinitionKey(caseDefinitionKey);
|
|
1407
1528
|
});
|
|
1408
1529
|
}
|
|
1409
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailContentComponent, deps: [{ token: i1$1.ConfigService }, { token: i2
|
|
1410
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskDetailContentComponent, isStandalone: true, selector: "valtimo-task-detail-content", inputs: { task: "task", taskAndProcessLink: "taskAndProcessLink", modalClosed: "modalClosed" }, outputs: { closeModalEvent: "closeModalEvent", formSubmit: "formSubmit", activeChange: "activeChange" }, viewQueries: [{ propertyName: "form", first: true, predicate: ["form"], descendants: true }, { propertyName: "formViewModelDynamicContainer", first: true, predicate: ["formViewModelComponent"], descendants: true, read: ViewContainerRef }, { propertyName: "formFlow", first: true, predicate: ["formFlow"], descendants: true }, { propertyName: "formCustomComponentDynamicContainer", first: true, predicate: ["formCustomComponent"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n loading: loading$ | async,\n task: task$ | async,\n taskId: taskInstanceId$ | async,\n formDefinition: formDefinition$ | async,\n formDefinitionId: formDefinitionId$ | async,\n formName: formName$ | async,\n formIoFormData: formIoFormData$ | async,\n submission: submission$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n processLinkIsFormViewModel: processLinkIsFormViewModel$ | async,\n processLinkIsUiComponent: processLinkIsUiComponent$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n noFormNotification: noFormNotification$ | async,\n } as obs\"\n>\n @if (obs.loading) {\n <div style=\"width: 100%; display: flex; justify-content: center; padding: 1rem\">\n <cds-loading size=\"sm\"></cds-loading>\n </div>\n } @else {\n <valtimo-form-io\n #form\n *ngIf=\"\n obs.formDefinition &&\n obs.submission &&\n obs.processLinkIsForm &&\n !obs.processLinkIsUiComponent &&\n !obs.processLinkIsFormViewModel\n \"\n [form]=\"obs.formDefinition\"\n [submission]=\"obs.submission\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n\n <valtimo-form-flow\n #formFlow\n *ngIf=\"obs.processLinkIsFormFlow\"\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask(obs.task)\"\n (formFlowChange)=\"onFormFlowChangeEvent()\"\n ></valtimo-form-flow>\n\n @if (obs.noFormNotification) {\n <cds-inline-notification [notificationObj]=\"obs.noFormNotification\"></cds-inline-notification>\n }\n\n @if (obs.errorMessage) {\n <cds-inline-notification\n [notificationObj]=\"{\n type: 'error',\n title: ('interface.error' | translate),\n message: obs.errorMessage,\n showClose: false,\n lowContrast: true\n }\"\n ></cds-inline-notification>\n }\n }\n\n <div class=\"m-2\">\n <ng-template #formViewModelComponent></ng-template>\n <ng-template #formCustomComponent></ng-template>\n </div>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormIoModule }, { kind: "component", type: i9.FormioComponent, selector: "valtimo-form-io", inputs: ["options", "submission", "form", "readOnly", "formRefresh$"], outputs: ["submit", "change", "event"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ProcessLinkModule }, { kind: "component", type: i7.FormFlowComponent, selector: "valtimo-form-flow", inputs: ["formIoFormData", "formFlowInstanceId"], outputs: ["formFlowComplete", "formFlowChange"] }, { kind: "ngmodule", type: LoadingModule }, { kind: "component", type:
|
|
1530
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailContentComponent, deps: [{ token: i1$1.ConfigService }, { token: i2.DocumentService }, { token: i1$1.GlobalNotificationService }, { token: i3.IconService }, { token: i4$2.NGXLogger }, { token: i9.ValtimoModalService }, { token: i3$1.PermissionService }, { token: i7.ProcessLinkService }, { token: i1$2.Router }, { token: i9.FormIoStateService }, { token: TaskIntermediateSaveService }, { token: TaskService }, { token: i4$1.TranslateService }, { token: FORM_VIEW_MODEL_TOKEN, optional: true }, { token: FORM_CUSTOM_COMPONENT_TOKEN, optional: true }, { token: i7.UrlResolverService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1531
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskDetailContentComponent, isStandalone: true, selector: "valtimo-task-detail-content", inputs: { task: "task", taskAndProcessLink: "taskAndProcessLink", modalClosed: "modalClosed" }, outputs: { closeModalEvent: "closeModalEvent", formSubmit: "formSubmit", activeChange: "activeChange", taskUpdated: "taskUpdated" }, viewQueries: [{ propertyName: "form", first: true, predicate: ["form"], descendants: true }, { propertyName: "formViewModelDynamicContainer", first: true, predicate: ["formViewModelComponent"], descendants: true, read: ViewContainerRef }, { propertyName: "formFlow", first: true, predicate: ["formFlow"], descendants: true }, { propertyName: "formCustomComponentDynamicContainer", first: true, predicate: ["formCustomComponent"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n loading: loading$ | async,\n task: task$ | async,\n taskId: taskInstanceId$ | async,\n formDefinition: formDefinition$ | async,\n formDefinitionId: formDefinitionId$ | async,\n formName: formName$ | async,\n formIoFormData: formIoFormData$ | async,\n submission: submission$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n processLinkIsFormViewModel: processLinkIsFormViewModel$ | async,\n processLinkIsUiComponent: processLinkIsUiComponent$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n noFormNotification: noFormNotification$ | async,\n } as obs\"\n>\n @if (obs.loading) {\n <div style=\"width: 100%; display: flex; justify-content: center; padding: 1rem\">\n <cds-loading size=\"sm\"></cds-loading>\n </div>\n } @else {\n <valtimo-form-io\n #form\n *ngIf=\"\n obs.formDefinition &&\n obs.submission &&\n obs.processLinkIsForm &&\n !obs.processLinkIsUiComponent &&\n !obs.processLinkIsFormViewModel\n \"\n [form]=\"obs.formDefinition\"\n [submission]=\"obs.submission\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n\n <valtimo-form-flow\n #formFlow\n *ngIf=\"obs.processLinkIsFormFlow\"\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask(obs.task)\"\n (formFlowChange)=\"onFormFlowChangeEvent()\"\n ></valtimo-form-flow>\n\n @if (obs.noFormNotification) {\n <cds-inline-notification [notificationObj]=\"obs.noFormNotification\"></cds-inline-notification>\n }\n\n @if (obs.errorMessage) {\n <cds-inline-notification\n [notificationObj]=\"{\n type: 'error',\n title: ('interface.error' | translate),\n message: obs.errorMessage,\n showClose: false,\n lowContrast: true\n }\"\n ></cds-inline-notification>\n }\n }\n\n <div class=\"m-2\">\n <ng-template #formViewModelComponent></ng-template>\n <ng-template #formCustomComponent></ng-template>\n </div>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormIoModule }, { kind: "component", type: i9.FormioComponent, selector: "valtimo-form-io", inputs: ["options", "submission", "form", "readOnly", "formRefresh$"], outputs: ["submit", "change", "event"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ProcessLinkModule }, { kind: "component", type: i7.FormFlowComponent, selector: "valtimo-form-flow", inputs: ["formIoFormData", "formFlowInstanceId"], outputs: ["formFlowComplete", "formFlowChange"] }, { kind: "ngmodule", type: LoadingModule }, { kind: "component", type: i3.Loading, selector: "cds-loading, ibm-loading", inputs: ["title", "isActive", "size", "overlay"] }, { kind: "ngmodule", type: NotificationModule }, { kind: "component", type: i3.Notification, selector: "cds-notification, cds-inline-notification, ibm-notification, ibm-inline-notification", inputs: ["notificationObj"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1411
1532
|
}
|
|
1412
1533
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailContentComponent, decorators: [{
|
|
1413
1534
|
type: Component,
|
|
@@ -1419,7 +1540,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
1419
1540
|
LoadingModule,
|
|
1420
1541
|
NotificationModule,
|
|
1421
1542
|
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n loading: loading$ | async,\n task: task$ | async,\n taskId: taskInstanceId$ | async,\n formDefinition: formDefinition$ | async,\n formDefinitionId: formDefinitionId$ | async,\n formName: formName$ | async,\n formIoFormData: formIoFormData$ | async,\n submission: submission$ | async,\n processLinkIsForm: processLinkIsForm$ | async,\n processLinkIsFormViewModel: processLinkIsFormViewModel$ | async,\n processLinkIsUiComponent: processLinkIsUiComponent$ | async,\n formioOptions: formioOptions$ | async,\n processLinkIsFormFlow: processLinkIsFormFlow$ | async,\n formFlowInstanceId: formFlowInstanceId$ | async,\n errorMessage: errorMessage$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n noFormNotification: noFormNotification$ | async,\n } as obs\"\n>\n @if (obs.loading) {\n <div style=\"width: 100%; display: flex; justify-content: center; padding: 1rem\">\n <cds-loading size=\"sm\"></cds-loading>\n </div>\n } @else {\n <valtimo-form-io\n #form\n *ngIf=\"\n obs.formDefinition &&\n obs.submission &&\n obs.processLinkIsForm &&\n !obs.processLinkIsUiComponent &&\n !obs.processLinkIsFormViewModel\n \"\n [form]=\"obs.formDefinition\"\n [submission]=\"obs.submission\"\n (submit)=\"onSubmit($event)\"\n (change)=\"onChange($event)\"\n [options]=\"obs.formioOptions\"\n ></valtimo-form-io>\n\n <valtimo-form-flow\n #formFlow\n *ngIf=\"obs.processLinkIsFormFlow\"\n [formIoFormData]=\"formIoFormData$\"\n [formFlowInstanceId]=\"obs.formFlowInstanceId\"\n (formFlowComplete)=\"completeTask(obs.task)\"\n (formFlowChange)=\"onFormFlowChangeEvent()\"\n ></valtimo-form-flow>\n\n @if (obs.noFormNotification) {\n <cds-inline-notification [notificationObj]=\"obs.noFormNotification\"></cds-inline-notification>\n }\n\n @if (obs.errorMessage) {\n <cds-inline-notification\n [notificationObj]=\"{\n type: 'error',\n title: ('interface.error' | translate),\n message: obs.errorMessage,\n showClose: false,\n lowContrast: true\n }\"\n ></cds-inline-notification>\n }\n }\n\n <div class=\"m-2\">\n <ng-template #formViewModelComponent></ng-template>\n <ng-template #formCustomComponent></ng-template>\n </div>\n</ng-container>\n" }]
|
|
1422
|
-
}], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i2
|
|
1543
|
+
}], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i2.DocumentService }, { type: i1$1.GlobalNotificationService }, { type: i3.IconService }, { type: i4$2.NGXLogger }, { type: i9.ValtimoModalService }, { type: i3$1.PermissionService }, { type: i7.ProcessLinkService }, { type: i1$2.Router }, { type: i9.FormIoStateService }, { type: TaskIntermediateSaveService }, { type: TaskService }, { type: i4$1.TranslateService }, { type: undefined, decorators: [{
|
|
1423
1544
|
type: Optional
|
|
1424
1545
|
}, {
|
|
1425
1546
|
type: Inject,
|
|
@@ -1453,6 +1574,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
1453
1574
|
type: Output
|
|
1454
1575
|
}], activeChange: [{
|
|
1455
1576
|
type: Output
|
|
1577
|
+
}], taskUpdated: [{
|
|
1578
|
+
type: Output
|
|
1456
1579
|
}] } });
|
|
1457
1580
|
|
|
1458
1581
|
/*
|
|
@@ -1597,8 +1720,8 @@ class TaskDetailIntermediateSaveComponent {
|
|
|
1597
1720
|
this.currentIntermediateSaveEvent.emit(this.currentIntermediateSave);
|
|
1598
1721
|
});
|
|
1599
1722
|
}
|
|
1600
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailIntermediateSaveComponent, deps: [{ token: i1$1.ConfigService }, { token: i1$1.GlobalNotificationService }, { token:
|
|
1601
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskDetailIntermediateSaveComponent, isStandalone: true, selector: "valtimo-task-detail-intermediate-save", inputs: { task: "task", taskAndProcessLink: "taskAndProcessLink" }, outputs: { currentIntermediateSaveEvent: "currentIntermediateSaveEvent", showModalEvent: "showModalEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n@if (intermediateSaveEnabled && (formFlowInstanceId$ | async) === undefined) {\n <button\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"save\"\n [vTooltip]=\"'formManagement.intermediateSave.save' | translate\"\n (click)=\"saveCurrentProgress()\"\n ></button>\n\n <button\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"recently-viewed\"\n [disabled]=\"!currentIntermediateSave\"\n [vTooltip]=\"'formManagement.intermediateSave.clear' | translate\"\n (click)=\"revertSaveClick()\"\n ></button>\n}\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n", styles: [":host{flex-shrink:0}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type:
|
|
1723
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailIntermediateSaveComponent, deps: [{ token: i1$1.ConfigService }, { token: i1$1.GlobalNotificationService }, { token: i3.IconService }, { token: TaskIntermediateSaveService }, { token: TaskService }, { token: i4$1.TranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1724
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskDetailIntermediateSaveComponent, isStandalone: true, selector: "valtimo-task-detail-intermediate-save", inputs: { task: "task", taskAndProcessLink: "taskAndProcessLink" }, outputs: { currentIntermediateSaveEvent: "currentIntermediateSaveEvent", showModalEvent: "showModalEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n@if (intermediateSaveEnabled && (formFlowInstanceId$ | async) === undefined) {\n <button\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"save\"\n [vTooltip]=\"'formManagement.intermediateSave.save' | translate\"\n (click)=\"saveCurrentProgress()\"\n ></button>\n\n <button\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"recently-viewed\"\n [disabled]=\"!currentIntermediateSave\"\n [vTooltip]=\"'formManagement.intermediateSave.clear' | translate\"\n (click)=\"revertSaveClick()\"\n ></button>\n}\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n", styles: [":host{flex-shrink:0}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i3.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: ConfirmationModalModule }, { kind: "component", type: i9.ConfirmationModalComponent, selector: "valtimo-confirmation-modal", inputs: ["titleTranslationKey", "title", "content", "contentTranslationKey", "confirmButtonText", "confirmButtonTextTranslationKey", "confirmButtonType", "showOptionalButton", "optionalButtonText", "optionalButtonTextTranslationKey", "optionalButtonType", "cancelButtonText", "cancelButtonTextTranslationKey", "cancelButtonType", "showModalSubject$", "outputOnConfirm", "outputOnOptional", "spacerAfterCancelButton"], outputs: ["confirmEvent", "optionalEvent", "cancelEvent"] }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i3.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "ngmodule", type: ModalModule }, { kind: "ngmodule", type: TooltipModule }, { kind: "directive", type: i9.TooltipDirective, selector: "[vTooltip]", inputs: ["vTooltip", "onBottom", "tooltipDisabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1602
1725
|
}
|
|
1603
1726
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailIntermediateSaveComponent, decorators: [{
|
|
1604
1727
|
type: Component,
|
|
@@ -1611,7 +1734,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
1611
1734
|
ModalModule,
|
|
1612
1735
|
TooltipModule,
|
|
1613
1736
|
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n@if (intermediateSaveEnabled && (formFlowInstanceId$ | async) === undefined) {\n <button\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"save\"\n [vTooltip]=\"'formManagement.intermediateSave.save' | translate\"\n (click)=\"saveCurrentProgress()\"\n ></button>\n\n <button\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"recently-viewed\"\n [disabled]=\"!currentIntermediateSave\"\n [vTooltip]=\"'formManagement.intermediateSave.clear' | translate\"\n (click)=\"revertSaveClick()\"\n ></button>\n}\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n", styles: [":host{flex-shrink:0}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
1614
|
-
}], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i1$1.GlobalNotificationService }, { type:
|
|
1737
|
+
}], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i1$1.GlobalNotificationService }, { type: i3.IconService }, { type: TaskIntermediateSaveService }, { type: TaskService }, { type: i4$1.TranslateService }], propDecorators: { task: [{
|
|
1615
1738
|
type: Input
|
|
1616
1739
|
}], taskAndProcessLink: [{
|
|
1617
1740
|
type: Input
|
|
@@ -1622,7 +1745,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
1622
1745
|
}] } });
|
|
1623
1746
|
|
|
1624
1747
|
/*
|
|
1625
|
-
* Copyright 2015-
|
|
1748
|
+
* Copyright 2015-2026 Ritense BV, the Netherlands.
|
|
1626
1749
|
*
|
|
1627
1750
|
* Licensed under EUPL, Version 1.2 (the "License");
|
|
1628
1751
|
* you may not use this file except in compliance with the License.
|
|
@@ -1648,44 +1771,82 @@ class SetTaskDueDateComponent {
|
|
|
1648
1771
|
return this.selectedDateString$.getValue();
|
|
1649
1772
|
}
|
|
1650
1773
|
set task(value) {
|
|
1651
|
-
if (!value)
|
|
1774
|
+
if (!value) {
|
|
1775
|
+
this.hasDueDate$.next(false);
|
|
1776
|
+
this._task$.next(null);
|
|
1777
|
+
this.selectedDateString$.next('');
|
|
1652
1778
|
return;
|
|
1779
|
+
}
|
|
1653
1780
|
this.hasDueDate$.next(!!value.due);
|
|
1654
1781
|
this._task$.next(value);
|
|
1655
1782
|
}
|
|
1656
|
-
constructor(iconService, taskService,
|
|
1783
|
+
constructor(cdsThemeService, iconService, taskService, translateService, globalNotificationService) {
|
|
1784
|
+
this.cdsThemeService = cdsThemeService;
|
|
1657
1785
|
this.iconService = iconService;
|
|
1658
1786
|
this.taskService = taskService;
|
|
1659
|
-
this.cdsThemeService = cdsThemeService;
|
|
1660
1787
|
this.translateService = translateService;
|
|
1788
|
+
this.globalNotificationService = globalNotificationService;
|
|
1789
|
+
this.dueDateChanged = new EventEmitter();
|
|
1661
1790
|
this.canModifyTaskSet$ = new BehaviorSubject(false);
|
|
1662
1791
|
this.canModifyTask$ = new BehaviorSubject(false);
|
|
1663
1792
|
this._task$ = new BehaviorSubject(null);
|
|
1664
1793
|
this.hasDueDate$ = new BehaviorSubject(false);
|
|
1665
1794
|
this.selectedDateString$ = new BehaviorSubject('');
|
|
1666
1795
|
this.taskDueDate$ = this._task$.pipe(filter$1(task => !!task), map(task => new Date(task.due)));
|
|
1796
|
+
this.showDatePicker$ = new BehaviorSubject(true);
|
|
1667
1797
|
this.disabled$ = new BehaviorSubject(false);
|
|
1668
1798
|
this.open$ = new Subject();
|
|
1799
|
+
this.editToggletipOpen$ = new BehaviorSubject(false);
|
|
1669
1800
|
this.mouseIsOverDueDate$ = new BehaviorSubject(false);
|
|
1670
1801
|
this.toggletipTheme$ = this.cdsThemeService.toggletipTheme$;
|
|
1802
|
+
this.toggletipDropdownTheme$ = this.cdsThemeService.toggletipDropdownTheme$;
|
|
1671
1803
|
this.language$ = this.translateService.onLangChange.pipe(map(event => event.lang), startWith(this.translateService.currentLang), distinctUntilChanged$1());
|
|
1672
|
-
this.iconService.registerAll([CalendarAdd16]);
|
|
1804
|
+
this.iconService.registerAll([CalendarAdd16, Edit16]);
|
|
1805
|
+
}
|
|
1806
|
+
clear() {
|
|
1807
|
+
this.selectedDateString$.next('');
|
|
1808
|
+
this.resetDatePicker();
|
|
1809
|
+
}
|
|
1810
|
+
initEditWithCurrentDate() {
|
|
1811
|
+
this.editToggletipOpen$.next(true);
|
|
1812
|
+
const task = this._task;
|
|
1813
|
+
if (task?.due) {
|
|
1814
|
+
this.selectedDateString$.next(new Date(task.due).toISOString());
|
|
1815
|
+
}
|
|
1816
|
+
else {
|
|
1817
|
+
this.selectedDateString$.next('');
|
|
1818
|
+
}
|
|
1819
|
+
this.resetDatePicker();
|
|
1820
|
+
}
|
|
1821
|
+
onCloseEditToggletip() {
|
|
1822
|
+
this.editToggletipOpen$.next(false);
|
|
1823
|
+
}
|
|
1824
|
+
onMouseEnterDueDate() {
|
|
1825
|
+
this.mouseIsOverDueDate$.next(true);
|
|
1826
|
+
}
|
|
1827
|
+
onMouseLeaveDueDate() {
|
|
1828
|
+
this.mouseIsOverDueDate$.next(false);
|
|
1673
1829
|
}
|
|
1674
1830
|
onDateValueChange(value) {
|
|
1675
1831
|
const date = Array.isArray(value) && value[0];
|
|
1676
|
-
if (!date)
|
|
1832
|
+
if (!date) {
|
|
1833
|
+
this.selectedDateString$.next('');
|
|
1677
1834
|
return;
|
|
1835
|
+
}
|
|
1678
1836
|
this.selectedDateString$.next(date.toISOString());
|
|
1679
1837
|
}
|
|
1680
1838
|
onSubmitButtonClick() {
|
|
1681
1839
|
this.disabled$.next(true);
|
|
1682
|
-
|
|
1840
|
+
const dateString = this._selectedDateString;
|
|
1841
|
+
this.taskService.setTaskDueDate(this._task.id, { dueDate: dateString }).subscribe({
|
|
1683
1842
|
next: () => {
|
|
1684
1843
|
this.disabled$.next(false);
|
|
1685
1844
|
this.hasDueDate$.next(true);
|
|
1686
|
-
this._task$.next({ ...this._task, due:
|
|
1845
|
+
this._task$.next({ ...this._task, due: dateString });
|
|
1687
1846
|
this.selectedDateString$.next('');
|
|
1688
1847
|
this.closeToggletip();
|
|
1848
|
+
this.dueDateChanged.emit();
|
|
1849
|
+
this.showDueDateSetNotification(dateString);
|
|
1689
1850
|
},
|
|
1690
1851
|
error: () => {
|
|
1691
1852
|
this.disabled$.next(false);
|
|
@@ -1699,25 +1860,46 @@ class SetTaskDueDateComponent {
|
|
|
1699
1860
|
this.disabled$.next(false);
|
|
1700
1861
|
this.hasDueDate$.next(false);
|
|
1701
1862
|
this._task$.next({ ...this._task, due: null });
|
|
1863
|
+
this.closeToggletip();
|
|
1864
|
+
this.dueDateChanged.emit();
|
|
1865
|
+
this.showDueDateRemovedNotification();
|
|
1702
1866
|
},
|
|
1703
1867
|
error: () => {
|
|
1704
1868
|
this.disabled$.next(false);
|
|
1705
1869
|
},
|
|
1706
1870
|
});
|
|
1707
1871
|
}
|
|
1872
|
+
resetDatePicker() {
|
|
1873
|
+
this.showDatePicker$.next(false);
|
|
1874
|
+
setTimeout(() => this.showDatePicker$.next(true));
|
|
1875
|
+
}
|
|
1708
1876
|
closeToggletip() {
|
|
1709
|
-
|
|
1877
|
+
this.editToggletipOpen$.next(false);
|
|
1710
1878
|
this.open$.next(true);
|
|
1711
1879
|
setTimeout(() => this.open$.next(false));
|
|
1712
1880
|
}
|
|
1713
|
-
|
|
1714
|
-
this.
|
|
1881
|
+
showDueDateSetNotification(dateString) {
|
|
1882
|
+
const formattedDate = new Date(dateString).toLocaleDateString(this.translateService.currentLang);
|
|
1883
|
+
this.globalNotificationService.showToast({
|
|
1884
|
+
title: this.translateService.instant('taskDetail.dueDateSetNotificationTitle'),
|
|
1885
|
+
subtitle: this.translateService.instant('taskDetail.dueDateSetNotificationContent', {
|
|
1886
|
+
date: formattedDate,
|
|
1887
|
+
task: this._task?.name,
|
|
1888
|
+
}),
|
|
1889
|
+
type: 'info',
|
|
1890
|
+
});
|
|
1715
1891
|
}
|
|
1716
|
-
|
|
1717
|
-
this.
|
|
1892
|
+
showDueDateRemovedNotification() {
|
|
1893
|
+
this.globalNotificationService.showToast({
|
|
1894
|
+
title: this.translateService.instant('taskDetail.dueDateRemovedNotificationTitle'),
|
|
1895
|
+
subtitle: this.translateService.instant('taskDetail.dueDateRemovedNotificationContent', {
|
|
1896
|
+
task: this._task?.name,
|
|
1897
|
+
}),
|
|
1898
|
+
type: 'info',
|
|
1899
|
+
});
|
|
1718
1900
|
}
|
|
1719
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: SetTaskDueDateComponent, deps: [{ token:
|
|
1720
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: SetTaskDueDateComponent, isStandalone: true, selector: "valtimo-set-task-due-date", inputs: { canModifyTask: "canModifyTask", task: "task" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-
|
|
1901
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: SetTaskDueDateComponent, deps: [{ token: i9.CdsThemeService }, { token: i3.IconService }, { token: TaskService }, { token: i4$1.TranslateService }, { token: i1$1.GlobalNotificationService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1902
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: SetTaskDueDateComponent, isStandalone: true, selector: "valtimo-set-task-due-date", inputs: { canModifyTask: "canModifyTask", task: "task" }, outputs: { dueDateChanged: "dueDateChanged" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2026 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<ng-container\n *ngIf=\"\n (canModifyTaskSet$ | async) && {\n hasDueDate: hasDueDate$ | async,\n taskDueDate: taskDueDate$ | async,\n selectedDateString: selectedDateString$ | async,\n disabled: disabled$ | async,\n mouseIsOverDueDate: mouseIsOverDueDate$ | async,\n canModifyTask: canModifyTask$ | async,\n language: language$ | async,\n showDatePicker: showDatePicker$ | async,\n editToggletipOpen: editToggletipOpen$ | async,\n } as obs\n \"\n>\n <div\n *ngIf=\"obs.canModifyTask || (!obs.canModifyTask && obs.hasDueDate)\"\n class=\"due-date-container\"\n (mouseenter)=\"onMouseEnterDueDate()\"\n (mouseleave)=\"onMouseLeaveDueDate()\"\n >\n <div\n class=\"due-date-text element\"\n [ngClass]=\"{\n active: obs.canModifyTask\n ? obs.hasDueDate && !obs.mouseIsOverDueDate && !obs.editToggletipOpen\n : obs.hasDueDate,\n }\"\n >\n <span class=\"bold\">{{ 'setTaskDueDate.dueDateText' | translate }}</span>\n \n {{ obs.taskDueDate | date: 'dd-MM-yyyy' }}\n </div>\n\n <cds-toggletip\n *ngIf=\"obs.canModifyTask\"\n align=\"bottom\"\n class=\"element\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: obs.hasDueDate && (obs.mouseIsOverDueDate || obs.editToggletipOpen)}\"\n (onOpen)=\"initEditWithCurrentDate()\"\n (onClose)=\"onCloseEditToggletip()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"ghost\"\n size=\"sm\"\n class=\"click-to-edit-button\"\n >\n {{ 'setTaskDueDate.clickToEdit' | translate }}\n </button>\n\n <div cdsToggletipContent class=\"assign-due-date-popover-content\">\n <cds-date-picker\n *ngIf=\"obs.showDatePicker\"\n [attr.data-carbon-theme]=\"toggletipDropdownTheme$ | async\"\n [cdsLayer]=\"1\"\n [label]=\"'setTaskDueDate.label' | translate\"\n [language]=\"obs.language\"\n [placeholder]=\"'dd-mm-jjjj'\"\n dateFormat=\"d/m/Y\"\n [value]=\"obs.taskDueDate ? [obs.taskDueDate] : []\"\n [disabled]=\"obs.disabled\"\n (valueChange)=\"onDateValueChange($event)\"\n ></cds-date-picker>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"submit-due-date-button\"\n [disabled]=\"!obs.selectedDateString || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'setTaskDueDate.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"calendar--add\" size=\"16\"></svg>\n </button>\n\n <button\n cdsButton=\"danger--tertiary\"\n [cdsLayer]=\"1\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [disabled]=\"obs.disabled\"\n (click)=\"onRemoveButtonClick()\"\n >\n {{ 'setTaskDueDate.removeButtonText' | translate }}\n </button>\n </div>\n </cds-toggletip>\n\n <cds-toggletip\n align=\"bottom\"\n class=\"element main\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: !obs.hasDueDate}\"\n (onOpen)=\"clear()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"tertiary\"\n size=\"sm\"\n class=\"set-task-due-date-button\"\n >\n {{ 'setTaskDueDate.buttonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"calendar--add\" size=\"16\"></svg>\n </button>\n\n <div cdsToggletipContent class=\"assign-due-date-popover-content\">\n <cds-date-picker\n *ngIf=\"!obs.hasDueDate && obs.showDatePicker\"\n [attr.data-carbon-theme]=\"toggletipDropdownTheme$ | async\"\n [cdsLayer]=\"1\"\n [label]=\"'setTaskDueDate.label' | translate\"\n [language]=\"obs.language\"\n [placeholder]=\"'dd-mm-jjjj'\"\n dateFormat=\"d/m/Y\"\n [disabled]=\"obs.disabled\"\n (valueChange)=\"onDateValueChange($event)\"\n ></cds-date-picker>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"submit-due-date-button\"\n [disabled]=\"!obs.selectedDateString || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'setTaskDueDate.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"calendar--add\" size=\"16\"></svg>\n </button>\n </div>\n </cds-toggletip>\n </div>\n</ng-container>\n", styles: [":host ::ng-deep .cds--popover-content{max-inline-size:unset}.due-date-container{display:flex;align-items:center;justify-content:center;position:relative;font-weight:400;font-size:14px;line-height:18px;letter-spacing:.16px;color:var(--cds-link-01)}.due-date-container .bold{font-weight:700}.due-date-text{display:flex;justify-content:flex-start;align-items:center;width:100%}.element{opacity:0;visibility:hidden;position:absolute;width:100%;transition:opacity .3s ease-in-out}.element.active{opacity:1;visibility:visible}.element.main{position:relative;width:auto}.assign-due-date-popover-content{width:400px;max-inline-size:400px;display:flex;flex-direction:column;gap:16px}.assign-due-date-popover-content .cds--btn{width:100%;max-width:unset}.assign-due-date-popover-content ::ng-deep .cds--date-picker-input__wrapper,.assign-due-date-popover-content ::ng-deep .cds--date-picker-input__wrapper>span,.assign-due-date-popover-content ::ng-deep .cds--date-picker-container,.assign-due-date-popover-content ::ng-deep .cds--date-picker,.assign-due-date-popover-content ::ng-deep .cds--date-picker__input{width:100%}.set-task-due-date-button{width:250px}.click-to-edit-button{width:100%}\n/*!\n * Copyright 2015-2026 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i11.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "pipe", type: i11.DatePipe, name: "date" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i3.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: IconModule }, { kind: "directive", type: i3.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "ngmodule", type: ToggletipModule }, { kind: "component", type: i3.Toggletip, selector: "cds-toggletip, ibm-toggletip", inputs: ["id", "isOpen"] }, { kind: "directive", type: i3.ToggletipButton, selector: "[cdsToggletipButton], [ibmToggletipButton]", inputs: ["ariaLabel"] }, { kind: "directive", type: i3.ToggletipContent, selector: "[cdsToggletipContent], [ibmToggletipContent]" }, { kind: "ngmodule", type: DatePickerModule }, { kind: "component", type: i3.DatePicker, selector: "cds-date-picker, ibm-date-picker", inputs: ["range", "dateFormat", "language", "label", "helperText", "rangeHelperText", "rangeLabel", "placeholder", "ariaLabel", "inputPattern", "id", "value", "theme", "disabled", "readonly", "invalid", "invalidText", "warn", "warnText", "size", "rangeInvalid", "rangeInvalidText", "rangeWarn", "rangeWarnText", "skeleton", "plugins", "flatpickrOptions"], outputs: ["valueChange", "onClose"] }, { kind: "ngmodule", type: LayerModule }, { kind: "directive", type: i3.LayerDirective, selector: "[cdsLayer], [ibmLayer]", inputs: ["ibmLayer", "cdsLayer"], exportAs: ["layer"] }, { kind: "directive", type: RemoveClassnamesDirective, selector: "[removeClassnames]", inputs: ["removeClassnames"] }] }); }
|
|
1721
1903
|
}
|
|
1722
1904
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: SetTaskDueDateComponent, decorators: [{
|
|
1723
1905
|
type: Component,
|
|
@@ -1730,8 +1912,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
1730
1912
|
DatePickerModule,
|
|
1731
1913
|
LayerModule,
|
|
1732
1914
|
RemoveClassnamesDirective,
|
|
1733
|
-
], template: "<!--\n ~ Copyright 2015-
|
|
1734
|
-
}], ctorParameters: () => [{ type:
|
|
1915
|
+
], template: "<!--\n ~ Copyright 2015-2026 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<ng-container\n *ngIf=\"\n (canModifyTaskSet$ | async) && {\n hasDueDate: hasDueDate$ | async,\n taskDueDate: taskDueDate$ | async,\n selectedDateString: selectedDateString$ | async,\n disabled: disabled$ | async,\n mouseIsOverDueDate: mouseIsOverDueDate$ | async,\n canModifyTask: canModifyTask$ | async,\n language: language$ | async,\n showDatePicker: showDatePicker$ | async,\n editToggletipOpen: editToggletipOpen$ | async,\n } as obs\n \"\n>\n <div\n *ngIf=\"obs.canModifyTask || (!obs.canModifyTask && obs.hasDueDate)\"\n class=\"due-date-container\"\n (mouseenter)=\"onMouseEnterDueDate()\"\n (mouseleave)=\"onMouseLeaveDueDate()\"\n >\n <div\n class=\"due-date-text element\"\n [ngClass]=\"{\n active: obs.canModifyTask\n ? obs.hasDueDate && !obs.mouseIsOverDueDate && !obs.editToggletipOpen\n : obs.hasDueDate,\n }\"\n >\n <span class=\"bold\">{{ 'setTaskDueDate.dueDateText' | translate }}</span>\n \n {{ obs.taskDueDate | date: 'dd-MM-yyyy' }}\n </div>\n\n <cds-toggletip\n *ngIf=\"obs.canModifyTask\"\n align=\"bottom\"\n class=\"element\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: obs.hasDueDate && (obs.mouseIsOverDueDate || obs.editToggletipOpen)}\"\n (onOpen)=\"initEditWithCurrentDate()\"\n (onClose)=\"onCloseEditToggletip()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"ghost\"\n size=\"sm\"\n class=\"click-to-edit-button\"\n >\n {{ 'setTaskDueDate.clickToEdit' | translate }}\n </button>\n\n <div cdsToggletipContent class=\"assign-due-date-popover-content\">\n <cds-date-picker\n *ngIf=\"obs.showDatePicker\"\n [attr.data-carbon-theme]=\"toggletipDropdownTheme$ | async\"\n [cdsLayer]=\"1\"\n [label]=\"'setTaskDueDate.label' | translate\"\n [language]=\"obs.language\"\n [placeholder]=\"'dd-mm-jjjj'\"\n dateFormat=\"d/m/Y\"\n [value]=\"obs.taskDueDate ? [obs.taskDueDate] : []\"\n [disabled]=\"obs.disabled\"\n (valueChange)=\"onDateValueChange($event)\"\n ></cds-date-picker>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"submit-due-date-button\"\n [disabled]=\"!obs.selectedDateString || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'setTaskDueDate.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"calendar--add\" size=\"16\"></svg>\n </button>\n\n <button\n cdsButton=\"danger--tertiary\"\n [cdsLayer]=\"1\"\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n [disabled]=\"obs.disabled\"\n (click)=\"onRemoveButtonClick()\"\n >\n {{ 'setTaskDueDate.removeButtonText' | translate }}\n </button>\n </div>\n </cds-toggletip>\n\n <cds-toggletip\n align=\"bottom\"\n class=\"element main\"\n [autoAlign]=\"true\"\n [isOpen]=\"open$ | async\"\n [ngClass]=\"{active: !obs.hasDueDate}\"\n (onOpen)=\"clear()\"\n >\n <button\n cdsToggletipButton\n [removeClassnames]=\"['cds--toggletip-button']\"\n cdsButton=\"tertiary\"\n size=\"sm\"\n class=\"set-task-due-date-button\"\n >\n {{ 'setTaskDueDate.buttonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"calendar--add\" size=\"16\"></svg>\n </button>\n\n <div cdsToggletipContent class=\"assign-due-date-popover-content\">\n <cds-date-picker\n *ngIf=\"!obs.hasDueDate && obs.showDatePicker\"\n [attr.data-carbon-theme]=\"toggletipDropdownTheme$ | async\"\n [cdsLayer]=\"1\"\n [label]=\"'setTaskDueDate.label' | translate\"\n [language]=\"obs.language\"\n [placeholder]=\"'dd-mm-jjjj'\"\n dateFormat=\"d/m/Y\"\n [disabled]=\"obs.disabled\"\n (valueChange)=\"onDateValueChange($event)\"\n ></cds-date-picker>\n\n <button\n cdsButton\n [attr.data-carbon-theme]=\"toggletipTheme$ | async\"\n class=\"submit-due-date-button\"\n [disabled]=\"!obs.selectedDateString || obs.disabled\"\n (click)=\"onSubmitButtonClick()\"\n >\n {{ 'setTaskDueDate.submitButtonText' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"calendar--add\" size=\"16\"></svg>\n </button>\n </div>\n </cds-toggletip>\n </div>\n</ng-container>\n", styles: [":host ::ng-deep .cds--popover-content{max-inline-size:unset}.due-date-container{display:flex;align-items:center;justify-content:center;position:relative;font-weight:400;font-size:14px;line-height:18px;letter-spacing:.16px;color:var(--cds-link-01)}.due-date-container .bold{font-weight:700}.due-date-text{display:flex;justify-content:flex-start;align-items:center;width:100%}.element{opacity:0;visibility:hidden;position:absolute;width:100%;transition:opacity .3s ease-in-out}.element.active{opacity:1;visibility:visible}.element.main{position:relative;width:auto}.assign-due-date-popover-content{width:400px;max-inline-size:400px;display:flex;flex-direction:column;gap:16px}.assign-due-date-popover-content .cds--btn{width:100%;max-width:unset}.assign-due-date-popover-content ::ng-deep .cds--date-picker-input__wrapper,.assign-due-date-popover-content ::ng-deep .cds--date-picker-input__wrapper>span,.assign-due-date-popover-content ::ng-deep .cds--date-picker-container,.assign-due-date-popover-content ::ng-deep .cds--date-picker,.assign-due-date-popover-content ::ng-deep .cds--date-picker__input{width:100%}.set-task-due-date-button{width:250px}.click-to-edit-button{width:100%}\n/*!\n * Copyright 2015-2026 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"] }]
|
|
1916
|
+
}], ctorParameters: () => [{ type: i9.CdsThemeService }, { type: i3.IconService }, { type: TaskService }, { type: i4$1.TranslateService }, { type: i1$1.GlobalNotificationService }], propDecorators: { dueDateChanged: [{
|
|
1917
|
+
type: Output
|
|
1918
|
+
}], canModifyTask: [{
|
|
1735
1919
|
type: Input
|
|
1736
1920
|
}], task: [{
|
|
1737
1921
|
type: Input
|
|
@@ -1776,11 +1960,12 @@ class TaskDetailModalComponent {
|
|
|
1776
1960
|
this.globalNotificationService = globalNotificationService;
|
|
1777
1961
|
this.formSubmit = new EventEmitter();
|
|
1778
1962
|
this.assignmentOfTaskChanged = new EventEmitter();
|
|
1963
|
+
this.dueDateChanged = new EventEmitter();
|
|
1964
|
+
this.modalClosed = new EventEmitter();
|
|
1779
1965
|
this.currentIntermediateSave$ = new BehaviorSubject(null);
|
|
1780
1966
|
this.processLinkPreloaded$ = new BehaviorSubject(false);
|
|
1781
1967
|
this.task$ = new BehaviorSubject(null);
|
|
1782
1968
|
this.taskAndProcessLink$ = new BehaviorSubject(null);
|
|
1783
|
-
this.task = new BehaviorSubject(null);
|
|
1784
1969
|
this.submission$ = new BehaviorSubject({});
|
|
1785
1970
|
this.page$ = new BehaviorSubject(null);
|
|
1786
1971
|
this.showConfirmationModal$ = new BehaviorSubject(false);
|
|
@@ -1856,30 +2041,39 @@ class TaskDetailModalComponent {
|
|
|
1856
2041
|
}
|
|
1857
2042
|
else {
|
|
1858
2043
|
const currentTask = this.task$.getValue();
|
|
1859
|
-
const
|
|
1860
|
-
if (currentTask
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
});
|
|
1870
|
-
}
|
|
1871
|
-
else {
|
|
1872
|
-
this.globalNotificationService.showToast({
|
|
1873
|
-
title: this.translateService.instant('taskDetail.unassignedNotificationTitle'),
|
|
1874
|
-
content: this.translateService.instant('taskDetail.unassignedNotificationContent'),
|
|
1875
|
-
type: 'info',
|
|
1876
|
-
});
|
|
2044
|
+
const fetchedTask = response.task;
|
|
2045
|
+
if (!currentTask || !fetchedTask)
|
|
2046
|
+
return;
|
|
2047
|
+
// Merge fetched task data onto the existing task, only overwriting with
|
|
2048
|
+
// defined values to preserve fields not returned by the GET /v1/task/{id}
|
|
2049
|
+
// endpoint (e.g. valtimoAssignee, businessKey, caseDocumentId)
|
|
2050
|
+
const mergedTask = { ...currentTask };
|
|
2051
|
+
for (const [key, value] of Object.entries(fetchedTask)) {
|
|
2052
|
+
if (value !== undefined) {
|
|
2053
|
+
mergedTask[key] = value;
|
|
1877
2054
|
}
|
|
1878
2055
|
}
|
|
1879
|
-
|
|
2056
|
+
if (currentTask.assignee !== mergedTask.assignee) {
|
|
2057
|
+
this.showAssigneeNotification(mergedTask);
|
|
2058
|
+
}
|
|
2059
|
+
this.task$.next(mergedTask);
|
|
1880
2060
|
}
|
|
1881
2061
|
}));
|
|
1882
2062
|
}
|
|
2063
|
+
showAssigneeNotification(task) {
|
|
2064
|
+
if (task.assignee) {
|
|
2065
|
+
this.globalNotificationService.showToast({
|
|
2066
|
+
title: this.translateService.instant('taskDetail.assignedNotificationTitle'),
|
|
2067
|
+
type: 'info',
|
|
2068
|
+
});
|
|
2069
|
+
}
|
|
2070
|
+
else {
|
|
2071
|
+
this.globalNotificationService.showToast({
|
|
2072
|
+
title: this.translateService.instant('taskDetail.unassignedNotificationTitle'),
|
|
2073
|
+
type: 'info',
|
|
2074
|
+
});
|
|
2075
|
+
}
|
|
2076
|
+
}
|
|
1883
2077
|
clearCurrentProgress() {
|
|
1884
2078
|
this._intermediateSaveComponent.clearCurrentProgress();
|
|
1885
2079
|
}
|
|
@@ -1887,23 +2081,24 @@ class TaskDetailModalComponent {
|
|
|
1887
2081
|
if (task) {
|
|
1888
2082
|
this.task$.next({ ...task });
|
|
1889
2083
|
}
|
|
1890
|
-
this.
|
|
1891
|
-
title: task?.name,
|
|
1892
|
-
subtitle: `${this.translateService.instant('taskDetail.taskCreated')} ${task?.created}`,
|
|
1893
|
-
});
|
|
2084
|
+
this.setPageFromTask(task);
|
|
1894
2085
|
this.openModal();
|
|
1895
2086
|
}
|
|
1896
2087
|
openTaskAndProcessLinkDetails(taskWithProcessLink) {
|
|
1897
2088
|
this.processLinkPreloaded$.next(true);
|
|
1898
2089
|
if (taskWithProcessLink) {
|
|
1899
2090
|
this.taskAndProcessLink$.next(taskWithProcessLink);
|
|
1900
|
-
|
|
2091
|
+
const task = enrichTaskFromProcessLink({ ...taskWithProcessLink.task }, taskWithProcessLink.processLinkActivityResult);
|
|
2092
|
+
this.task$.next(task);
|
|
1901
2093
|
}
|
|
2094
|
+
this.setPageFromTask(taskWithProcessLink?.task);
|
|
2095
|
+
this.openModal();
|
|
2096
|
+
}
|
|
2097
|
+
setPageFromTask(task) {
|
|
1902
2098
|
this.page$.next({
|
|
1903
|
-
title:
|
|
1904
|
-
subtitle: `${this.translateService.instant('taskDetail.taskCreated')} ${
|
|
2099
|
+
title: task?.name,
|
|
2100
|
+
subtitle: `${this.translateService.instant('taskDetail.taskCreated')} ${task?.created}`,
|
|
1905
2101
|
});
|
|
1906
|
-
this.openModal();
|
|
1907
2102
|
}
|
|
1908
2103
|
gotoProcessLinkScreen() {
|
|
1909
2104
|
this.closeModal();
|
|
@@ -1912,6 +2107,9 @@ class TaskDetailModalComponent {
|
|
|
1912
2107
|
onCurrentIntermediateSaveEvent(value) {
|
|
1913
2108
|
this.currentIntermediateSave$.next(value);
|
|
1914
2109
|
}
|
|
2110
|
+
onTaskUpdated(task) {
|
|
2111
|
+
this.task$.next(task);
|
|
2112
|
+
}
|
|
1915
2113
|
onFormSubmit() {
|
|
1916
2114
|
this.formSubmit.emit();
|
|
1917
2115
|
}
|
|
@@ -1921,8 +2119,12 @@ class TaskDetailModalComponent {
|
|
|
1921
2119
|
closeModal() {
|
|
1922
2120
|
this.modalOpen$.next(false);
|
|
1923
2121
|
this.modalCloseEvent$.next(!this.modalCloseEvent$.getValue());
|
|
1924
|
-
|
|
2122
|
+
this.modalClosed.emit();
|
|
2123
|
+
// Delay clearing task data and submission until after modal close animation completes
|
|
1925
2124
|
runAfterCarbonModalClosed(() => {
|
|
2125
|
+
this.processLinkPreloaded$.next(false);
|
|
2126
|
+
this.task$.next(null);
|
|
2127
|
+
this.taskAndProcessLink$.next(null);
|
|
1926
2128
|
this.taskIntermediateSaveService.setSubmission({});
|
|
1927
2129
|
});
|
|
1928
2130
|
}
|
|
@@ -1933,19 +2135,23 @@ class TaskDetailModalComponent {
|
|
|
1933
2135
|
this.cdr.detectChanges();
|
|
1934
2136
|
});
|
|
1935
2137
|
}
|
|
1936
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailModalComponent, deps: [{ token: i1$2.Router }, { token: i4.TranslateService }, { token: i3.PermissionService }, { token: i4$
|
|
1937
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskDetailModalComponent, isStandalone: false, selector: "valtimo-task-detail-modal", inputs: { modalSize: "modalSize", openFromCaseManagement: "openFromCaseManagement" }, outputs: { formSubmit: "formSubmit", assignmentOfTaskChanged: "assignmentOfTaskChanged" }, viewQueries: [{ propertyName: "_intermediateSaveComponent", first: true, predicate: TaskDetailIntermediateSaveComponent, descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n id=\"taskDetailModal\"\n [size]=\"size$ | async\"\n [open]=\"modalOpen$ | async\"\n (close)=\"closeModal()\"\n valtimoCdsModal\n [minContentHeight]=\"480\"\n>\n <cds-modal-header (closeSelect)=\"closeModal()\">\n <div class=\"title-container\">\n <p class=\"cds--modal-header__heading cds--type-beta\">{{ (page$ | async)?.title }}</p>\n\n <p class=\"cds--modal-header__label cds--type-delta\">{{ (page$ | async)?.subtitle }}</p>\n\n <p\n class=\"cds--modal-header__label cds--type-delta\"\n *ngIf=\"currentIntermediateSave$ | async as currentIntermediateSave\"\n >\n {{ 'formManagement.intermediateSave.lastSavedBy' | translate }}:\n\n {{\n currentIntermediateSave?.editedBy\n ? currentIntermediateSave?.editedBy\n : currentIntermediateSave.createdBy\n }}\n\n {{ 'formManagement.intermediateSave.on' | translate }}:\n\n {{\n currentIntermediateSave?.editedOn\n ? currentIntermediateSave?.editedOn\n : currentIntermediateSave.createdOn\n }}\n </p>\n\n <ng-container *ngTemplateOutlet=\"assignUserToTask\"></ng-container>\n </div>\n\n <div class=\"save-buttons-margin\">\n <button\n *ngIf=\"!(openFromCaseManagement$ | async)\"\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"folder--details--reference\"\n [vTooltip]=\"'formManagement.navigateToRelatedCase' | translate\"\n (click)=\"openRelatedCase()\"\n ></button>\n\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-intermediate-save\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n } @else {\n <valtimo-task-detail-intermediate-save\n [task]=\"task$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n }\n </div>\n </cds-modal-header>\n\n <div body class=\"cds--modal-content pb-1\">\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-content\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n ></valtimo-task-detail-content>\n } @else {\n <valtimo-task-detail-content\n [task]=\"task$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n ></valtimo-task-detail-content>\n }\n </div>\n</cds-modal>\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n\n<ng-template #assignUserToTask>\n <div\n *ngIf=\"{\n task: task$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n canModifyTask: canModifyTask$ | async,\n } as obs\"\n class=\"task-actions\"\n >\n <valtimo-assign-user-to-task\n *ngIf=\"obs.task && assignmentOfTaskChanged\"\n [taskId]=\"obs.task.id\"\n [assigneeId]=\"obs.task.assignee\"\n [canAssignUserToTask]=\"obs.canAssignUserToTask\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n\n <valtimo-set-task-due-date\n [task]=\"obs.task\"\n [canModifyTask]=\"obs.canModifyTask\"\n ></valtimo-set-task-due-date>\n </div>\n</ng-template>\n", styles: ["#taskDetailModal .formio-component-submit{text-align:right}#taskDetailModal .cds--modal:not(.is-visible){pointer-events:none}cds-modal-header .cds--modal-header{display:flex;justify-content:space-between}.save-buttons-margin{margin-top:-15px}.task-actions{display:flex;flex-wrap:wrap;width:100%;padding-top:8px;gap:8px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i11.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type:
|
|
2138
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailModalComponent, deps: [{ token: i1$2.Router }, { token: i4$1.TranslateService }, { token: i3$1.PermissionService }, { token: i4$2.NGXLogger }, { token: TaskIntermediateSaveService }, { token: i6.SseService }, { token: i0.ChangeDetectorRef }, { token: i3.IconService }, { token: i2.DocumentService }, { token: TaskService }, { token: i1$1.GlobalNotificationService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2139
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskDetailModalComponent, isStandalone: false, selector: "valtimo-task-detail-modal", inputs: { modalSize: "modalSize", openFromCaseManagement: "openFromCaseManagement" }, outputs: { formSubmit: "formSubmit", assignmentOfTaskChanged: "assignmentOfTaskChanged", dueDateChanged: "dueDateChanged", modalClosed: "modalClosed" }, viewQueries: [{ propertyName: "_intermediateSaveComponent", first: true, predicate: TaskDetailIntermediateSaveComponent, descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n id=\"taskDetailModal\"\n [size]=\"size$ | async\"\n [open]=\"modalOpen$ | async\"\n (close)=\"closeModal()\"\n valtimoCdsModal\n [minContentHeight]=\"480\"\n>\n <cds-modal-header (closeSelect)=\"closeModal()\">\n <div class=\"title-container\">\n <p class=\"cds--modal-header__heading cds--type-beta\">{{ (page$ | async)?.title }}</p>\n\n <p class=\"cds--modal-header__label cds--type-delta\">{{ (page$ | async)?.subtitle }}</p>\n\n <p\n class=\"cds--modal-header__label cds--type-delta\"\n *ngIf=\"currentIntermediateSave$ | async as currentIntermediateSave\"\n >\n {{ 'formManagement.intermediateSave.lastSavedBy' | translate }}:\n\n {{\n currentIntermediateSave?.editedBy\n ? currentIntermediateSave?.editedBy\n : currentIntermediateSave.createdBy\n }}\n\n {{ 'formManagement.intermediateSave.on' | translate }}:\n\n {{\n currentIntermediateSave?.editedOn\n ? currentIntermediateSave?.editedOn\n : currentIntermediateSave.createdOn\n }}\n </p>\n\n <ng-container *ngTemplateOutlet=\"assignUserToTask\"></ng-container>\n </div>\n\n <div class=\"save-buttons-margin\">\n <button\n *ngIf=\"!(openFromCaseManagement$ | async)\"\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"folder--details--reference\"\n [vTooltip]=\"'formManagement.navigateToRelatedCase' | translate\"\n (click)=\"openRelatedCase()\"\n ></button>\n\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-intermediate-save\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n } @else {\n <valtimo-task-detail-intermediate-save\n [task]=\"task$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n }\n </div>\n </cds-modal-header>\n\n <div body class=\"cds--modal-content pb-1\">\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-content\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n (taskUpdated)=\"onTaskUpdated($event)\"\n ></valtimo-task-detail-content>\n } @else {\n <valtimo-task-detail-content\n [task]=\"task$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n (taskUpdated)=\"onTaskUpdated($event)\"\n ></valtimo-task-detail-content>\n }\n </div>\n</cds-modal>\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n\n<ng-template #assignUserToTask>\n <div\n *ngIf=\"{\n task: task$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n canModifyTask: canModifyTask$ | async,\n } as obs\"\n class=\"task-actions\"\n >\n <valtimo-assign-user-to-task\n *ngIf=\"obs.task && assignmentOfTaskChanged\"\n [taskId]=\"obs.task.id\"\n [assigneeId]=\"obs.task.assignee\"\n [canAssignUserToTask]=\"obs.canAssignUserToTask\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n\n <valtimo-set-task-due-date\n [task]=\"obs.task\"\n [canModifyTask]=\"obs.canModifyTask\"\n (dueDateChanged)=\"dueDateChanged.emit()\"\n ></valtimo-set-task-due-date>\n </div>\n</ng-template>\n", styles: ["#taskDetailModal .formio-component-submit{text-align:right}#taskDetailModal .cds--modal:not(.is-visible){pointer-events:none}cds-modal-header .cds--modal-header{display:flex;justify-content:space-between}.save-buttons-margin{margin-top:-15px}.task-actions{display:flex;flex-wrap:wrap;width:100%;padding-top:8px;gap:8px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i11.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i3.Modal, selector: "cds-modal, ibm-modal", inputs: ["size", "theme", "ariaLabel", "open", "trigger", "hasScrollingContent"], outputs: ["overlaySelected", "close"] }, { kind: "component", type: i3.ModalHeader, selector: "cds-modal-header, ibm-modal-header", inputs: ["theme", "closeLabel", "showCloseButton"], outputs: ["closeSelect"] }, { kind: "directive", type: i3.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "directive", type: i3.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "directive", type: i9.TooltipDirective, selector: "[vTooltip]", inputs: ["vTooltip", "onBottom", "tooltipDisabled"] }, { kind: "component", type: i9.ConfirmationModalComponent, selector: "valtimo-confirmation-modal", inputs: ["titleTranslationKey", "title", "content", "contentTranslationKey", "confirmButtonText", "confirmButtonTextTranslationKey", "confirmButtonType", "showOptionalButton", "optionalButtonText", "optionalButtonTextTranslationKey", "optionalButtonType", "cancelButtonText", "cancelButtonTextTranslationKey", "cancelButtonType", "showModalSubject$", "outputOnConfirm", "outputOnOptional", "spacerAfterCancelButton"], outputs: ["confirmEvent", "optionalEvent", "cancelEvent"] }, { kind: "component", type: AssignUserToTaskComponent, selector: "valtimo-assign-user-to-task", inputs: ["taskId", "assigneeId", "canAssignUserToTask"], outputs: ["assignmentOfTaskChanged"] }, { kind: "component", type: TaskDetailContentComponent, selector: "valtimo-task-detail-content", inputs: ["task", "taskAndProcessLink", "modalClosed"], outputs: ["closeModalEvent", "formSubmit", "activeChange", "taskUpdated"] }, { kind: "component", type: TaskDetailIntermediateSaveComponent, selector: "valtimo-task-detail-intermediate-save", inputs: ["task", "taskAndProcessLink"], outputs: ["currentIntermediateSaveEvent", "showModalEvent"] }, { kind: "component", type: SetTaskDueDateComponent, selector: "valtimo-set-task-due-date", inputs: ["canModifyTask", "task"], outputs: ["dueDateChanged"] }, { kind: "directive", type: i9.ValtimoCdsModalDirective, selector: "[valtimoCdsModal]", inputs: ["minContentHeight"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None }); }
|
|
1938
2140
|
}
|
|
1939
2141
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskDetailModalComponent, decorators: [{
|
|
1940
2142
|
type: Component,
|
|
1941
|
-
args: [{ standalone: false, selector: 'valtimo-task-detail-modal', encapsulation: ViewEncapsulation.None, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n id=\"taskDetailModal\"\n [size]=\"size$ | async\"\n [open]=\"modalOpen$ | async\"\n (close)=\"closeModal()\"\n valtimoCdsModal\n [minContentHeight]=\"480\"\n>\n <cds-modal-header (closeSelect)=\"closeModal()\">\n <div class=\"title-container\">\n <p class=\"cds--modal-header__heading cds--type-beta\">{{ (page$ | async)?.title }}</p>\n\n <p class=\"cds--modal-header__label cds--type-delta\">{{ (page$ | async)?.subtitle }}</p>\n\n <p\n class=\"cds--modal-header__label cds--type-delta\"\n *ngIf=\"currentIntermediateSave$ | async as currentIntermediateSave\"\n >\n {{ 'formManagement.intermediateSave.lastSavedBy' | translate }}:\n\n {{\n currentIntermediateSave?.editedBy\n ? currentIntermediateSave?.editedBy\n : currentIntermediateSave.createdBy\n }}\n\n {{ 'formManagement.intermediateSave.on' | translate }}:\n\n {{\n currentIntermediateSave?.editedOn\n ? currentIntermediateSave?.editedOn\n : currentIntermediateSave.createdOn\n }}\n </p>\n\n <ng-container *ngTemplateOutlet=\"assignUserToTask\"></ng-container>\n </div>\n\n <div class=\"save-buttons-margin\">\n <button\n *ngIf=\"!(openFromCaseManagement$ | async)\"\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"folder--details--reference\"\n [vTooltip]=\"'formManagement.navigateToRelatedCase' | translate\"\n (click)=\"openRelatedCase()\"\n ></button>\n\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-intermediate-save\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n } @else {\n <valtimo-task-detail-intermediate-save\n [task]=\"task$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n }\n </div>\n </cds-modal-header>\n\n <div body class=\"cds--modal-content pb-1\">\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-content\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n ></valtimo-task-detail-content>\n } @else {\n <valtimo-task-detail-content\n [task]=\"task$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n ></valtimo-task-detail-content>\n }\n </div>\n</cds-modal>\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n\n<ng-template #assignUserToTask>\n <div\n *ngIf=\"{\n task: task$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n canModifyTask: canModifyTask$ | async,\n } as obs\"\n class=\"task-actions\"\n >\n <valtimo-assign-user-to-task\n *ngIf=\"obs.task && assignmentOfTaskChanged\"\n [taskId]=\"obs.task.id\"\n [assigneeId]=\"obs.task.assignee\"\n [canAssignUserToTask]=\"obs.canAssignUserToTask\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n\n <valtimo-set-task-due-date\n [task]=\"obs.task\"\n [canModifyTask]=\"obs.canModifyTask\"\n ></valtimo-set-task-due-date>\n </div>\n</ng-template>\n", styles: ["#taskDetailModal .formio-component-submit{text-align:right}#taskDetailModal .cds--modal:not(.is-visible){pointer-events:none}cds-modal-header .cds--modal-header{display:flex;justify-content:space-between}.save-buttons-margin{margin-top:-15px}.task-actions{display:flex;flex-wrap:wrap;width:100%;padding-top:8px;gap:8px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
1942
|
-
}], ctorParameters: () => [{ type: i1$2.Router }, { type: i4.TranslateService }, { type: i3.PermissionService }, { type: i4$
|
|
2143
|
+
args: [{ standalone: false, selector: 'valtimo-task-detail-modal', encapsulation: ViewEncapsulation.None, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n id=\"taskDetailModal\"\n [size]=\"size$ | async\"\n [open]=\"modalOpen$ | async\"\n (close)=\"closeModal()\"\n valtimoCdsModal\n [minContentHeight]=\"480\"\n>\n <cds-modal-header (closeSelect)=\"closeModal()\">\n <div class=\"title-container\">\n <p class=\"cds--modal-header__heading cds--type-beta\">{{ (page$ | async)?.title }}</p>\n\n <p class=\"cds--modal-header__label cds--type-delta\">{{ (page$ | async)?.subtitle }}</p>\n\n <p\n class=\"cds--modal-header__label cds--type-delta\"\n *ngIf=\"currentIntermediateSave$ | async as currentIntermediateSave\"\n >\n {{ 'formManagement.intermediateSave.lastSavedBy' | translate }}:\n\n {{\n currentIntermediateSave?.editedBy\n ? currentIntermediateSave?.editedBy\n : currentIntermediateSave.createdBy\n }}\n\n {{ 'formManagement.intermediateSave.on' | translate }}:\n\n {{\n currentIntermediateSave?.editedOn\n ? currentIntermediateSave?.editedOn\n : currentIntermediateSave.createdOn\n }}\n </p>\n\n <ng-container *ngTemplateOutlet=\"assignUserToTask\"></ng-container>\n </div>\n\n <div class=\"save-buttons-margin\">\n <button\n *ngIf=\"!(openFromCaseManagement$ | async)\"\n cdsButton=\"ghost\"\n iconOnly=\"true\"\n cdsIcon=\"folder--details--reference\"\n [vTooltip]=\"'formManagement.navigateToRelatedCase' | translate\"\n (click)=\"openRelatedCase()\"\n ></button>\n\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-intermediate-save\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n } @else {\n <valtimo-task-detail-intermediate-save\n [task]=\"task$ | async\"\n (currentIntermediateSaveEvent)=\"onCurrentIntermediateSaveEvent($event)\"\n (showModalEvent)=\"onShowModalEvent()\"\n ></valtimo-task-detail-intermediate-save>\n }\n </div>\n </cds-modal-header>\n\n <div body class=\"cds--modal-content pb-1\">\n @if (processLinkPreloaded$ | async) {\n <valtimo-task-detail-content\n [taskAndProcessLink]=\"taskAndProcessLink$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n (taskUpdated)=\"onTaskUpdated($event)\"\n ></valtimo-task-detail-content>\n } @else {\n <valtimo-task-detail-content\n [task]=\"task$ | async\"\n [modalClosed]=\"modalCloseEvent$ | async\"\n (formSubmit)=\"onFormSubmit()\"\n (closeModalEvent)=\"closeModal()\"\n (taskUpdated)=\"onTaskUpdated($event)\"\n ></valtimo-task-detail-content>\n }\n </div>\n</cds-modal>\n\n<valtimo-confirmation-modal\n [showModalSubject$]=\"showConfirmationModal$\"\n (confirmEvent)=\"clearCurrentProgress()\"\n (cancelEvent)=\"showConfirmationModal$.next(false)\"\n cancelButtonType=\"ghost\"\n confirmButtonTextTranslationKey=\"interface.confirm\"\n titleTranslationKey=\"formManagement.intermediateSave.clear\"\n contentTranslationKey=\"formManagement.intermediateSave.clearConfirm\"\n></valtimo-confirmation-modal>\n\n<ng-template #assignUserToTask>\n <div\n *ngIf=\"{\n task: task$ | async,\n canAssignUserToTask: canAssignUserToTask$ | async,\n canModifyTask: canModifyTask$ | async,\n } as obs\"\n class=\"task-actions\"\n >\n <valtimo-assign-user-to-task\n *ngIf=\"obs.task && assignmentOfTaskChanged\"\n [taskId]=\"obs.task.id\"\n [assigneeId]=\"obs.task.assignee\"\n [canAssignUserToTask]=\"obs.canAssignUserToTask\"\n (assignmentOfTaskChanged)=\"assignmentOfTaskChanged.emit()\"\n ></valtimo-assign-user-to-task>\n\n <valtimo-set-task-due-date\n [task]=\"obs.task\"\n [canModifyTask]=\"obs.canModifyTask\"\n (dueDateChanged)=\"dueDateChanged.emit()\"\n ></valtimo-set-task-due-date>\n </div>\n</ng-template>\n", styles: ["#taskDetailModal .formio-component-submit{text-align:right}#taskDetailModal .cds--modal:not(.is-visible){pointer-events:none}cds-modal-header .cds--modal-header{display:flex;justify-content:space-between}.save-buttons-margin{margin-top:-15px}.task-actions{display:flex;flex-wrap:wrap;width:100%;padding-top:8px;gap:8px}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
2144
|
+
}], ctorParameters: () => [{ type: i1$2.Router }, { type: i4$1.TranslateService }, { type: i3$1.PermissionService }, { type: i4$2.NGXLogger }, { type: TaskIntermediateSaveService }, { type: i6.SseService }, { type: i0.ChangeDetectorRef }, { type: i3.IconService }, { type: i2.DocumentService }, { type: TaskService }, { type: i1$1.GlobalNotificationService }], propDecorators: { _intermediateSaveComponent: [{
|
|
1943
2145
|
type: ViewChild,
|
|
1944
2146
|
args: [TaskDetailIntermediateSaveComponent]
|
|
1945
2147
|
}], formSubmit: [{
|
|
1946
2148
|
type: Output
|
|
1947
2149
|
}], assignmentOfTaskChanged: [{
|
|
1948
2150
|
type: Output
|
|
2151
|
+
}], dueDateChanged: [{
|
|
2152
|
+
type: Output
|
|
2153
|
+
}], modalClosed: [{
|
|
2154
|
+
type: Output
|
|
1949
2155
|
}], modalSize: [{
|
|
1950
2156
|
type: Input
|
|
1951
2157
|
}], openFromCaseManagement: [{
|
|
@@ -2037,7 +2243,16 @@ class TaskListComponent {
|
|
|
2037
2243
|
description: 'task-list.' + selectedTaskType + '.noResultsDescription',
|
|
2038
2244
|
isSearchResult: false,
|
|
2039
2245
|
}));
|
|
2040
|
-
this.fields$ = this.taskListColumnService.fields
|
|
2246
|
+
this.fields$ = this.taskListColumnService.fields$.pipe(map((fields) => [
|
|
2247
|
+
{
|
|
2248
|
+
key: 'isOpened',
|
|
2249
|
+
label: '',
|
|
2250
|
+
viewType: ViewType.TEMPLATE,
|
|
2251
|
+
template: this._unreadIndicator,
|
|
2252
|
+
className: 'valtimo-task-list__unread-column',
|
|
2253
|
+
},
|
|
2254
|
+
...fields,
|
|
2255
|
+
]));
|
|
2041
2256
|
this.loadingTasks$ = new BehaviorSubject(true);
|
|
2042
2257
|
this.visibleTabs$ = new BehaviorSubject(null);
|
|
2043
2258
|
this._enableLoadingAnimation$ = new BehaviorSubject(true);
|
|
@@ -2172,7 +2387,7 @@ class TaskListComponent {
|
|
|
2172
2387
|
this.taskListSortService.updateSortState(this.taskListService.selectedTaskType, sortState);
|
|
2173
2388
|
}
|
|
2174
2389
|
setCaseDefinition(definition) {
|
|
2175
|
-
if (definition.item.id) {
|
|
2390
|
+
if (definition.item.id && definition.item.id !== this.taskListService.caseDefinitionKey) {
|
|
2176
2391
|
this.taskListSortService.resetOverrideSortState();
|
|
2177
2392
|
this.loadingTasks$.next(true);
|
|
2178
2393
|
this.taskListService.setCaseDefinitionKey(definition.item.id);
|
|
@@ -2261,6 +2476,7 @@ class TaskListComponent {
|
|
|
2261
2476
|
caseDocumentId: specifiedTask.caseDocumentId,
|
|
2262
2477
|
processInstanceId: specifiedTask.processInstanceId,
|
|
2263
2478
|
name: specifiedTask.name,
|
|
2479
|
+
isOpened: specifiedTask.isOpened,
|
|
2264
2480
|
...(moment(specifiedTask.created).isValid() && {
|
|
2265
2481
|
created: moment(specifiedTask.created).format(MOMENT_FORMAT),
|
|
2266
2482
|
}),
|
|
@@ -2310,7 +2526,7 @@ class TaskListComponent {
|
|
|
2310
2526
|
if (decodedParams.params)
|
|
2311
2527
|
this.taskListPaginationService.updateTaskPagination(this.taskListService.selectedTaskType, decodedParams.params);
|
|
2312
2528
|
}
|
|
2313
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskListComponent, deps: [{ token: i1$1.ConfigService }, { token: i2
|
|
2529
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskListComponent, deps: [{ token: i1$1.ConfigService }, { token: i2.DocumentService }, { token: i3$1.PermissionService }, { token: i1$2.Router }, { token: TaskService }, { token: TaskListService }, { token: i4$1.TranslateService }, { token: TaskListColumnService }, { token: TaskListPaginationService }, { token: TaskListSortService }, { token: TaskListSearchService }, { token: TaskListQueryParamService }, { token: i9.PageTitleService }, { token: i6.SseService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2314
2530
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TaskListComponent, isStandalone: false, selector: "valtimo-task-list", host: { listeners: { "window:popstate": "onPopState($event)" } }, providers: [
|
|
2315
2531
|
TaskListService,
|
|
2316
2532
|
TaskListColumnService,
|
|
@@ -2318,7 +2534,7 @@ class TaskListComponent {
|
|
|
2318
2534
|
TaskListSortService,
|
|
2319
2535
|
TaskListSearchService,
|
|
2320
2536
|
TaskListQueryParamService,
|
|
2321
|
-
], viewQueries: [{ propertyName: "_taskDetail", first: true, predicate: ["taskDetail"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<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 overrideSortState: overrideSortState$ | async,\n searchFields: searchFields$ | async,\n loadingSearchFields: loadingSearchFields$ | async,\n caseDefinitionKey: caseDefinitionKey$ | async,\n noResultsMessage: noResultsMessage$ | async,\n } as obs\"\n class=\"main-content\"\n>\n <div class=\"container-fluid\">\n @if (obs.caseDefinitionKey && obs.caseDefinitionKey !== ALL_CASES_ID) {\n <ng-container\n *ngTemplateOutlet=\"\n searchFields;\n context: {\n obs: obs,\n }\n \"\n ></ng-container>\n }\n\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 [attr.data-testid]=\"'task-list-tab-' + tab\"\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 [sortState]=\"obs.overrideSortState || 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]=\"obs.noResultsMessage.description | translate\"\n [title]=\"obs.noResultsMessage.title | 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-template #searchFields let-obs=\"obs\">\n <div class=\"mb-3\">\n <valtimo-search-fields\n [searchFields]=\"obs.searchFields\"\n [inputDisabled]=\"obs.loadingSearchFields\"\n [caseDefinitionKey]=\"obs.caseDefinitionKey\"\n [setValuesSubject$]=\"setSearchFieldValuesSubject$\"\n [clearValuesSubject$]=\"clearSearchFieldValuesSubject$\"\n (doSearch)=\"search($event)\"\n >\n </valtimo-search-fields>\n </div>\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 [attr.data-testid]=\"'task-list-case-dropdown'\"\n [disabled]=\"obs.loadingCaseListItems || (obs.caseListItems || []).length === 1\"\n [skeleton]=\"obs.loadingCaseListItems\"\n (selected)=\"setCaseDefinition($event)\"\n >\n <cds-dropdown-list [items]=\"obs.caseListItems || []\"></cds-dropdown-list>\n </cds-dropdown>\n </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-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i11.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i11.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i9.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "skeletonRowCount", "actions", "actionItems", "showActionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "component", type: i9.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title", "smallPadding", "collapseVertically", "alwaysRenderVertically"] }, { kind: "directive", type: i12.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "triggers", "container", "disableTooltip", "tooltipClass", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "directive", type: i2.Link, selector: "[cdsLink], [ibmLink]", inputs: ["inline", "disabled"] }, { kind: "component", type: i2.Tabs, selector: "cds-tabs, ibm-tabs", inputs: ["position", "cacheActive", "followFocus", "isNavigation", "ariaLabel", "ariaLabelledby", "type", "theme", "skeleton"] }, { kind: "component", type: i2.Tab, selector: "cds-tab, ibm-tab", inputs: ["heading", "title", "context", "active", "disabled", "tabIndex", "id", "cacheActive", "tabContent", "templateContext"], outputs: ["selected"] }, { kind: "directive", type: i9.RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }, { kind: "component", type: i14.Dropdown, selector: "cds-dropdown, ibm-dropdown", inputs: ["id", "label", "hideLabel", "helperText", "placeholder", "displayValue", "clearText", "size", "type", "theme", "disabled", "readonly", "skeleton", "inline", "disableArrowKeys", "invalid", "invalidText", "warn", "warnText", "appendInline", "scrollableContainer", "itemValueKey", "selectionFeedback", "menuButtonLabel", "selectedLabel", "dropUp", "fluid"], outputs: ["selected", "onClose", "close"] }, { kind: "component", type: i14.DropdownList, selector: "cds-dropdown-list, ibm-dropdown-list", inputs: ["ariaLabel", "items", "listTpl", "type", "showTitles"], outputs: ["select", "scroll", "blurIntent"] }, { kind: "component", type: i9.SearchFieldsComponent, selector: "valtimo-search-fields", inputs: ["loading", "searchFields", "caseDefinitionKey", "setValuesSubject$", "clearValuesSubject$", "defaultValues", "disableSaveSearch", "inputDisabled", "externalSearchField", "canSaveSearch"], outputs: ["doSearch", "saveSearchEvent", "clearEvent"] }, { kind: "component", type: TaskDetailModalComponent, selector: "valtimo-task-detail-modal", inputs: ["modalSize", "openFromCaseManagement"], outputs: ["formSubmit", "assignmentOfTaskChanged"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
2537
|
+
], viewQueries: [{ propertyName: "_taskDetail", first: true, predicate: ["taskDetail"], descendants: true }, { propertyName: "_unreadIndicator", first: true, predicate: ["unreadIndicator"], descendants: true, static: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n 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 overrideSortState: overrideSortState$ | async,\n searchFields: searchFields$ | async,\n loadingSearchFields: loadingSearchFields$ | async,\n caseDefinitionKey: caseDefinitionKey$ | async,\n noResultsMessage: noResultsMessage$ | async,\n } as obs\"\n class=\"main-content\"\n>\n <div class=\"container-fluid\">\n @if (obs.caseDefinitionKey && obs.caseDefinitionKey !== ALL_CASES_ID) {\n <ng-container\n *ngTemplateOutlet=\"\n searchFields;\n context: {\n obs: obs,\n }\n \"\n ></ng-container>\n }\n\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 (dueDateChanged)=\"reload()\"\n (modalClosed)=\"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 [attr.data-testid]=\"'task-list-tab-' + tab\"\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 #unreadIndicator let-data=\"data\">\n <span *ngIf=\"!data.item?.isOpened\" class=\"valtimo-task-list__unread-dot\"></span>\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 [sortState]=\"obs.overrideSortState || 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]=\"obs.noResultsMessage.description | translate\"\n [title]=\"obs.noResultsMessage.title | 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-template #searchFields let-obs=\"obs\">\n <div class=\"mb-3\">\n <valtimo-search-fields\n [searchFields]=\"obs.searchFields\"\n [inputDisabled]=\"obs.loadingSearchFields\"\n [caseDefinitionKey]=\"obs.caseDefinitionKey\"\n [setValuesSubject$]=\"setSearchFieldValuesSubject$\"\n [clearValuesSubject$]=\"clearSearchFieldValuesSubject$\"\n (doSearch)=\"search($event)\"\n >\n </valtimo-search-fields>\n </div>\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 [attr.data-testid]=\"'task-list-case-dropdown'\"\n [disabled]=\"obs.loadingCaseListItems || (obs.caseListItems || []).length === 1\"\n [skeleton]=\"obs.loadingCaseListItems\"\n (selected)=\"setCaseDefinition($event)\"\n >\n <cds-dropdown-list [items]=\"obs.caseListItems || []\"></cds-dropdown-list>\n </cds-dropdown>\n </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}.valtimo-task-list__unread-dot{display:inline-block;width:8px;height:8px;border-radius:50%;background-color:var(--cds-link-primary)}::ng-deep .valtimo-task-list__unread-column{width:2rem;padding-right:0!important}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i11.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i11.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i9.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "skeletonRowCount", "actions", "actionItems", "showActionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "component", type: i9.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title", "smallPadding", "collapseVertically", "alwaysRenderVertically"] }, { kind: "directive", type: i12.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "triggers", "container", "disableTooltip", "tooltipClass", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "directive", type: i3.Link, selector: "[cdsLink], [ibmLink]", inputs: ["inline", "disabled"] }, { kind: "component", type: i3.Tabs, selector: "cds-tabs, ibm-tabs", inputs: ["position", "cacheActive", "followFocus", "isNavigation", "ariaLabel", "ariaLabelledby", "type", "theme", "skeleton"] }, { kind: "component", type: i3.Tab, selector: "cds-tab, ibm-tab", inputs: ["heading", "title", "context", "active", "disabled", "tabIndex", "id", "cacheActive", "tabContent", "templateContext"], outputs: ["selected"] }, { kind: "directive", type: i9.RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }, { kind: "component", type: i14.Dropdown, selector: "cds-dropdown, ibm-dropdown", inputs: ["id", "label", "hideLabel", "helperText", "placeholder", "displayValue", "clearText", "size", "type", "theme", "disabled", "readonly", "skeleton", "inline", "disableArrowKeys", "invalid", "invalidText", "warn", "warnText", "appendInline", "scrollableContainer", "itemValueKey", "selectionFeedback", "menuButtonLabel", "selectedLabel", "dropUp", "fluid"], outputs: ["selected", "onClose", "close"] }, { kind: "component", type: i14.DropdownList, selector: "cds-dropdown-list, ibm-dropdown-list", inputs: ["ariaLabel", "items", "listTpl", "type", "showTitles"], outputs: ["select", "scroll", "blurIntent"] }, { kind: "component", type: i9.SearchFieldsComponent, selector: "valtimo-search-fields", inputs: ["loading", "searchFields", "caseDefinitionKey", "setValuesSubject$", "clearValuesSubject$", "defaultValues", "disableSaveSearch", "inputDisabled", "externalSearchField", "canSaveSearch"], outputs: ["doSearch", "saveSearchEvent", "clearEvent"] }, { kind: "component", type: TaskDetailModalComponent, selector: "valtimo-task-detail-modal", inputs: ["modalSize", "openFromCaseManagement"], outputs: ["formSubmit", "assignmentOfTaskChanged", "dueDateChanged", "modalClosed"] }, { kind: "pipe", type: i11.AsyncPipe, name: "async" }, { kind: "pipe", type: i4$1.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
2322
2538
|
}
|
|
2323
2539
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TaskListComponent, decorators: [{
|
|
2324
2540
|
type: Component,
|
|
@@ -2329,10 +2545,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
2329
2545
|
TaskListSortService,
|
|
2330
2546
|
TaskListSearchService,
|
|
2331
2547
|
TaskListQueryParamService,
|
|
2332
|
-
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n 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 overrideSortState: overrideSortState$ | async,\n searchFields: searchFields$ | async,\n loadingSearchFields: loadingSearchFields$ | async,\n caseDefinitionKey: caseDefinitionKey$ | async,\n noResultsMessage: noResultsMessage$ | async,\n } as obs\"\n class=\"main-content\"\n>\n <div class=\"container-fluid\">\n @if (obs.caseDefinitionKey && obs.caseDefinitionKey !== ALL_CASES_ID) {\n <ng-container\n *ngTemplateOutlet=\"\n searchFields;\n context: {\n obs: obs,\n }\n \"\n ></ng-container>\n }\n\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 [attr.data-testid]=\"'task-list-tab-' + tab\"\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 [sortState]=\"obs.overrideSortState || 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]=\"obs.noResultsMessage.description | translate\"\n [title]=\"obs.noResultsMessage.title | 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-template #searchFields let-obs=\"obs\">\n <div class=\"mb-3\">\n <valtimo-search-fields\n [searchFields]=\"obs.searchFields\"\n [inputDisabled]=\"obs.loadingSearchFields\"\n [caseDefinitionKey]=\"obs.caseDefinitionKey\"\n [setValuesSubject$]=\"setSearchFieldValuesSubject$\"\n [clearValuesSubject$]=\"clearSearchFieldValuesSubject$\"\n (doSearch)=\"search($event)\"\n >\n </valtimo-search-fields>\n </div>\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 [attr.data-testid]=\"'task-list-case-dropdown'\"\n [disabled]=\"obs.loadingCaseListItems || (obs.caseListItems || []).length === 1\"\n [skeleton]=\"obs.loadingCaseListItems\"\n (selected)=\"setCaseDefinition($event)\"\n >\n <cds-dropdown-list [items]=\"obs.caseListItems || []\"></cds-dropdown-list>\n </cds-dropdown>\n </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-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
2333
|
-
}], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i2
|
|
2548
|
+
], template: "<!--\n ~ Copyright 2015-2025 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<div\n *ngIf=\"{\n 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 overrideSortState: overrideSortState$ | async,\n searchFields: searchFields$ | async,\n loadingSearchFields: loadingSearchFields$ | async,\n caseDefinitionKey: caseDefinitionKey$ | async,\n noResultsMessage: noResultsMessage$ | async,\n } as obs\"\n class=\"main-content\"\n>\n <div class=\"container-fluid\">\n @if (obs.caseDefinitionKey && obs.caseDefinitionKey !== ALL_CASES_ID) {\n <ng-container\n *ngTemplateOutlet=\"\n searchFields;\n context: {\n obs: obs,\n }\n \"\n ></ng-container>\n }\n\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 (dueDateChanged)=\"reload()\"\n (modalClosed)=\"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 [attr.data-testid]=\"'task-list-tab-' + tab\"\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 #unreadIndicator let-data=\"data\">\n <span *ngIf=\"!data.item?.isOpened\" class=\"valtimo-task-list__unread-dot\"></span>\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 [sortState]=\"obs.overrideSortState || 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]=\"obs.noResultsMessage.description | translate\"\n [title]=\"obs.noResultsMessage.title | 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-template #searchFields let-obs=\"obs\">\n <div class=\"mb-3\">\n <valtimo-search-fields\n [searchFields]=\"obs.searchFields\"\n [inputDisabled]=\"obs.loadingSearchFields\"\n [caseDefinitionKey]=\"obs.caseDefinitionKey\"\n [setValuesSubject$]=\"setSearchFieldValuesSubject$\"\n [clearValuesSubject$]=\"clearSearchFieldValuesSubject$\"\n (doSearch)=\"search($event)\"\n >\n </valtimo-search-fields>\n </div>\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 [attr.data-testid]=\"'task-list-case-dropdown'\"\n [disabled]=\"obs.loadingCaseListItems || (obs.caseListItems || []).length === 1\"\n [skeleton]=\"obs.loadingCaseListItems\"\n (selected)=\"setCaseDefinition($event)\"\n >\n <cds-dropdown-list [items]=\"obs.caseListItems || []\"></cds-dropdown-list>\n </cds-dropdown>\n </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}.valtimo-task-list__unread-dot{display:inline-block;width:8px;height:8px;border-radius:50%;background-color:var(--cds-link-primary)}::ng-deep .valtimo-task-list__unread-column{width:2rem;padding-right:0!important}\n/*!\n * Copyright 2015-2025 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
|
|
2549
|
+
}], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i2.DocumentService }, { type: i3$1.PermissionService }, { type: i1$2.Router }, { type: TaskService }, { type: TaskListService }, { type: i4$1.TranslateService }, { type: TaskListColumnService }, { type: TaskListPaginationService }, { type: TaskListSortService }, { type: TaskListSearchService }, { type: TaskListQueryParamService }, { type: i9.PageTitleService }, { type: i6.SseService }], propDecorators: { _taskDetail: [{
|
|
2334
2550
|
type: ViewChild,
|
|
2335
2551
|
args: ['taskDetail']
|
|
2552
|
+
}], _unreadIndicator: [{
|
|
2553
|
+
type: ViewChild,
|
|
2554
|
+
args: ['unreadIndicator', { static: true }]
|
|
2336
2555
|
}], onPopState: [{
|
|
2337
2556
|
type: HostListener,
|
|
2338
2557
|
args: ['window:popstate', ['$event']]
|
|
@@ -2541,10 +2760,9 @@ class TaskModule {
|
|
|
2541
2760
|
PageHeaderModule,
|
|
2542
2761
|
WidgetModule,
|
|
2543
2762
|
SpinnerModule,
|
|
2544
|
-
SearchableDropdownSelectModule,
|
|
2545
2763
|
CamundaFormModule,
|
|
2546
2764
|
BrowserAnimationsModule,
|
|
2547
|
-
FormsModule, i4.TranslateModule, NgbModule,
|
|
2765
|
+
FormsModule, i4$1.TranslateModule, NgbModule,
|
|
2548
2766
|
FormIoModule,
|
|
2549
2767
|
ModalModule,
|
|
2550
2768
|
LinkModule,
|
|
@@ -2570,7 +2788,6 @@ class TaskModule {
|
|
|
2570
2788
|
PageHeaderModule,
|
|
2571
2789
|
WidgetModule,
|
|
2572
2790
|
SpinnerModule,
|
|
2573
|
-
SearchableDropdownSelectModule,
|
|
2574
2791
|
CamundaFormModule,
|
|
2575
2792
|
BrowserAnimationsModule,
|
|
2576
2793
|
FormsModule,
|
|
@@ -2611,7 +2828,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
2611
2828
|
PageHeaderModule,
|
|
2612
2829
|
WidgetModule,
|
|
2613
2830
|
SpinnerModule,
|
|
2614
|
-
SearchableDropdownSelectModule,
|
|
2615
2831
|
CamundaFormModule,
|
|
2616
2832
|
BrowserAnimationsModule,
|
|
2617
2833
|
FormsModule,
|