@pega/angular-sdk-overrides 0.26.1 → 0.26.3
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/lib/designSystemExtension/alert/alert.component.html +4 -1
- package/lib/designSystemExtension/alert/alert.component.scss +9 -10
- package/lib/designSystemExtension/alert/alert.component.ts +6 -2
- package/lib/designSystemExtension/field-group/field-group.component.ts +11 -3
- package/lib/designSystemExtension/material-case-summary/material-case-summary.component.html +12 -3
- package/lib/designSystemExtension/operator/operator.component.ts +2 -1
- package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.html +104 -10
- package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.scss +141 -1
- package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.ts +224 -72
- package/lib/field/auto-complete/auto-complete.component.html +46 -5
- package/lib/field/auto-complete/auto-complete.component.scss +92 -0
- package/lib/field/auto-complete/auto-complete.component.ts +349 -22
- package/lib/field/cancel-alert/cancel-alert.component.ts +38 -15
- package/lib/field/check-box/check-box.component.html +3 -1
- package/lib/field/check-box/check-box.component.ts +10 -1
- package/lib/field/currency/currency.component.html +2 -1
- package/lib/field/currency/currency.component.ts +10 -1
- package/lib/field/date/date.component.html +2 -1
- package/lib/field/date/date.component.ts +2 -0
- package/lib/field/date-time/date-time.component.html +2 -1
- package/lib/field/date-time/date-time.component.scss +46 -40
- package/lib/field/date-time/date-time.component.ts +2 -0
- package/lib/field/decimal/decimal.component.html +2 -1
- package/lib/field/decimal/decimal.component.ts +2 -0
- package/lib/field/dropdown/dropdown.component.html +2 -1
- package/lib/field/dropdown/dropdown.component.ts +10 -1
- package/lib/field/email/email.component.html +2 -1
- package/lib/field/email/email.component.ts +2 -2
- package/lib/field/field.base.ts +27 -1
- package/lib/field/group/group.component.html +1 -1
- package/lib/field/group/group.component.ts +1 -3
- package/lib/field/integer/integer.component.html +2 -1
- package/lib/field/integer/integer.component.ts +4 -2
- package/lib/field/location/location.component.html +2 -1
- package/lib/field/location/location.component.ts +3 -1
- package/lib/field/object-reference/object-reference.component.html +1 -1
- package/lib/field/object-reference/object-reference.component.ts +3 -0
- package/lib/field/percentage/percentage.component.html +2 -1
- package/lib/field/percentage/percentage.component.ts +10 -1
- package/lib/field/phone/phone.component.html +2 -1
- package/lib/field/phone/phone.component.ts +2 -1
- package/lib/field/radio-buttons/radio-buttons.component.html +2 -1
- package/lib/field/radio-buttons/radio-buttons.component.ts +10 -1
- package/lib/field/rich-text/rich-text.component.scss +1 -166
- package/lib/field/rich-text/rich-text.component.ts +1 -1
- package/lib/field/semantic-link/semantic-link.component.html +1 -1
- package/lib/field/semantic-link/semantic-link.component.scss +4 -0
- package/lib/field/semantic-link/semantic-link.component.ts +9 -5
- package/lib/field/text-area/text-area.component.html +2 -1
- package/lib/field/text-area/text-area.component.ts +2 -1
- package/lib/field/text-input/text-input.component.html +2 -1
- package/lib/field/text-input/text-input.component.ts +2 -1
- package/lib/field/time/time.component.html +2 -1
- package/lib/field/time/time.component.ts +2 -1
- package/lib/field/url/url.component.html +2 -1
- package/lib/field/url/url.component.ts +2 -1
- package/lib/field/user-reference/user-reference.component.html +4 -2
- package/lib/field/user-reference/user-reference.component.ts +10 -5
- package/lib/infra/Containers/flow-container/flow-container.component.html +1 -1
- package/lib/infra/Containers/flow-container/flow-container.component.ts +33 -40
- package/lib/infra/Containers/modal-view-container/data-view-action-buttons/data-view-action-buttons.component.html +12 -0
- package/lib/infra/Containers/modal-view-container/data-view-action-buttons/data-view-action-buttons.component.spec.ts +130 -0
- package/lib/infra/Containers/modal-view-container/data-view-action-buttons/data-view-action-buttons.component.ts +77 -0
- package/lib/infra/Containers/modal-view-container/modal-view-container.component.html +35 -8
- package/lib/infra/Containers/modal-view-container/modal-view-container.component.spec.ts +24 -11
- package/lib/infra/Containers/modal-view-container/modal-view-container.component.ts +185 -194
- package/lib/infra/Containers/view-container/view-container.component.ts +32 -31
- package/lib/infra/assignment/assignment.component.html +2 -1
- package/lib/infra/assignment/assignment.component.ts +30 -13
- package/lib/infra/defer-load/defer-load.component.ts +6 -3
- package/lib/infra/multi-step/multi-step.component.html +25 -33
- package/lib/infra/multi-step/multi-step.component.scss +48 -0
- package/lib/infra/multi-step/multi-step.component.ts +11 -0
- package/lib/infra/navbar/navbar.component.ts +33 -35
- package/lib/infra/root-container/root-container.component.ts +33 -38
- package/lib/infra/view/view.component.ts +17 -39
- package/lib/template/app-shell/app-shell.component.ts +12 -11
- package/lib/template/base/details-template-base.ts +35 -53
- package/lib/template/case-summary/case-summary.component.ts +15 -1
- package/lib/template/case-view/case-view.component.html +13 -1
- package/lib/template/case-view/case-view.component.spec.ts +119 -10
- package/lib/template/case-view/case-view.component.ts +52 -3
- package/lib/template/data-reference/data-reference.component.ts +27 -18
- package/lib/template/data-reference/search-form/search-form.component.html +1 -1
- package/lib/template/data-reference/search-form/search-form.component.ts +2 -0
- package/lib/template/default-form/default-form.component.html +19 -3
- package/lib/template/default-form/default-form.component.ts +13 -3
- package/lib/template/details/details.component.html +23 -3
- package/lib/template/details/details.component.scss +9 -2
- package/lib/template/details/details.component.ts +3 -32
- package/lib/template/details-narrow-wide/details-narrow-wide.component.html +21 -2
- package/lib/template/details-narrow-wide/details-narrow-wide.component.scss +8 -1
- package/lib/template/details-narrow-wide/details-narrow-wide.component.ts +3 -37
- package/lib/template/details-one-column/details-one-column.component.html +23 -1
- package/lib/template/details-one-column/details-one-column.component.scss +14 -0
- package/lib/template/details-one-column/details-one-column.component.ts +3 -38
- package/lib/template/details-three-column/details-three-column.component.html +21 -2
- package/lib/template/details-three-column/details-three-column.component.scss +8 -1
- package/lib/template/details-three-column/details-three-column.component.ts +3 -46
- package/lib/template/details-two-column/details-two-column.component.html +21 -2
- package/lib/template/details-two-column/details-two-column.component.scss +8 -1
- package/lib/template/details-two-column/details-two-column.component.ts +3 -44
- package/lib/template/details-wide-narrow/details-wide-narrow.component.html +21 -2
- package/lib/template/details-wide-narrow/details-wide-narrow.component.scss +8 -1
- package/lib/template/details-wide-narrow/details-wide-narrow.component.ts +3 -41
- package/lib/template/field-value-list/field-value-list.component.scss +17 -0
- package/lib/template/list-view/list-view.component.ts +39 -0
- package/lib/template/self-service-case-view/self-service-case-view.component.html +13 -1
- package/lib/template/self-service-case-view/self-service-case-view.component.spec.ts +96 -11
- package/lib/template/self-service-case-view/self-service-case-view.component.ts +52 -3
- package/lib/template/simple-table-manual/helpers.ts +30 -9
- package/lib/template/simple-table-manual/simple-table-manual.component.html +30 -14
- package/lib/template/simple-table-manual/simple-table-manual.component.scss +4 -0
- package/lib/template/simple-table-manual/simple-table-manual.component.ts +118 -29
- package/lib/template/single-reference-readonly/single-reference-readonly.component.html +1 -1
- package/lib/template/single-reference-readonly/single-reference-readonly.component.scss +2 -2
- package/lib/template/single-reference-readonly/single-reference-readonly.component.ts +4 -4
- package/lib/template/wss-nav-bar/wss-nav-bar.component.ts +18 -20
- package/lib/widget/attachment/AttachmentUtils.ts +18 -10
- package/lib/widget/attachment/attachment.component.html +16 -6
- package/lib/widget/attachment/attachment.component.ts +12 -2
- package/lib/widget/case-history/case-history.component.ts +6 -2
- package/lib/widget/file-utility/file-utility.component.ts +25 -29
- package/lib/widget/todo/todo.component.ts +7 -2
- package/package.json +1 -1
- package/lib/designSystemExtension/material-details/material-details.component.html +0 -40
- package/lib/designSystemExtension/material-details/material-details.component.scss +0 -116
- package/lib/designSystemExtension/material-details/material-details.component.spec.ts +0 -24
- package/lib/designSystemExtension/material-details/material-details.component.ts +0 -31
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.html +0 -41
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.scss +0 -34
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.spec.ts +0 -22
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.ts +0 -61
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component, forwardRef } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
2
3
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
3
4
|
import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
4
5
|
|
|
@@ -6,36 +7,6 @@ import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
|
6
7
|
selector: 'app-details',
|
|
7
8
|
templateUrl: './details.component.html',
|
|
8
9
|
styleUrls: ['./details.component.scss'],
|
|
9
|
-
imports: [forwardRef(() => ComponentMapperComponent)]
|
|
10
|
+
imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
|
|
10
11
|
})
|
|
11
|
-
export class DetailsComponent extends DetailsTemplateBase {
|
|
12
|
-
override pConn$: typeof PConnect;
|
|
13
|
-
|
|
14
|
-
highlightedDataArr: any[] = [];
|
|
15
|
-
showHighlightedData: boolean;
|
|
16
|
-
arFields$: any[] = [];
|
|
17
|
-
|
|
18
|
-
override updateSelf() {
|
|
19
|
-
const rawMetaData: any = this.pConn$.resolveConfigProps(this.pConn$.getRawMetadata()?.config);
|
|
20
|
-
this.showHighlightedData = rawMetaData?.showHighlightedData;
|
|
21
|
-
|
|
22
|
-
if (this.showHighlightedData) {
|
|
23
|
-
const highlightedData = rawMetaData?.highlightedData;
|
|
24
|
-
this.highlightedDataArr = highlightedData.map(field => {
|
|
25
|
-
field.config.displayMode = 'STACKED_LARGE_VAL';
|
|
26
|
-
|
|
27
|
-
if (field.config.value === '@P .pyStatusWork') {
|
|
28
|
-
field.type = 'TextInput';
|
|
29
|
-
field.config.displayAsStatus = true;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
return field;
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
const kids = this.pConn$.getChildren() as any[];
|
|
37
|
-
for (const kid of kids) {
|
|
38
|
-
this.arFields$ = this.processDetailFields(kid);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
}
|
|
12
|
+
export class DetailsComponent extends DetailsTemplateBase {}
|
|
@@ -1,4 +1,23 @@
|
|
|
1
1
|
<component-mapper
|
|
2
|
-
name="
|
|
3
|
-
[props]="{
|
|
2
|
+
name="FieldGroup"
|
|
3
|
+
[props]="{ name: propsToUse.showLabel ? propsToUse.label : '', childrenTemplate: detailsContent }"
|
|
4
4
|
></component-mapper>
|
|
5
|
+
|
|
6
|
+
<ng-template #detailsContent>
|
|
7
|
+
<ng-container *ngIf="showHighlightedData && highlightedDataArr.length > 0">
|
|
8
|
+
<div class="psdk-grid-highlighted">
|
|
9
|
+
<component-mapper
|
|
10
|
+
*ngFor="let field of highlightedDataArr"
|
|
11
|
+
[name]="field.getComponentName()"
|
|
12
|
+
[props]="{ pConn$: field, formGroup$ }"
|
|
13
|
+
></component-mapper>
|
|
14
|
+
</div>
|
|
15
|
+
</ng-container>
|
|
16
|
+
<div class="psdk-grid-filter-narrow-wide">
|
|
17
|
+
<component-mapper
|
|
18
|
+
*ngFor="let child of children"
|
|
19
|
+
[name]="child.getPConnect().getComponentName()"
|
|
20
|
+
[props]="{ pConn$: child.getPConnect(), formGroup$ }"
|
|
21
|
+
></component-mapper>
|
|
22
|
+
</div>
|
|
23
|
+
</ng-template>
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
-
.psdk-grid-filter {
|
|
1
|
+
.psdk-grid-filter-narrow-wide {
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: 3fr 7fr;
|
|
4
4
|
column-gap: calc(2 * 0.5rem);
|
|
5
5
|
row-gap: calc(2 * 0.5rem);
|
|
6
6
|
align-items: start;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
.psdk-grid-highlighted {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-wrap: wrap;
|
|
12
|
+
align-items: flex-start;
|
|
13
|
+
gap: calc(0.5rem) calc(5rem);
|
|
14
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component, forwardRef } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
2
3
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
3
4
|
import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
4
5
|
|
|
@@ -6,41 +7,6 @@ import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
|
6
7
|
selector: 'app-details-narrow-wide',
|
|
7
8
|
templateUrl: './details-narrow-wide.component.html',
|
|
8
9
|
styleUrls: ['./details-narrow-wide.component.scss'],
|
|
9
|
-
imports: [forwardRef(() => ComponentMapperComponent)]
|
|
10
|
+
imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
|
|
10
11
|
})
|
|
11
|
-
export class DetailsNarrowWideComponent extends DetailsTemplateBase {
|
|
12
|
-
override pConn$: typeof PConnect;
|
|
13
|
-
|
|
14
|
-
arFields$: any[] = [];
|
|
15
|
-
arFields2$: any[] = [];
|
|
16
|
-
highlightedDataArr: any[] = [];
|
|
17
|
-
showHighlightedData: boolean;
|
|
18
|
-
|
|
19
|
-
override updateSelf() {
|
|
20
|
-
const rawMetaData: any = this.pConn$.resolveConfigProps(this.pConn$.getRawMetadata()?.config);
|
|
21
|
-
this.showHighlightedData = rawMetaData?.showHighlightedData;
|
|
22
|
-
|
|
23
|
-
if (this.showHighlightedData) {
|
|
24
|
-
const highlightedData = rawMetaData?.highlightedData;
|
|
25
|
-
this.highlightedDataArr = highlightedData.map(field => {
|
|
26
|
-
field.config.displayMode = 'STACKED_LARGE_VAL';
|
|
27
|
-
|
|
28
|
-
if (field.config.value === '@P .pyStatusWork') {
|
|
29
|
-
field.type = 'TextInput';
|
|
30
|
-
field.config.displayAsStatus = true;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
return field;
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
const kids = this.pConn$.getChildren() as any[];
|
|
38
|
-
for (const kid of kids) {
|
|
39
|
-
if (kids.indexOf(kid) == 0) {
|
|
40
|
-
this.arFields$ = this.processDetailFields(kid);
|
|
41
|
-
} else {
|
|
42
|
-
this.arFields2$ = this.processDetailFields(kid);
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
12
|
+
export class DetailsNarrowWideComponent extends DetailsTemplateBase {}
|
|
@@ -1 +1,23 @@
|
|
|
1
|
-
<component-mapper
|
|
1
|
+
<component-mapper
|
|
2
|
+
name="FieldGroup"
|
|
3
|
+
[props]="{ name: propsToUse.showLabel ? propsToUse.label : '', childrenTemplate: detailsContent }"
|
|
4
|
+
></component-mapper>
|
|
5
|
+
|
|
6
|
+
<ng-template #detailsContent>
|
|
7
|
+
<ng-container *ngIf="showHighlightedData && highlightedDataArr.length > 0">
|
|
8
|
+
<div class="psdk-grid-highlighted">
|
|
9
|
+
<component-mapper
|
|
10
|
+
*ngFor="let field of highlightedDataArr"
|
|
11
|
+
[name]="field.getComponentName()"
|
|
12
|
+
[props]="{ pConn$: field, formGroup$ }"
|
|
13
|
+
></component-mapper>
|
|
14
|
+
</div>
|
|
15
|
+
</ng-container>
|
|
16
|
+
<div class="psdk-grid-filter-1">
|
|
17
|
+
<component-mapper
|
|
18
|
+
*ngFor="let child of children"
|
|
19
|
+
[name]="child.getPConnect().getComponentName()"
|
|
20
|
+
[props]="{ pConn$: child.getPConnect(), formGroup$ }"
|
|
21
|
+
></component-mapper>
|
|
22
|
+
</div>
|
|
23
|
+
</ng-template>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
.psdk-grid-filter-1 {
|
|
2
|
+
display: grid;
|
|
3
|
+
grid-template-columns: repeat(1, minmax(0, 1fr));
|
|
4
|
+
column-gap: calc(2 * 0.5rem);
|
|
5
|
+
row-gap: calc(2 * 0.5rem);
|
|
6
|
+
align-items: start;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.psdk-grid-highlighted {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-wrap: wrap;
|
|
12
|
+
align-items: flex-start;
|
|
13
|
+
gap: calc(0.5rem) calc(5rem);
|
|
14
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component, forwardRef } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
2
3
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
3
4
|
import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
4
5
|
|
|
@@ -6,42 +7,6 @@ import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
|
6
7
|
selector: 'app-details-one-column',
|
|
7
8
|
templateUrl: './details-one-column.component.html',
|
|
8
9
|
styleUrls: ['./details-one-column.component.scss'],
|
|
9
|
-
imports: [forwardRef(() => ComponentMapperComponent)]
|
|
10
|
+
imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
|
|
10
11
|
})
|
|
11
|
-
export class DetailsOneColumnComponent extends DetailsTemplateBase {
|
|
12
|
-
override pConn$: typeof PConnect;
|
|
13
|
-
|
|
14
|
-
showHighlightedData: boolean;
|
|
15
|
-
highlightedDataArr: any;
|
|
16
|
-
|
|
17
|
-
arFields$: any[] = [];
|
|
18
|
-
|
|
19
|
-
override updateSelf() {
|
|
20
|
-
const rawMetaData: any = this.pConn$.resolveConfigProps(this.pConn$.getRawMetadata()?.config);
|
|
21
|
-
this.showHighlightedData = rawMetaData?.showHighlightedData;
|
|
22
|
-
|
|
23
|
-
if (this.showHighlightedData) {
|
|
24
|
-
const highlightedData = rawMetaData?.highlightedData;
|
|
25
|
-
this.highlightedDataArr = highlightedData.map(field => {
|
|
26
|
-
field.config.displayMode = 'STACKED_LARGE_VAL';
|
|
27
|
-
|
|
28
|
-
if (field.config.value === '@P .pyStatusWork') {
|
|
29
|
-
field.type = 'TextInput';
|
|
30
|
-
field.config.displayAsStatus = true;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
return field;
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
this.pConn$.setInheritedProp('displayMode', 'DISPLAY_ONLY');
|
|
38
|
-
this.pConn$.setInheritedProp('readOnly', true);
|
|
39
|
-
|
|
40
|
-
const kids = this.pConn$.getChildren() as any[];
|
|
41
|
-
for (const kid of kids) {
|
|
42
|
-
if (kids.indexOf(kid) == 0) {
|
|
43
|
-
this.arFields$ = this.processDetailFields(kid);
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
}
|
|
12
|
+
export class DetailsOneColumnComponent extends DetailsTemplateBase {}
|
|
@@ -1,4 +1,23 @@
|
|
|
1
1
|
<component-mapper
|
|
2
|
-
name="
|
|
3
|
-
[props]="{
|
|
2
|
+
name="FieldGroup"
|
|
3
|
+
[props]="{ name: propsToUse.showLabel ? propsToUse.label : '', childrenTemplate: detailsContent }"
|
|
4
4
|
></component-mapper>
|
|
5
|
+
|
|
6
|
+
<ng-template #detailsContent>
|
|
7
|
+
<ng-container *ngIf="showHighlightedData && highlightedDataArr.length > 0">
|
|
8
|
+
<div class="psdk-grid-highlighted">
|
|
9
|
+
<component-mapper
|
|
10
|
+
*ngFor="let field of highlightedDataArr"
|
|
11
|
+
[name]="field.getComponentName()"
|
|
12
|
+
[props]="{ pConn$: field, formGroup$ }"
|
|
13
|
+
></component-mapper>
|
|
14
|
+
</div>
|
|
15
|
+
</ng-container>
|
|
16
|
+
<div class="psdk-grid-filter-3">
|
|
17
|
+
<component-mapper
|
|
18
|
+
*ngFor="let child of children"
|
|
19
|
+
[name]="child.getPConnect().getComponentName()"
|
|
20
|
+
[props]="{ pConn$: child.getPConnect(), formGroup$ }"
|
|
21
|
+
></component-mapper>
|
|
22
|
+
</div>
|
|
23
|
+
</ng-template>
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
-
.psdk-grid-filter {
|
|
1
|
+
.psdk-grid-filter-3 {
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: repeat(3, minmax(0, 1fr));
|
|
4
4
|
column-gap: calc(2 * 0.5rem);
|
|
5
5
|
row-gap: calc(2 * 0.5rem);
|
|
6
6
|
align-items: start;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
.psdk-grid-highlighted {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-wrap: wrap;
|
|
12
|
+
align-items: flex-start;
|
|
13
|
+
gap: calc(0.5rem) calc(5rem);
|
|
14
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component, forwardRef } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
2
3
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
3
4
|
import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
4
5
|
|
|
@@ -6,50 +7,6 @@ import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
|
6
7
|
selector: 'app-details-three-column',
|
|
7
8
|
templateUrl: './details-three-column.component.html',
|
|
8
9
|
styleUrls: ['./details-three-column.component.scss'],
|
|
9
|
-
imports: [forwardRef(() => ComponentMapperComponent)]
|
|
10
|
+
imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
|
|
10
11
|
})
|
|
11
|
-
export class DetailsThreeColumnComponent extends DetailsTemplateBase {
|
|
12
|
-
override pConn$: typeof PConnect;
|
|
13
|
-
|
|
14
|
-
showHighlightedData: boolean;
|
|
15
|
-
highlightedDataArr: any;
|
|
16
|
-
|
|
17
|
-
arFields$: any[] = [];
|
|
18
|
-
arFields2$: any[] = [];
|
|
19
|
-
arFields3$: any[] = [];
|
|
20
|
-
|
|
21
|
-
propsToUse: any = {};
|
|
22
|
-
|
|
23
|
-
override updateSelf() {
|
|
24
|
-
const rawMetaData: any = this.pConn$.resolveConfigProps(this.pConn$.getRawMetadata()?.config);
|
|
25
|
-
this.showHighlightedData = rawMetaData?.showHighlightedData;
|
|
26
|
-
|
|
27
|
-
if (this.showHighlightedData) {
|
|
28
|
-
const highlightedData = rawMetaData?.highlightedData;
|
|
29
|
-
this.highlightedDataArr = highlightedData.map(field => {
|
|
30
|
-
field.config.displayMode = 'STACKED_LARGE_VAL';
|
|
31
|
-
|
|
32
|
-
if (field.config.value === '@P .pyStatusWork') {
|
|
33
|
-
field.type = 'TextInput';
|
|
34
|
-
field.config.displayAsStatus = true;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
return field;
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
this.pConn$.setInheritedProp('displayMode', 'DISPLAY_ONLY');
|
|
42
|
-
this.pConn$.setInheritedProp('readOnly', true);
|
|
43
|
-
|
|
44
|
-
const kids = this.pConn$.getChildren() as any[];
|
|
45
|
-
for (const kid of kids) {
|
|
46
|
-
if (kids.indexOf(kid) == 0) {
|
|
47
|
-
this.arFields$ = this.processDetailFields(kid);
|
|
48
|
-
} else if (kids.indexOf(kid) == 1) {
|
|
49
|
-
this.arFields2$ = this.processDetailFields(kid);
|
|
50
|
-
} else {
|
|
51
|
-
this.arFields3$ = this.processDetailFields(kid);
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}
|
|
12
|
+
export class DetailsThreeColumnComponent extends DetailsTemplateBase {}
|
|
@@ -1,4 +1,23 @@
|
|
|
1
1
|
<component-mapper
|
|
2
|
-
name="
|
|
3
|
-
[props]="{
|
|
2
|
+
name="FieldGroup"
|
|
3
|
+
[props]="{ name: propsToUse.showLabel ? propsToUse.label : '', childrenTemplate: detailsContent }"
|
|
4
4
|
></component-mapper>
|
|
5
|
+
|
|
6
|
+
<ng-template #detailsContent>
|
|
7
|
+
<ng-container *ngIf="showHighlightedData && highlightedDataArr.length > 0">
|
|
8
|
+
<div class="psdk-grid-highlighted">
|
|
9
|
+
<component-mapper
|
|
10
|
+
*ngFor="let field of highlightedDataArr"
|
|
11
|
+
[name]="field.getComponentName()"
|
|
12
|
+
[props]="{ pConn$: field, formGroup$ }"
|
|
13
|
+
></component-mapper>
|
|
14
|
+
</div>
|
|
15
|
+
</ng-container>
|
|
16
|
+
<div class="psdk-grid-filter-2">
|
|
17
|
+
<component-mapper
|
|
18
|
+
*ngFor="let child of children"
|
|
19
|
+
[name]="child.getPConnect().getComponentName()"
|
|
20
|
+
[props]="{ pConn$: child.getPConnect(), formGroup$ }"
|
|
21
|
+
></component-mapper>
|
|
22
|
+
</div>
|
|
23
|
+
</ng-template>
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
-
.psdk-grid-filter {
|
|
1
|
+
.psdk-grid-filter-2 {
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
4
4
|
column-gap: calc(2 * 0.5rem);
|
|
5
5
|
row-gap: calc(2 * 0.5rem);
|
|
6
6
|
align-items: start;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
.psdk-grid-highlighted {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-wrap: wrap;
|
|
12
|
+
align-items: flex-start;
|
|
13
|
+
gap: calc(0.5rem) calc(5rem);
|
|
14
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component, forwardRef } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
2
3
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
3
4
|
import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
4
5
|
|
|
@@ -6,48 +7,6 @@ import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
|
6
7
|
selector: 'app-details-two-column',
|
|
7
8
|
templateUrl: './details-two-column.component.html',
|
|
8
9
|
styleUrls: ['./details-two-column.component.scss'],
|
|
9
|
-
imports: [forwardRef(() => ComponentMapperComponent)]
|
|
10
|
+
imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
|
|
10
11
|
})
|
|
11
|
-
export class DetailsTwoColumnComponent extends DetailsTemplateBase {
|
|
12
|
-
override pConn$: typeof PConnect;
|
|
13
|
-
|
|
14
|
-
showHighlightedData: boolean;
|
|
15
|
-
highlightedDataArr: any;
|
|
16
|
-
|
|
17
|
-
arFields$: any[] = [];
|
|
18
|
-
arFields2$: any[] = [];
|
|
19
|
-
arFields3$: any[] = [];
|
|
20
|
-
|
|
21
|
-
propsToUse: any = {};
|
|
22
|
-
|
|
23
|
-
override updateSelf() {
|
|
24
|
-
const rawMetaData: any = this.pConn$.resolveConfigProps(this.pConn$.getRawMetadata()?.config);
|
|
25
|
-
this.showHighlightedData = rawMetaData?.showHighlightedData;
|
|
26
|
-
|
|
27
|
-
if (this.showHighlightedData) {
|
|
28
|
-
const highlightedData = rawMetaData?.highlightedData;
|
|
29
|
-
this.highlightedDataArr = highlightedData?.map(field => {
|
|
30
|
-
field.config.displayMode = 'STACKED_LARGE_VAL';
|
|
31
|
-
|
|
32
|
-
if (field.config.value === '@P .pyStatusWork') {
|
|
33
|
-
field.type = 'TextInput';
|
|
34
|
-
field.config.displayAsStatus = true;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
return field;
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
this.pConn$.setInheritedProp('displayMode', 'DISPLAY_ONLY');
|
|
42
|
-
this.pConn$.setInheritedProp('readOnly', true);
|
|
43
|
-
|
|
44
|
-
const kids = this.pConn$.getChildren() as any[];
|
|
45
|
-
for (const kid of kids) {
|
|
46
|
-
if (kids.indexOf(kid) == 0) {
|
|
47
|
-
this.arFields$ = this.processDetailFields(kid);
|
|
48
|
-
} else {
|
|
49
|
-
this.arFields2$ = this.processDetailFields(kid);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
12
|
+
export class DetailsTwoColumnComponent extends DetailsTemplateBase {}
|
|
@@ -1,4 +1,23 @@
|
|
|
1
1
|
<component-mapper
|
|
2
|
-
name="
|
|
3
|
-
[props]="{
|
|
2
|
+
name="FieldGroup"
|
|
3
|
+
[props]="{ name: propsToUse.showLabel ? propsToUse.label : '', childrenTemplate: detailsContent }"
|
|
4
4
|
></component-mapper>
|
|
5
|
+
|
|
6
|
+
<ng-template #detailsContent>
|
|
7
|
+
<ng-container *ngIf="showHighlightedData && highlightedDataArr.length > 0">
|
|
8
|
+
<div class="psdk-grid-highlighted">
|
|
9
|
+
<component-mapper
|
|
10
|
+
*ngFor="let field of highlightedDataArr"
|
|
11
|
+
[name]="field.getComponentName()"
|
|
12
|
+
[props]="{ pConn$: field, formGroup$ }"
|
|
13
|
+
></component-mapper>
|
|
14
|
+
</div>
|
|
15
|
+
</ng-container>
|
|
16
|
+
<div class="psdk-grid-filter-wide-narrow">
|
|
17
|
+
<component-mapper
|
|
18
|
+
*ngFor="let child of children"
|
|
19
|
+
[name]="child.getPConnect().getComponentName()"
|
|
20
|
+
[props]="{ pConn$: child.getPConnect(), formGroup$ }"
|
|
21
|
+
></component-mapper>
|
|
22
|
+
</div>
|
|
23
|
+
</ng-template>
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
-
.psdk-grid-filter {
|
|
1
|
+
.psdk-grid-filter-wide-narrow {
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: 7fr 3fr;
|
|
4
4
|
column-gap: calc(2 * 0.5rem);
|
|
5
5
|
row-gap: calc(2 * 0.5rem);
|
|
6
6
|
align-items: start;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
.psdk-grid-highlighted {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-wrap: wrap;
|
|
12
|
+
align-items: flex-start;
|
|
13
|
+
gap: calc(0.5rem) calc(5rem);
|
|
14
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component, forwardRef } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
2
3
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
3
4
|
import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
4
5
|
|
|
@@ -6,45 +7,6 @@ import { DetailsTemplateBase } from '@pega/angular-sdk-components';
|
|
|
6
7
|
selector: 'app-details-wide-narrow',
|
|
7
8
|
templateUrl: './details-wide-narrow.component.html',
|
|
8
9
|
styleUrls: ['./details-wide-narrow.component.scss'],
|
|
9
|
-
imports: [forwardRef(() => ComponentMapperComponent)]
|
|
10
|
+
imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
|
|
10
11
|
})
|
|
11
|
-
export class DetailsWideNarrowComponent extends DetailsTemplateBase {
|
|
12
|
-
override pConn$: typeof PConnect;
|
|
13
|
-
|
|
14
|
-
highlightedDataArr: any[] = [];
|
|
15
|
-
showHighlightedData: boolean;
|
|
16
|
-
arFields$: any[] = [];
|
|
17
|
-
arFields2$: any[] = [];
|
|
18
|
-
propsToUse: any = {};
|
|
19
|
-
|
|
20
|
-
override updateSelf() {
|
|
21
|
-
const rawMetaData: any = this.pConn$.resolveConfigProps(this.pConn$.getRawMetadata()?.config);
|
|
22
|
-
this.showHighlightedData = rawMetaData?.showHighlightedData;
|
|
23
|
-
|
|
24
|
-
if (this.showHighlightedData) {
|
|
25
|
-
const highlightedData = rawMetaData?.highlightedData;
|
|
26
|
-
this.highlightedDataArr = highlightedData.map(field => {
|
|
27
|
-
field.config.displayMode = 'STACKED_LARGE_VAL';
|
|
28
|
-
|
|
29
|
-
if (field.config.value === '@P .pyStatusWork') {
|
|
30
|
-
field.type = 'TextInput';
|
|
31
|
-
field.config.displayAsStatus = true;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
return field;
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
this.pConn$.setInheritedProp('displayMode', 'DISPLAY_ONLY');
|
|
39
|
-
this.pConn$.setInheritedProp('readOnly', true);
|
|
40
|
-
|
|
41
|
-
const kids = this.pConn$.getChildren() as any[];
|
|
42
|
-
for (const kid of kids) {
|
|
43
|
-
if (kids.indexOf(kid) == 0) {
|
|
44
|
-
this.arFields$ = this.processDetailFields(kid);
|
|
45
|
-
} else {
|
|
46
|
-
this.arFields2$ = this.processDetailFields(kid);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
12
|
+
export class DetailsWideNarrowComponent extends DetailsTemplateBase {}
|
|
@@ -21,3 +21,20 @@
|
|
|
21
21
|
.psdk-val-labels-left {
|
|
22
22
|
white-space: break-spaces;
|
|
23
23
|
}
|
|
24
|
+
|
|
25
|
+
.psdk-container-stacked-large-val {
|
|
26
|
+
margin: 8px 0;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.psdk-container-stacked-large-val .psdk-grid-label {
|
|
30
|
+
color: rgba(0, 0, 0, 0.6);
|
|
31
|
+
font-size: 0.875rem;
|
|
32
|
+
font-weight: 400;
|
|
33
|
+
line-height: 1.5;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.psdk-val-stacked {
|
|
37
|
+
color: rgba(0, 0, 0, 0.87);
|
|
38
|
+
font-size: 1.25rem;
|
|
39
|
+
line-height: 1.5;
|
|
40
|
+
}
|
|
@@ -18,6 +18,7 @@ import { DragDropModule, CdkDragDrop, moveItemInArray, CdkDropList, CdkDrag } fr
|
|
|
18
18
|
import { ProgressSpinnerService } from '@pega/angular-sdk-components';
|
|
19
19
|
import { Utils } from '@pega/angular-sdk-components';
|
|
20
20
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
21
|
+
import { AngularPConnectData, AngularPConnectService } from '@pega/angular-sdk-components';
|
|
21
22
|
import { getCurrencyOptions } from '@pega/angular-sdk-components';
|
|
22
23
|
import { getLocale, getSeconds } from '@pega/angular-sdk-components';
|
|
23
24
|
import { formatters } from '@pega/angular-sdk-components';
|
|
@@ -162,18 +163,28 @@ export class ListViewComponent implements OnInit, OnDestroy {
|
|
|
162
163
|
paging: any;
|
|
163
164
|
fieldDefs: any;
|
|
164
165
|
checkBoxValue: string;
|
|
166
|
+
// Last value seen on the bound property, used to detect external changes.
|
|
167
|
+
lastSelectedPropValue: any;
|
|
165
168
|
label?: string = '';
|
|
166
169
|
uniqueId = crypto.randomUUID();
|
|
167
170
|
displayAs: any;
|
|
168
171
|
showRecords: any;
|
|
169
172
|
identifier: string;
|
|
170
173
|
promotedFiltersId: string;
|
|
174
|
+
|
|
175
|
+
// Used with AngularPConnect
|
|
176
|
+
angularPConnectData: AngularPConnectData = {};
|
|
177
|
+
|
|
171
178
|
constructor(
|
|
179
|
+
private angularPConnect: AngularPConnectService,
|
|
172
180
|
private psService: ProgressSpinnerService,
|
|
173
181
|
public utils: Utils
|
|
174
182
|
) {}
|
|
175
183
|
|
|
176
184
|
ngOnInit(): void {
|
|
185
|
+
// First thing in initialization is registering and subscribing to the AngularPConnect service
|
|
186
|
+
this.angularPConnectData = this.angularPConnect.registerAndSubscribeComponent(this, this.onStateChange);
|
|
187
|
+
|
|
177
188
|
this.configProps$ = this.pConn$.getConfigProps() as ListViewProps;
|
|
178
189
|
/** By default, pyGUID is used for Data classes and pyID is for Work classes as row-id/key */
|
|
179
190
|
const defRowID = this.configProps$?.referenceType === 'Case' ? 'pyID' : 'pyGUID';
|
|
@@ -197,6 +208,7 @@ export class ListViewComponent implements OnInit, OnDestroy {
|
|
|
197
208
|
this.selectionMode = this.configProps$.selectionMode;
|
|
198
209
|
|
|
199
210
|
this.checkBoxValue = this.configProps$.value;
|
|
211
|
+
this.lastSelectedPropValue = this.configProps$.value;
|
|
200
212
|
|
|
201
213
|
this.arFilterMainButtons$.push({ actionID: 'submit', jsAction: 'submit', name: 'Submit' });
|
|
202
214
|
this.arFilterSecondaryButtons$.push({ actionID: 'cancel', jsAction: 'cancel', name: 'Cancel' });
|
|
@@ -266,6 +278,29 @@ export class ListViewComponent implements OnInit, OnDestroy {
|
|
|
266
278
|
this.clearSelectionsAndUpdateTable(this.pConn$, this.uniqueId, this.configProps$?.viewName);
|
|
267
279
|
}
|
|
268
280
|
|
|
281
|
+
onStateChange() {
|
|
282
|
+
// Should always check the bridge to see if the component should
|
|
283
|
+
// update itself (re-render)
|
|
284
|
+
const bUpdateSelf = this.angularPConnect.shouldComponentUpdate(this);
|
|
285
|
+
|
|
286
|
+
// ONLY call updateSelf when the component should update
|
|
287
|
+
if (bUpdateSelf) {
|
|
288
|
+
this.updateSelf();
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
updateSelf(): void {
|
|
293
|
+
// The selected row is driven by the bound property, which another field on the screen may change.
|
|
294
|
+
const latestConfigProps = this.pConn$.getConfigProps() as ListViewProps;
|
|
295
|
+
const latestValue = latestConfigProps?.value;
|
|
296
|
+
|
|
297
|
+
// Only re-sync on an actual property change, so a row the user just picked is not reverted.
|
|
298
|
+
if (this.selectionMode === SELECTION_MODE.SINGLE && latestValue !== this.lastSelectedPropValue) {
|
|
299
|
+
this.lastSelectedPropValue = latestValue;
|
|
300
|
+
this.checkBoxValue = latestValue;
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
|
|
269
304
|
clearSelectionsAndUpdateTable(getPConnect: any, uniqueId: string, viewName): void {
|
|
270
305
|
const clearSelectionsAndRefreshList = ({ viewName: name, clearSelections }: any) => {
|
|
271
306
|
if (name === viewName) {
|
|
@@ -487,6 +522,10 @@ export class ListViewComponent implements OnInit, OnDestroy {
|
|
|
487
522
|
// }
|
|
488
523
|
|
|
489
524
|
ngOnDestroy() {
|
|
525
|
+
if (this.angularPConnectData.unsubscribeFn) {
|
|
526
|
+
this.angularPConnectData.unsubscribeFn();
|
|
527
|
+
}
|
|
528
|
+
|
|
490
529
|
PCore.getPubSubUtils().unsubscribe(
|
|
491
530
|
PCore.getConstants().PUB_SUB_EVENTS.EVENT_DASHBOARD_FILTER_CHANGE,
|
|
492
531
|
`dashboard-component-${'id'}`,
|
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
<div class="psdk-self-service-case-view-header">
|
|
3
3
|
<div class="heading">{{ this.heading$ }}</div>
|
|
4
4
|
<div *ngIf="showCaseActions" class="psdk-case-view-buttons">
|
|
5
|
-
<button mat-raised-button color="secondary" [matMenuTriggerFor]="actionMenu"
|
|
5
|
+
<button mat-raised-button color="secondary" [matMenuTriggerFor]="actionMenu" [disabled]="bActionsMenuDisabled$">
|
|
6
|
+
{{ localizedVal('Actions...', localeCategory) }}
|
|
7
|
+
</button>
|
|
6
8
|
<mat-menu #actionMenu="matMenu" overlapTrigger="false">
|
|
7
9
|
<ng-container *ngFor="let action of arAvailableActions$">
|
|
8
10
|
<button mat-menu-item (click)="_menuActionClick(action)">
|
|
@@ -14,6 +16,16 @@
|
|
|
14
16
|
{{ process.name }}
|
|
15
17
|
</button>
|
|
16
18
|
</ng-container>
|
|
19
|
+
<ng-container *ngFor="let action of arDataObjectActions$">
|
|
20
|
+
<button mat-menu-item (click)="_menuDataObjectActionClick(action)">
|
|
21
|
+
{{ localizedVal(action.name, '', localeKey) }}
|
|
22
|
+
</button>
|
|
23
|
+
</ng-container>
|
|
24
|
+
<ng-container *ngFor="let action of arCreateCaseActions$">
|
|
25
|
+
<button mat-menu-item (click)="_menuCreateCaseActionClick(action)">
|
|
26
|
+
{{ localizedVal(action.name, '', localeKey) }}
|
|
27
|
+
</button>
|
|
28
|
+
</ng-container>
|
|
17
29
|
</mat-menu>
|
|
18
30
|
</div>
|
|
19
31
|
</div>
|