@hmcts/ccd-case-ui-toolkit 7.3.57-exui-3003-3005 → 7.3.57-message-interpolation-01
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/hmcts-ccd-case-ui-toolkit.mjs +70 -155
- package/fesm2022/hmcts-ccd-case-ui-toolkit.mjs.map +1 -1
- package/index.d.ts +14 -30
- package/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -3389,7 +3389,6 @@ class CaseField {
|
|
|
3389
3389
|
acls;
|
|
3390
3390
|
metadata;
|
|
3391
3391
|
formatted_value;
|
|
3392
|
-
hmctsServiceId;
|
|
3393
3392
|
retain_hidden_value;
|
|
3394
3393
|
wizardProps;
|
|
3395
3394
|
_value;
|
|
@@ -3786,7 +3785,6 @@ class CaseView {
|
|
|
3786
3785
|
events;
|
|
3787
3786
|
metadataFields;
|
|
3788
3787
|
basicFields;
|
|
3789
|
-
hmctsServiceId;
|
|
3790
3788
|
case_flag;
|
|
3791
3789
|
}
|
|
3792
3790
|
__decorate([
|
|
@@ -6885,6 +6883,7 @@ class LabelSubstitutorModule {
|
|
|
6885
6883
|
static ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ providers: [
|
|
6886
6884
|
FieldsUtils,
|
|
6887
6885
|
CurrencyPipe,
|
|
6886
|
+
PlaceholderService
|
|
6888
6887
|
] });
|
|
6889
6888
|
}
|
|
6890
6889
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LabelSubstitutorModule, [{
|
|
@@ -6899,6 +6898,7 @@ class LabelSubstitutorModule {
|
|
|
6899
6898
|
providers: [
|
|
6900
6899
|
FieldsUtils,
|
|
6901
6900
|
CurrencyPipe,
|
|
6901
|
+
PlaceholderService
|
|
6902
6902
|
]
|
|
6903
6903
|
}]
|
|
6904
6904
|
}], null, null); })();
|
|
@@ -8938,22 +8938,19 @@ class CaseworkerService {
|
|
|
8938
8938
|
|
|
8939
8939
|
class CaseNotifier {
|
|
8940
8940
|
casesService;
|
|
8941
|
-
caseFlagRefdataService;
|
|
8942
8941
|
static CASE_NAME = 'caseNameHmctsInternal';
|
|
8943
8942
|
static CASE_LOCATION = 'caseManagementLocation';
|
|
8944
8943
|
caseViewSource = new BehaviorSubject(new CaseView());
|
|
8945
|
-
hmctsServiceIdByCaseType = new Map();
|
|
8946
8944
|
caseView = this.caseViewSource.asObservable();
|
|
8947
8945
|
cachedCaseView;
|
|
8948
|
-
constructor(casesService
|
|
8946
|
+
constructor(casesService) {
|
|
8949
8947
|
this.casesService = casesService;
|
|
8950
|
-
this.caseFlagRefdataService = caseFlagRefdataService;
|
|
8951
8948
|
}
|
|
8952
8949
|
removeCachedCase() {
|
|
8953
8950
|
this.cachedCaseView = null;
|
|
8954
8951
|
}
|
|
8955
8952
|
announceCase(c) {
|
|
8956
|
-
this.
|
|
8953
|
+
this.caseViewSource.next(c);
|
|
8957
8954
|
}
|
|
8958
8955
|
fetchAndRefresh(cid) {
|
|
8959
8956
|
return this.casesService
|
|
@@ -8961,10 +8958,8 @@ class CaseNotifier {
|
|
|
8961
8958
|
.pipe(map(caseView => {
|
|
8962
8959
|
this.cachedCaseView = plainToClassFromExist(new CaseView(), caseView);
|
|
8963
8960
|
this.setBasicFields(this.cachedCaseView.tabs);
|
|
8961
|
+
this.announceCase(this.cachedCaseView);
|
|
8964
8962
|
return this.cachedCaseView;
|
|
8965
|
-
}), switchMap(caseView => this.resolveHmctsServiceId(caseView)), map(caseView => {
|
|
8966
|
-
this.announceCase(caseView);
|
|
8967
|
-
return caseView;
|
|
8968
8963
|
}));
|
|
8969
8964
|
}
|
|
8970
8965
|
setBasicFields(tabs) {
|
|
@@ -8979,32 +8974,12 @@ class CaseNotifier {
|
|
|
8979
8974
|
}
|
|
8980
8975
|
});
|
|
8981
8976
|
}
|
|
8982
|
-
|
|
8983
|
-
const caseTypeId = caseView?.case_type?.id;
|
|
8984
|
-
if (!caseTypeId || !this.caseFlagRefdataService) {
|
|
8985
|
-
return of(caseView);
|
|
8986
|
-
}
|
|
8987
|
-
if (this.hmctsServiceIdByCaseType.has(caseTypeId)) {
|
|
8988
|
-
caseView.hmctsServiceId = this.hmctsServiceIdByCaseType.get(caseTypeId);
|
|
8989
|
-
return of(caseView);
|
|
8990
|
-
}
|
|
8991
|
-
return this.caseFlagRefdataService.getHmctsServiceDetailsByCaseType(caseTypeId).pipe(map((serviceDetails) => {
|
|
8992
|
-
const hmctsServiceId = serviceDetails?.find((serviceDetail) => !!serviceDetail.service_code)?.service_code;
|
|
8993
|
-
if (hmctsServiceId) {
|
|
8994
|
-
this.hmctsServiceIdByCaseType.set(caseTypeId, hmctsServiceId);
|
|
8995
|
-
caseView.hmctsServiceId = hmctsServiceId;
|
|
8996
|
-
}
|
|
8997
|
-
return caseView;
|
|
8998
|
-
}), catchError(() => of(caseView)));
|
|
8999
|
-
}
|
|
9000
|
-
static ɵfac = function CaseNotifier_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CaseNotifier)(i0.ɵɵinject(CasesService), i0.ɵɵinject(CaseFlagRefdataService, 8)); };
|
|
8977
|
+
static ɵfac = function CaseNotifier_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CaseNotifier)(i0.ɵɵinject(CasesService)); };
|
|
9001
8978
|
static ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: CaseNotifier, factory: CaseNotifier.ɵfac });
|
|
9002
8979
|
}
|
|
9003
8980
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CaseNotifier, [{
|
|
9004
8981
|
type: Injectable
|
|
9005
|
-
}], () => [{ type: CasesService },
|
|
9006
|
-
type: Optional
|
|
9007
|
-
}] }], null); })();
|
|
8982
|
+
}], () => [{ type: CasesService }], null); })();
|
|
9008
8983
|
|
|
9009
8984
|
var Permissions;
|
|
9010
8985
|
(function (Permissions) {
|
|
@@ -11363,6 +11338,8 @@ class CaseEditPageComponent {
|
|
|
11363
11338
|
dialogRefAfterClosedSub;
|
|
11364
11339
|
saveDraftSub;
|
|
11365
11340
|
caseFormValidationErrorsSub;
|
|
11341
|
+
fieldsUtils = new FieldsUtils();
|
|
11342
|
+
placeholderService = new PlaceholderService();
|
|
11366
11343
|
static scrollToTop() {
|
|
11367
11344
|
window.scrollTo(0, 0);
|
|
11368
11345
|
}
|
|
@@ -11529,7 +11506,7 @@ class CaseEditPageComponent {
|
|
|
11529
11506
|
? group.get(`${casefield.id}_judicialUserControl`)
|
|
11530
11507
|
: group.get(casefield.id);
|
|
11531
11508
|
if (fieldElement) {
|
|
11532
|
-
const label = casefield
|
|
11509
|
+
const label = this.getInterpolatedFieldLabel(casefield);
|
|
11533
11510
|
let id = casefield.id;
|
|
11534
11511
|
if (fieldElement['component'] && fieldElement['component'].parent) {
|
|
11535
11512
|
if (fieldElement['component'].idPrefix.indexOf(`_${id}_`) === -1) {
|
|
@@ -11589,7 +11566,7 @@ class CaseEditPageComponent {
|
|
|
11589
11566
|
});
|
|
11590
11567
|
}
|
|
11591
11568
|
else {
|
|
11592
|
-
this.validationErrors.push({ id, message: `Select or fill the required ${
|
|
11569
|
+
this.validationErrors.push({ id, message: `Select or fill the required ${label} field` });
|
|
11593
11570
|
fieldElement.markAsDirty();
|
|
11594
11571
|
}
|
|
11595
11572
|
}
|
|
@@ -11990,7 +11967,20 @@ class CaseEditPageComponent {
|
|
|
11990
11967
|
});
|
|
11991
11968
|
}
|
|
11992
11969
|
getRpxTranslatePipeArgs(fieldLabel) {
|
|
11993
|
-
return fieldLabel ? ({ FIELDLABEL: fieldLabel }) : null;
|
|
11970
|
+
return fieldLabel ? ({ FIELDLABEL: this.resolveLabelPlaceholders(fieldLabel) }) : null;
|
|
11971
|
+
}
|
|
11972
|
+
getInterpolatedFieldLabel(caseField) {
|
|
11973
|
+
const label = caseField.label || 'Field';
|
|
11974
|
+
return this.resolveLabelPlaceholders(label);
|
|
11975
|
+
}
|
|
11976
|
+
resolveLabelPlaceholders(label) {
|
|
11977
|
+
const dataControl = this.editForm?.controls?.['data'];
|
|
11978
|
+
const formFields = dataControl && typeof dataControl.getRawValue === 'function'
|
|
11979
|
+
? dataControl.getRawValue()
|
|
11980
|
+
: {};
|
|
11981
|
+
const contextFields = this.caseFields?.length ? this.caseFields : this.eventTrigger?.case_fields || [];
|
|
11982
|
+
const fields = this.fieldsUtils.mergeLabelCaseFieldsAndFormFields(contextFields, formFields);
|
|
11983
|
+
return this.placeholderService.resolvePlaceholders(fields, label);
|
|
11994
11984
|
}
|
|
11995
11985
|
onEventCanBeCompleted(eventCanBeCompleted) {
|
|
11996
11986
|
this.caseEdit.onEventCanBeCompleted({
|
|
@@ -12042,7 +12032,7 @@ class CaseEditPageComponent {
|
|
|
12042
12032
|
type: Component,
|
|
12043
12033
|
args: [{ selector: 'ccd-case-edit-page', standalone: false, template: "<ng-container *ngIf=\"currentPage\">\n <h1 *ngIf=\"!currentPage.label\" class=\"govuk-heading-l\">{{eventTrigger.name | rpxTranslate}}</h1>\n <ng-container *ngIf=\"currentPage.label\">\n <span class=\"govuk-caption-l\">{{ eventTrigger.name | rpxTranslate}}</span>\n <h1 class=\"govuk-heading-l\">{{currentPage.label | rpxTranslate}}</h1>\n </ng-container>\n</ng-container>\n\n<!--Case ID or Title -->\n<div *ngIf=\"getCaseTitle(); then titleBlock; else idBlock\"></div>\n<ng-template #titleBlock>\n <ccd-markdown [content]=\"getCaseTitle() | ccdCaseTitle: caseFields : editForm.controls['data'] | rpxTranslate\"></ccd-markdown>\n</ng-template>\n<ng-template #idBlock>\n <h2 *ngIf=\"getCaseId()\" class=\"heading-h2\">#{{ getCaseId() | ccdCaseReference }}</h2>\n</ng-template>\n\n<!-- Error message summary -->\n<div *ngIf=\"validationErrors.length > 0\" class=\"govuk-error-summary\" aria-labelledby=\"error-summary-title\" role=\"alert\" tabindex=\"-1\" data-module=\"govuk-error-summary\">\n <h2 class=\"govuk-error-summary__title\" id=\"error-summary-title\">\n {{'There is a problem' | rpxTranslate}}\n </h2>\n <div *ngFor=\"let validationError of validationErrors\" class=\"govuk-error-summary__body\">\n <ul class=\"govuk-list govuk-error-summary__list\">\n <li>\n <a (click)=\"navigateToErrorElement(validationError.id)\" (keyup.enter)=\"navigateToErrorElement(validationError.id)\" tabindex=\"0\" class=\"validation-error\">\n {{ validationError.message | rpxTranslate: getRpxTranslatePipeArgs(validationError.label | rpxTranslate): null }}\n </a>\n </li>\n </ul>\n </div>\n</div>\n\n<ccd-case-edit-generic-errors [error]=\"caseEdit.error\"></ccd-case-edit-generic-errors>\n\n<ccd-callback-errors\n [triggerTextContinue]=\"triggerTextStart\"\n [triggerTextIgnore]=\"triggerTextIgnoreWarnings\"\n [callbackErrorsSubject]=\"caseEdit.callbackErrorsSubject\"\n (callbackErrorsContext)=\"callbackErrorsNotify($event)\">\n</ccd-callback-errors>\n<div class=\"width-50\">\n <form *ngIf=\"currentPage\" class=\"form\" [formGroup]=\"editForm\" (submit)=\"nextStep()\">\n <fieldset id=\"fieldset-case-data\">\n <legend style=\"display: none;\"></legend>\n <!-- single column -->\n <ccd-case-edit-form id='caseEditForm' *ngIf=\"!currentPage.isMultiColumn()\" [fields]=\"currentPage.getCol1Fields()\"\n [formGroup]=\"editForm.controls['data']\" [caseFields]=\"caseFields\"\n [pageChangeSubject]=\"pageChangeSubject\"\n (valuesChanged)=\"applyValuesChanged($event)\"></ccd-case-edit-form>\n <!-- two columns -->\n <div *ngIf=\"currentPage.isMultiColumn()\" class=\"grid-row\">\n <div class=\"column-two-thirds rightBorderSeparator\">\n <ccd-case-edit-form id='caseEditForm1' [fields]=\"currentPage.getCol1Fields()\"\n [formGroup]=\"editForm.controls['data']\" [caseFields]=\"caseFields\"></ccd-case-edit-form>\n </div>\n <div class=\"column-one-third\">\n <ccd-case-edit-form id='caseEditForm2' [fields]=\"currentPage.getCol2Fields()\"\n [formGroup]=\"editForm.controls['data']\" [caseFields]=\"caseFields\"></ccd-case-edit-form>\n </div>\n </div>\n </fieldset>\n\n <div class=\"form-group form-group-related\">\n <button class=\"button button-secondary\" type=\"button\" (click)=\"toPreviousPage()\" *ngIf=\"!isAtStart()\" [disabled]=\"isDisabled()\">\n {{'Previous' | rpxTranslate}}\n </button>\n <button class=\"button\" type=\"submit\" [disabled]=\"submitting()\">{{triggerText | rpxTranslate}}</button>\n </div>\n\n <p class=\"cancel\"><button type=\"button\" (click)=\"cancel()\" class=\"govuk-js-link\">{{getCancelText() | rpxTranslate}}</button></p>\n </form>\n</div>\n\n<ccd-case-event-completion *ngIf=\"caseEdit.isEventCompletionChecksRequired\"\n [eventCompletionParams]=\"caseEdit.eventCompletionParams\"\n (eventCanBeCompleted)=\"onEventCanBeCompleted($event)\">\n</ccd-case-event-completion>\n", styles: [".rightBorderSeparator{border-right-width:4px;border-right-color:#ffcc02;border-right-style:solid}.validation-error{cursor:pointer;text-decoration:underline;color:#d4351c}\n"] }]
|
|
12044
12034
|
}], () => [{ type: CaseEditComponent }, { type: i1$1.ActivatedRoute }, { type: FormValueService }, { type: FormErrorService }, { type: i0.ChangeDetectorRef }, { type: PageValidationService }, { type: i1$3.MatLegacyDialog }, { type: CaseFieldService }, { type: CaseEditDataService }, { type: LoadingService }, { type: ValidPageListCaseFieldsService }, { type: MultipageComponentStateService }, { type: AddressesService }, { type: LinkedCasesService }, { type: CaseFlagStateService }], null); })();
|
|
12045
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(CaseEditPageComponent, { className: "CaseEditPageComponent", filePath: "lib/shared/components/case-editor/case-edit-page/case-edit-page.component.ts", lineNumber:
|
|
12035
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(CaseEditPageComponent, { className: "CaseEditPageComponent", filePath: "lib/shared/components/case-editor/case-edit-page/case-edit-page.component.ts", lineNumber: 36 }); })();
|
|
12046
12036
|
|
|
12047
12037
|
class CallbackErrorsContext {
|
|
12048
12038
|
triggerText;
|
|
@@ -15567,39 +15557,8 @@ class ReadComplexFieldComponent extends AbstractFieldReadComponent {
|
|
|
15567
15557
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ReadComplexFieldComponent, { className: "ReadComplexFieldComponent", filePath: "lib/shared/components/palette/complex/read-complex-field.component.ts", lineNumber: 11 }); })();
|
|
15568
15558
|
|
|
15569
15559
|
class ReadDateFieldComponent extends AbstractFieldReadComponent {
|
|
15570
|
-
|
|
15571
|
-
static
|
|
15572
|
-
caseSubscription;
|
|
15573
|
-
caseHmctsServiceId;
|
|
15574
|
-
constructor(caseNotifier) {
|
|
15575
|
-
super();
|
|
15576
|
-
this.caseNotifier = caseNotifier;
|
|
15577
|
-
}
|
|
15578
|
-
ngOnInit() {
|
|
15579
|
-
super.ngOnInit();
|
|
15580
|
-
this.caseSubscription = this.caseNotifier?.caseView.subscribe((caseDetails) => {
|
|
15581
|
-
this.caseHmctsServiceId = caseDetails?.hmctsServiceId;
|
|
15582
|
-
});
|
|
15583
|
-
}
|
|
15584
|
-
ngOnDestroy() {
|
|
15585
|
-
if (this.caseSubscription) {
|
|
15586
|
-
this.caseSubscription.unsubscribe();
|
|
15587
|
-
}
|
|
15588
|
-
}
|
|
15589
|
-
// Most services display DateTime values as received from CCD; only the services listed in SERVICES_RENDERED_IN_LOCAL_TIME need converting to local time.
|
|
15590
|
-
get timeZone() {
|
|
15591
|
-
return this.shouldRenderInLocalTime() ? 'local' : 'utc';
|
|
15592
|
-
}
|
|
15593
|
-
shouldRenderInLocalTime() {
|
|
15594
|
-
return ReadDateFieldComponent.SERVICES_RENDERED_IN_LOCAL_TIME.includes(this.getHmctsServiceId());
|
|
15595
|
-
}
|
|
15596
|
-
getHmctsServiceId() {
|
|
15597
|
-
if (typeof this.caseField?.hmctsServiceId === 'string') {
|
|
15598
|
-
return this.caseField.hmctsServiceId;
|
|
15599
|
-
}
|
|
15600
|
-
return this.caseHmctsServiceId;
|
|
15601
|
-
}
|
|
15602
|
-
static ɵfac = function ReadDateFieldComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ReadDateFieldComponent)(i0.ɵɵdirectiveInject(CaseNotifier, 8)); };
|
|
15560
|
+
timeZone = 'utc';
|
|
15561
|
+
static ɵfac = /*@__PURE__*/ (() => { let ɵReadDateFieldComponent_BaseFactory; return function ReadDateFieldComponent_Factory(__ngFactoryType__) { return (ɵReadDateFieldComponent_BaseFactory || (ɵReadDateFieldComponent_BaseFactory = i0.ɵɵgetInheritedFactory(ReadDateFieldComponent)))(__ngFactoryType__ || ReadDateFieldComponent); }; })();
|
|
15603
15562
|
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ReadDateFieldComponent, selectors: [["ccd-read-date-field"]], standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 5, consts: [[1, "text-16"]], template: function ReadDateFieldComponent_Template(rf, ctx) { if (rf & 1) {
|
|
15604
15563
|
i0.ɵɵelementStart(0, "span", 0);
|
|
15605
15564
|
i0.ɵɵtext(1);
|
|
@@ -15607,20 +15566,18 @@ class ReadDateFieldComponent extends AbstractFieldReadComponent {
|
|
|
15607
15566
|
i0.ɵɵelementEnd();
|
|
15608
15567
|
} if (rf & 2) {
|
|
15609
15568
|
i0.ɵɵadvance();
|
|
15610
|
-
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind3(2, 1, ctx.caseField.value,
|
|
15569
|
+
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind3(2, 1, ctx.caseField.value, "utc", ctx.caseField.dateTimeDisplayFormat));
|
|
15611
15570
|
} }, dependencies: [DatePipe], encapsulation: 2 });
|
|
15612
15571
|
}
|
|
15613
15572
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReadDateFieldComponent, [{
|
|
15614
15573
|
type: Component,
|
|
15615
15574
|
args: [{
|
|
15616
15575
|
selector: 'ccd-read-date-field',
|
|
15617
|
-
template: `<span class="text-16">{{caseField.value | ccdDate:
|
|
15576
|
+
template: `<span class="text-16">{{caseField.value | ccdDate:'utc':caseField.dateTimeDisplayFormat}}</span>`,
|
|
15618
15577
|
standalone: false
|
|
15619
15578
|
}]
|
|
15620
|
-
}],
|
|
15621
|
-
|
|
15622
|
-
}] }], null); })();
|
|
15623
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ReadDateFieldComponent, { className: "ReadDateFieldComponent", filePath: "lib/shared/components/palette/date/read-date-field.component.ts", lineNumber: 12 }); })();
|
|
15579
|
+
}], null, null); })();
|
|
15580
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ReadDateFieldComponent, { className: "ReadDateFieldComponent", filePath: "lib/shared/components/palette/date/read-date-field.component.ts", lineNumber: 9 }); })();
|
|
15624
15581
|
|
|
15625
15582
|
function WriteDateContainerFieldComponent_ng_container_0_Template(rf, ctx) { if (rf & 1) {
|
|
15626
15583
|
i0.ɵɵelementContainerStart(0);
|
|
@@ -29504,22 +29461,24 @@ class UpdateFlagTitleDisplayPipe extends AsyncPipe {
|
|
|
29504
29461
|
|
|
29505
29462
|
const _c0$l = (a0, a1, a2) => [a0, false, undefined, true, a1, a2];
|
|
29506
29463
|
function ReadComplexFieldRawComponent_ng_container_1_Template(rf, ctx) { if (rf & 1) {
|
|
29507
|
-
i0.ɵɵelementContainerStart(0);
|
|
29508
|
-
i0.ɵɵelementStart(
|
|
29509
|
-
i0.ɵɵtext(
|
|
29510
|
-
i0.ɵɵpipe(
|
|
29464
|
+
i0.ɵɵelementContainerStart(0)(1, 2);
|
|
29465
|
+
i0.ɵɵelementStart(2, "dt", 3)(3, "span", 4);
|
|
29466
|
+
i0.ɵɵtext(4);
|
|
29467
|
+
i0.ɵɵpipe(5, "rpxTranslate");
|
|
29511
29468
|
i0.ɵɵelementEnd()();
|
|
29512
|
-
i0.ɵɵelementStart(
|
|
29513
|
-
i0.ɵɵelement(
|
|
29469
|
+
i0.ɵɵelementStart(6, "dd", 3);
|
|
29470
|
+
i0.ɵɵelement(7, "ccd-field-read", 5);
|
|
29514
29471
|
i0.ɵɵelementEnd();
|
|
29515
|
-
i0.ɵɵelementContainerEnd();
|
|
29472
|
+
i0.ɵɵelementContainerEnd()();
|
|
29516
29473
|
} if (rf & 2) {
|
|
29517
29474
|
const field_r1 = ctx.$implicit;
|
|
29518
29475
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
29519
29476
|
i0.ɵɵadvance();
|
|
29477
|
+
i0.ɵɵproperty("caseField", field_r1)("formGroup", ctx_r1.topLevelFormGroup)("contextFields", ctx_r1.caseFields);
|
|
29478
|
+
i0.ɵɵadvance();
|
|
29520
29479
|
i0.ɵɵproperty("hidden", field_r1.hidden || field_r1.field_type.type === "Label");
|
|
29521
29480
|
i0.ɵɵadvance(2);
|
|
29522
|
-
i0.ɵɵtextInterpolate(ctx_r1.isTranslatable(field_r1) ? i0.ɵɵpipeBind1(
|
|
29481
|
+
i0.ɵɵtextInterpolate(ctx_r1.isTranslatable(field_r1) ? i0.ɵɵpipeBind1(5, 11, field_r1.label) : field_r1.label);
|
|
29523
29482
|
i0.ɵɵadvance(2);
|
|
29524
29483
|
i0.ɵɵproperty("hidden", field_r1.hidden);
|
|
29525
29484
|
i0.ɵɵadvance();
|
|
@@ -29532,9 +29491,9 @@ function ReadComplexFieldRawComponent_ng_container_1_Template(rf, ctx) { if (rf
|
|
|
29532
29491
|
class ReadComplexFieldRawComponent extends AbstractFieldReadComponent {
|
|
29533
29492
|
caseFields = [];
|
|
29534
29493
|
static ɵfac = /*@__PURE__*/ (() => { let ɵReadComplexFieldRawComponent_BaseFactory; return function ReadComplexFieldRawComponent_Factory(__ngFactoryType__) { return (ɵReadComplexFieldRawComponent_BaseFactory || (ɵReadComplexFieldRawComponent_BaseFactory = i0.ɵɵgetInheritedFactory(ReadComplexFieldRawComponent)))(__ngFactoryType__ || ReadComplexFieldRawComponent); }; })();
|
|
29535
|
-
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ReadComplexFieldRawComponent, selectors: [["ccd-read-complex-field-raw"]], inputs: { caseFields: "caseFields" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 12, consts: [[1, "complex-raw"], [4, "ngFor", "ngForOf"], [3, "hidden"], [1, "text-16"], [3, "caseField", "context", "caseFields", "topLevelFormGroup", "idPrefix"]], template: function ReadComplexFieldRawComponent_Template(rf, ctx) { if (rf & 1) {
|
|
29494
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ReadComplexFieldRawComponent, selectors: [["ccd-read-complex-field-raw"]], inputs: { caseFields: "caseFields" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 12, consts: [[1, "complex-raw"], [4, "ngFor", "ngForOf"], ["ccdLabelSubstitutor", "", 3, "caseField", "formGroup", "contextFields"], [3, "hidden"], [1, "text-16"], [3, "caseField", "context", "caseFields", "topLevelFormGroup", "idPrefix"]], template: function ReadComplexFieldRawComponent_Template(rf, ctx) { if (rf & 1) {
|
|
29536
29495
|
i0.ɵɵelementStart(0, "dl", 0);
|
|
29537
|
-
i0.ɵɵtemplate(1, ReadComplexFieldRawComponent_ng_container_1_Template,
|
|
29496
|
+
i0.ɵɵtemplate(1, ReadComplexFieldRawComponent_ng_container_1_Template, 8, 13, "ng-container", 1);
|
|
29538
29497
|
i0.ɵɵpipe(2, "ccdReadFieldsFilter");
|
|
29539
29498
|
i0.ɵɵelementEnd();
|
|
29540
29499
|
} if (rf & 2) {
|
|
@@ -29544,17 +29503,17 @@ class ReadComplexFieldRawComponent extends AbstractFieldReadComponent {
|
|
|
29544
29503
|
}
|
|
29545
29504
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReadComplexFieldRawComponent, [{
|
|
29546
29505
|
type: Component,
|
|
29547
|
-
args: [{ selector: 'ccd-read-complex-field-raw', standalone: false, template: "<dl class=\"complex-raw\">\n <ng-container *ngFor=\"let field of caseField | ccdReadFieldsFilter:false :undefined :true :topLevelFormGroup :id()\">\n <dt [hidden]=\"field.hidden || field.field_type.type === 'Label'\"><span class=\"text-16\">{{isTranslatable(field) ? (field.label | rpxTranslate) : field.label}}</span></dt>\n
|
|
29506
|
+
args: [{ selector: 'ccd-read-complex-field-raw', standalone: false, template: "<dl class=\"complex-raw\">\n <ng-container *ngFor=\"let field of caseField | ccdReadFieldsFilter:false :undefined :true :topLevelFormGroup :id()\">\n <ng-container ccdLabelSubstitutor [caseField]=\"field\" [formGroup]=\"topLevelFormGroup\" [contextFields]=\"caseFields\">\n <dt [hidden]=\"field.hidden || field.field_type.type === 'Label'\"><span class=\"text-16\">{{isTranslatable(field) ? (field.label | rpxTranslate) : field.label}}</span></dt>\n <dd [hidden]=\"field.hidden\">\n <ccd-field-read [caseField]=\"field\" [context]=\"context\" [caseFields]=\"caseFields\" [topLevelFormGroup]=\"topLevelFormGroup\" [idPrefix]=\"idPrefix\"></ccd-field-read>\n </dd>\n </ng-container>\n </ng-container>\n</dl>\n", styles: ["dl.complex-raw{list-style-type:none;margin:5px 0 10px}dl.complex-raw dl.complex-raw{padding-left:2ch}dl.complex-raw dt{font-weight:700}\n"] }]
|
|
29548
29507
|
}], null, { caseFields: [{
|
|
29549
29508
|
type: Input
|
|
29550
29509
|
}] }); })();
|
|
29551
29510
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ReadComplexFieldRawComponent, { className: "ReadComplexFieldRawComponent", filePath: "lib/shared/components/palette/complex/read-complex-field-raw.component.ts", lineNumber: 17 }); })();
|
|
29552
29511
|
|
|
29553
29512
|
const _c0$k = (a0, a1, a2, a3) => [a0, false, undefined, true, a1, a2, a3];
|
|
29554
|
-
function
|
|
29513
|
+
function ReadComplexFieldTableComponent_ng_container_9_ng_container_2_Template(rf, ctx) { if (rf & 1) {
|
|
29555
29514
|
i0.ɵɵelementContainerStart(0);
|
|
29556
|
-
i0.ɵɵelementStart(1, "tr",
|
|
29557
|
-
i0.ɵɵelement(4, "ccd-field-read",
|
|
29515
|
+
i0.ɵɵelementStart(1, "tr", 8)(2, "td", 9)(3, "span", 3);
|
|
29516
|
+
i0.ɵɵelement(4, "ccd-field-read", 10);
|
|
29558
29517
|
i0.ɵɵelementEnd()()();
|
|
29559
29518
|
i0.ɵɵelementContainerEnd();
|
|
29560
29519
|
} if (rf & 2) {
|
|
@@ -29565,13 +29524,13 @@ function ReadComplexFieldTableComponent_ng_container_9_ng_container_1_Template(r
|
|
|
29565
29524
|
i0.ɵɵadvance(3);
|
|
29566
29525
|
i0.ɵɵproperty("topLevelFormGroup", ctx_r1.topLevelFormGroup)("caseFields", ctx_r1.caseFields)("caseField", field_r1)("context", ctx_r1.context);
|
|
29567
29526
|
} }
|
|
29568
|
-
function
|
|
29569
|
-
i0.ɵɵelementStart(0, "tr",
|
|
29527
|
+
function ReadComplexFieldTableComponent_ng_container_9_ng_template_4_Template(rf, ctx) { if (rf & 1) {
|
|
29528
|
+
i0.ɵɵelementStart(0, "tr", 11)(1, "th", 12)(2, "span", 3);
|
|
29570
29529
|
i0.ɵɵtext(3);
|
|
29571
29530
|
i0.ɵɵpipe(4, "rpxTranslate");
|
|
29572
29531
|
i0.ɵɵelementEnd()();
|
|
29573
29532
|
i0.ɵɵelementStart(5, "td")(6, "span", 3);
|
|
29574
|
-
i0.ɵɵelement(7, "ccd-field-read",
|
|
29533
|
+
i0.ɵɵelement(7, "ccd-field-read", 10);
|
|
29575
29534
|
i0.ɵɵelementEnd()()();
|
|
29576
29535
|
} if (rf & 2) {
|
|
29577
29536
|
const field_r1 = i0.ɵɵnextContext().$implicit;
|
|
@@ -29583,16 +29542,19 @@ function ReadComplexFieldTableComponent_ng_container_9_ng_template_3_Template(rf
|
|
|
29583
29542
|
i0.ɵɵproperty("topLevelFormGroup", ctx_r1.topLevelFormGroup)("caseFields", ctx_r1.caseFields)("caseField", field_r1)("context", ctx_r1.context);
|
|
29584
29543
|
} }
|
|
29585
29544
|
function ReadComplexFieldTableComponent_ng_container_9_Template(rf, ctx) { if (rf & 1) {
|
|
29586
|
-
i0.ɵɵelementContainerStart(0);
|
|
29587
|
-
i0.ɵɵtemplate(
|
|
29588
|
-
i0.ɵɵpipe(
|
|
29589
|
-
i0.ɵɵtemplate(
|
|
29590
|
-
i0.ɵɵelementContainerEnd();
|
|
29545
|
+
i0.ɵɵelementContainerStart(0)(1, 6);
|
|
29546
|
+
i0.ɵɵtemplate(2, ReadComplexFieldTableComponent_ng_container_9_ng_container_2_Template, 5, 5, "ng-container", 7);
|
|
29547
|
+
i0.ɵɵpipe(3, "ccdIsCompound");
|
|
29548
|
+
i0.ɵɵtemplate(4, ReadComplexFieldTableComponent_ng_container_9_ng_template_4_Template, 8, 8, "ng-template", null, 0, i0.ɵɵtemplateRefExtractor);
|
|
29549
|
+
i0.ɵɵelementContainerEnd()();
|
|
29591
29550
|
} if (rf & 2) {
|
|
29592
29551
|
const field_r1 = ctx.$implicit;
|
|
29593
|
-
const SimpleRow_r3 = i0.ɵɵreference(
|
|
29552
|
+
const SimpleRow_r3 = i0.ɵɵreference(5);
|
|
29553
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
29554
|
+
i0.ɵɵadvance();
|
|
29555
|
+
i0.ɵɵproperty("caseField", field_r1)("formGroup", ctx_r1.topLevelFormGroup)("contextFields", ctx_r1.caseFields);
|
|
29594
29556
|
i0.ɵɵadvance();
|
|
29595
|
-
i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(
|
|
29557
|
+
i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(3, 5, field_r1))("ngIfElse", SimpleRow_r3);
|
|
29596
29558
|
} }
|
|
29597
29559
|
class ReadComplexFieldTableComponent extends AbstractFieldReadComponent {
|
|
29598
29560
|
// parent_ can be replaced with any ***_ - underscore is only important character
|
|
@@ -29613,7 +29575,7 @@ class ReadComplexFieldTableComponent extends AbstractFieldReadComponent {
|
|
|
29613
29575
|
this.path = ReadComplexFieldTableComponent.DUMMY_STRING_PRE + this.idPrefix + ReadComplexFieldTableComponent.DUMMY_STRING_POST;
|
|
29614
29576
|
}
|
|
29615
29577
|
static ɵfac = /*@__PURE__*/ (() => { let ɵReadComplexFieldTableComponent_BaseFactory; return function ReadComplexFieldTableComponent_Factory(__ngFactoryType__) { return (ɵReadComplexFieldTableComponent_BaseFactory || (ɵReadComplexFieldTableComponent_BaseFactory = i0.ɵɵgetInheritedFactory(ReadComplexFieldTableComponent)))(__ngFactoryType__ || ReadComplexFieldTableComponent); }; })();
|
|
29616
|
-
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ReadComplexFieldTableComponent, selectors: [["ccd-read-complex-field-table"]], inputs: { caseFields: "caseFields" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 11, vars: 17, consts: [["SimpleRow", ""], [1, "complex-panel"], [1, "complex-panel-title"], [1, "text-16"], ["aria-describedby", "complex field table", 1, "complex-panel-table"], [4, "ngFor", "ngForOf"], [4, "ngIf", "ngIfElse"], [1, "complex-panel-compound-field", 3, "hidden"], ["colspan", "2"], [3, "topLevelFormGroup", "caseFields", "caseField", "context"], [1, "complex-panel-simple-field", 3, "hidden"], ["id", "complex-panel-simple-field-label"]], template: function ReadComplexFieldTableComponent_Template(rf, ctx) { if (rf & 1) {
|
|
29578
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ReadComplexFieldTableComponent, selectors: [["ccd-read-complex-field-table"]], inputs: { caseFields: "caseFields" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 11, vars: 17, consts: [["SimpleRow", ""], [1, "complex-panel"], [1, "complex-panel-title"], [1, "text-16"], ["aria-describedby", "complex field table", 1, "complex-panel-table"], [4, "ngFor", "ngForOf"], ["ccdLabelSubstitutor", "", 3, "caseField", "formGroup", "contextFields"], [4, "ngIf", "ngIfElse"], [1, "complex-panel-compound-field", 3, "hidden"], ["colspan", "2"], [3, "topLevelFormGroup", "caseFields", "caseField", "context"], [1, "complex-panel-simple-field", 3, "hidden"], ["id", "complex-panel-simple-field-label"]], template: function ReadComplexFieldTableComponent_Template(rf, ctx) { if (rf & 1) {
|
|
29617
29579
|
i0.ɵɵelementStart(0, "div", 1)(1, "dl", 2)(2, "dt")(3, "span", 3);
|
|
29618
29580
|
i0.ɵɵtext(4);
|
|
29619
29581
|
i0.ɵɵpipe(5, "rpxTranslate");
|
|
@@ -29621,7 +29583,7 @@ class ReadComplexFieldTableComponent extends AbstractFieldReadComponent {
|
|
|
29621
29583
|
i0.ɵɵelement(6, "dd");
|
|
29622
29584
|
i0.ɵɵelementEnd();
|
|
29623
29585
|
i0.ɵɵelementStart(7, "table", 4)(8, "tbody");
|
|
29624
|
-
i0.ɵɵtemplate(9, ReadComplexFieldTableComponent_ng_container_9_Template,
|
|
29586
|
+
i0.ɵɵtemplate(9, ReadComplexFieldTableComponent_ng_container_9_Template, 6, 7, "ng-container", 5);
|
|
29625
29587
|
i0.ɵɵpipe(10, "ccdReadFieldsFilter");
|
|
29626
29588
|
i0.ɵɵelementEnd()()();
|
|
29627
29589
|
} if (rf & 2) {
|
|
@@ -29633,7 +29595,7 @@ class ReadComplexFieldTableComponent extends AbstractFieldReadComponent {
|
|
|
29633
29595
|
}
|
|
29634
29596
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReadComplexFieldTableComponent, [{
|
|
29635
29597
|
type: Component,
|
|
29636
|
-
args: [{ selector: 'ccd-read-complex-field-table', standalone: false, template: "<div class=\"complex-panel\">\n <dl class=\"complex-panel-title\"><dt><span class=\"text-16\">{{caseField.label | rpxTranslate}}</span></dt><dd></dd></dl>\n <table class=\"complex-panel-table\" aria-describedby=\"complex field table\">\n <tbody>\n <ng-container *ngFor=\"let field of caseField | ccdReadFieldsFilter:false :undefined :true :topLevelFormGroup :path :idPrefix\">\n <ng-container *ngIf=\"(field | ccdIsCompound); else SimpleRow\">\n
|
|
29598
|
+
args: [{ selector: 'ccd-read-complex-field-table', standalone: false, template: "<div class=\"complex-panel\">\n <dl class=\"complex-panel-title\"><dt><span class=\"text-16\">{{caseField.label | rpxTranslate}}</span></dt><dd></dd></dl>\n <table class=\"complex-panel-table\" aria-describedby=\"complex field table\">\n <tbody>\n <ng-container *ngFor=\"let field of caseField | ccdReadFieldsFilter:false :undefined :true :topLevelFormGroup :path :idPrefix\">\n <ng-container ccdLabelSubstitutor [caseField]=\"field\" [formGroup]=\"topLevelFormGroup\" [contextFields]=\"caseFields\">\n <ng-container *ngIf=\"(field | ccdIsCompound); else SimpleRow\">\n <tr class=\"complex-panel-compound-field\" [hidden]=\"field.hidden\">\n <td colspan=\"2\">\n <span class=\"text-16\">\n <ccd-field-read [topLevelFormGroup]=\"topLevelFormGroup\" [caseFields]=\"caseFields\"\n [caseField]=\"field\" [context]=\"context\"></ccd-field-read>\n </span>\n </td>\n </tr>\n </ng-container>\n <ng-template #SimpleRow>\n <tr class=\"complex-panel-simple-field\" [hidden]=\"field.hidden\">\n <th id=\"complex-panel-simple-field-label\"><span class=\"text-16\">{{field.label | rpxTranslate}}</span></th>\n <td>\n <span class=\"text-16\">\n <ccd-field-read [topLevelFormGroup]=\"topLevelFormGroup\" [caseFields]=\"caseFields\"\n [caseField]=\"field\" [context]=\"context\"></ccd-field-read>\n </span>\n </td>\n </tr>\n </ng-template>\n </ng-container>\n </ng-container>\n </tbody>\n </table>\n</div>\n", styles: [".complex-panel{margin:13px 0;border:1px solid #bfc1c3}.complex-panel .complex-panel-title{background-color:#dee0e2;padding:5px 5px 2px;border-bottom:1px solid #bfc1c3;display:block;color:#0b0c0c;font-family:nta,Arial,sans-serif;font-weight:700;text-transform:none;font-size:16px;line-height:1.25}@media(min-width:641px){.complex-panel .complex-panel-title{font-size:19px;line-height:1.3157894737}}.complex-panel .complex-panel-table>tbody>tr>th{vertical-align:top}.complex-panel .complex-panel-table>tbody>tr:last-child>th,.complex-panel .complex-panel-table>tbody>tr:last-child>td{border-bottom:none}.complex-panel .complex-panel-simple-field th{padding-left:5px;width:295px}.complex-panel .complex-panel-compound-field td{padding:5px}\n"] }]
|
|
29637
29599
|
}], null, { caseFields: [{
|
|
29638
29600
|
type: Input
|
|
29639
29601
|
}] }); })();
|
|
@@ -32415,8 +32377,8 @@ i0.ɵɵsetComponentScope(ReadOrderSummaryRowComponent, function () { return [Rea
|
|
|
32415
32377
|
i0.ɵɵsetComponentScope(ReadComplexFieldComponent, function () { return [i5.NgSwitch, i5.NgSwitchCase, i5.NgSwitchDefault, ReadComplexFieldRawComponent,
|
|
32416
32378
|
ReadComplexFieldTableComponent,
|
|
32417
32379
|
ReadComplexFieldCollectionTableComponent]; }, []);
|
|
32418
|
-
i0.ɵɵsetComponentScope(ReadComplexFieldRawComponent, function () { return [i5.NgForOf, FieldReadComponent]; }, function () { return [ReadFieldsFilterPipe, i1.RpxTranslatePipe]; });
|
|
32419
|
-
i0.ɵɵsetComponentScope(ReadComplexFieldTableComponent, function () { return [i5.NgForOf, i5.NgIf, FieldReadComponent]; }, function () { return [IsCompoundPipe, ReadFieldsFilterPipe, i1.RpxTranslatePipe]; });
|
|
32380
|
+
i0.ɵɵsetComponentScope(ReadComplexFieldRawComponent, function () { return [i5.NgForOf, i4.NgControlStatusGroup, i4.FormGroupDirective, LabelSubstitutorDirective, FieldReadComponent]; }, function () { return [ReadFieldsFilterPipe, i1.RpxTranslatePipe]; });
|
|
32381
|
+
i0.ɵɵsetComponentScope(ReadComplexFieldTableComponent, function () { return [i5.NgForOf, i5.NgIf, i4.NgControlStatusGroup, i4.FormGroupDirective, LabelSubstitutorDirective, FieldReadComponent]; }, function () { return [IsCompoundPipe, ReadFieldsFilterPipe, i1.RpxTranslatePipe]; });
|
|
32420
32382
|
i0.ɵɵsetComponentScope(ReadComplexFieldCollectionTableComponent, function () { return [i5.NgForOf, i5.NgIf, FieldReadComponent,
|
|
32421
32383
|
ReadCaseLinkFieldComponent]; }, function () { return [i5.KeyValuePipe, IsCompoundPipe, CcdCollectionTableCaseFieldsFilterPipe, ReadFieldsFilterPipe, i1.RpxTranslatePipe]; });
|
|
32422
32384
|
i0.ɵɵsetComponentScope(ReadCaseFlagFieldComponent, function () { return [i5.NgForOf, i5.NgIf, i5.NgSwitch, i5.NgSwitchCase, i5.NgSwitchDefault,
|
|
@@ -41001,7 +40963,6 @@ class SearchResultComponent {
|
|
|
41001
40963
|
placeholderService;
|
|
41002
40964
|
browserService;
|
|
41003
40965
|
sessionStorageService;
|
|
41004
|
-
caseFlagRefdataService;
|
|
41005
40966
|
static PARAM_JURISDICTION = 'jurisdiction';
|
|
41006
40967
|
static PARAM_CASE_TYPE = 'case-type';
|
|
41007
40968
|
static PARAM_CASE_STATE = 'case-state';
|
|
@@ -41033,15 +40994,12 @@ class SearchResultComponent {
|
|
|
41033
40994
|
draftsCount;
|
|
41034
40995
|
consumerSortParameters = { column: null, order: null, type: null };
|
|
41035
40996
|
selectedCases = [];
|
|
41036
|
-
|
|
41037
|
-
pendingHmctsServiceIdCaseTypes = new Set();
|
|
41038
|
-
constructor(searchResultViewItemComparatorFactory, appConfig, activityService, caseReferencePipe, placeholderService, browserService, sessionStorageService, caseFlagRefdataService) {
|
|
40997
|
+
constructor(searchResultViewItemComparatorFactory, appConfig, activityService, caseReferencePipe, placeholderService, browserService, sessionStorageService) {
|
|
41039
40998
|
this.activityService = activityService;
|
|
41040
40999
|
this.caseReferencePipe = caseReferencePipe;
|
|
41041
41000
|
this.placeholderService = placeholderService;
|
|
41042
41001
|
this.browserService = browserService;
|
|
41043
41002
|
this.sessionStorageService = sessionStorageService;
|
|
41044
|
-
this.caseFlagRefdataService = caseFlagRefdataService;
|
|
41045
41003
|
this.searchResultViewItemComparatorFactory = searchResultViewItemComparatorFactory;
|
|
41046
41004
|
this.paginationPageSize = appConfig.getPaginationPageSize();
|
|
41047
41005
|
this.hideRows = false;
|
|
@@ -41071,7 +41029,6 @@ class SearchResultComponent {
|
|
|
41071
41029
|
return a.order - b.order;
|
|
41072
41030
|
});
|
|
41073
41031
|
this.hydrateResultView();
|
|
41074
|
-
this.resolveHmctsServiceIdsForResults();
|
|
41075
41032
|
this.draftsCount = this.draftsCount ? this.draftsCount : this.numberOfDrafts();
|
|
41076
41033
|
}
|
|
41077
41034
|
if (changes['page']) {
|
|
@@ -41219,48 +41176,8 @@ class SearchResultComponent {
|
|
|
41219
41176
|
value: result.case_fields[col.case_field_id],
|
|
41220
41177
|
display_context_parameter: col.display_context_parameter,
|
|
41221
41178
|
display_context: col.display_context,
|
|
41222
|
-
hmctsServiceId: this.hmctsServiceIdByCaseType.get(this.getCaseTypeId(result)) || ''
|
|
41223
41179
|
});
|
|
41224
41180
|
}
|
|
41225
|
-
resolveHmctsServiceIdsForResults() {
|
|
41226
|
-
this.resultView.results.forEach((result) => {
|
|
41227
|
-
const caseTypeId = this.getCaseTypeId(result);
|
|
41228
|
-
if (!caseTypeId || !this.caseFlagRefdataService) {
|
|
41229
|
-
return;
|
|
41230
|
-
}
|
|
41231
|
-
if (this.hmctsServiceIdByCaseType.has(caseTypeId)) {
|
|
41232
|
-
this.applyHmctsServiceIdToResultFields(caseTypeId, this.hmctsServiceIdByCaseType.get(caseTypeId));
|
|
41233
|
-
return;
|
|
41234
|
-
}
|
|
41235
|
-
if (this.pendingHmctsServiceIdCaseTypes.has(caseTypeId)) {
|
|
41236
|
-
return;
|
|
41237
|
-
}
|
|
41238
|
-
this.pendingHmctsServiceIdCaseTypes.add(caseTypeId);
|
|
41239
|
-
this.caseFlagRefdataService.getHmctsServiceDetailsByCaseType(caseTypeId).subscribe({
|
|
41240
|
-
next: (serviceDetails) => {
|
|
41241
|
-
const hmctsServiceId = serviceDetails?.find((serviceDetail) => !!serviceDetail.service_code)?.service_code;
|
|
41242
|
-
if (hmctsServiceId) {
|
|
41243
|
-
this.hmctsServiceIdByCaseType.set(caseTypeId, hmctsServiceId);
|
|
41244
|
-
this.applyHmctsServiceIdToResultFields(caseTypeId, hmctsServiceId);
|
|
41245
|
-
}
|
|
41246
|
-
},
|
|
41247
|
-
error: () => this.pendingHmctsServiceIdCaseTypes.delete(caseTypeId),
|
|
41248
|
-
complete: () => this.pendingHmctsServiceIdCaseTypes.delete(caseTypeId)
|
|
41249
|
-
});
|
|
41250
|
-
});
|
|
41251
|
-
}
|
|
41252
|
-
applyHmctsServiceIdToResultFields(caseTypeId, hmctsServiceId) {
|
|
41253
|
-
this.resultView.results
|
|
41254
|
-
.filter((result) => this.getCaseTypeId(result) === caseTypeId)
|
|
41255
|
-
.forEach((result) => {
|
|
41256
|
-
Object.keys(result.columns || {}).forEach((columnId) => {
|
|
41257
|
-
result.columns[columnId].hmctsServiceId = hmctsServiceId;
|
|
41258
|
-
});
|
|
41259
|
-
});
|
|
41260
|
-
}
|
|
41261
|
-
getCaseTypeId(result) {
|
|
41262
|
-
return result?.case_fields?.['[CASE_TYPE]'] || this.caseType?.id;
|
|
41263
|
-
}
|
|
41264
41181
|
getColumnsWithPrefix(col, result) {
|
|
41265
41182
|
col.value = this.draftPrefixOrGet(col, result);
|
|
41266
41183
|
col.value = this.placeholderService.resolvePlaceholders(result.case_fields, col.value);
|
|
@@ -41383,7 +41300,7 @@ class SearchResultComponent {
|
|
|
41383
41300
|
}
|
|
41384
41301
|
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
|
41385
41302
|
noop() { }
|
|
41386
|
-
static ɵfac = function SearchResultComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SearchResultComponent)(i0.ɵɵdirectiveInject(SearchResultViewItemComparatorFactory), i0.ɵɵdirectiveInject(AbstractAppConfig), i0.ɵɵdirectiveInject(ActivityService), i0.ɵɵdirectiveInject(CaseReferencePipe), i0.ɵɵdirectiveInject(PlaceholderService), i0.ɵɵdirectiveInject(BrowserService), i0.ɵɵdirectiveInject(SessionStorageService)
|
|
41303
|
+
static ɵfac = function SearchResultComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SearchResultComponent)(i0.ɵɵdirectiveInject(SearchResultViewItemComparatorFactory), i0.ɵɵdirectiveInject(AbstractAppConfig), i0.ɵɵdirectiveInject(ActivityService), i0.ɵɵdirectiveInject(CaseReferencePipe), i0.ɵɵdirectiveInject(PlaceholderService), i0.ɵɵdirectiveInject(BrowserService), i0.ɵɵdirectiveInject(SessionStorageService)); };
|
|
41387
41304
|
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SearchResultComponent, selectors: [["ccd-search-result"]], inputs: { caseLinkUrlTemplate: "caseLinkUrlTemplate", jurisdiction: "jurisdiction", caseType: "caseType", caseState: "caseState", caseFilterFG: "caseFilterFG", resultView: "resultView", page: "page", paginationMetadata: "paginationMetadata", metadataFields: "metadataFields", selectionEnabled: "selectionEnabled", showOnlySelected: "showOnlySelected", preSelectedCases: "preSelectedCases", consumerSortingEnabled: "consumerSortingEnabled" }, outputs: { selection: "selection", changePage: "changePage", clickCase: "clickCase", sortHandler: "sortHandler" }, standalone: false, features: [i0.ɵɵNgOnChangesFeature], decls: 3, vars: 3, consts: [["case_reference", ""], [4, "ngIf"], [3, "visibilityLabel", "autoHide", "maxSize", "screenReaderPaginationLabel", "screenReaderPageLabel", "screenReaderCurrentLabel", "pageChange", 4, "ngIf"], ["class", "notification", 4, "ngIf"], ["id", "search-result-heading__text", "tabindex", "-1", 1, "heading-h2"], ["class", "govuk-warning-text pagination-limit-warning", 4, "ngIf"], ["class", "pagination-top", 4, "ngIf"], ["class", "reset-selection", 4, "ngIf"], ["scope", "row"], ["class", "govuk-table__checkbox", 4, "ngIf"], ["class", "search-result-column-header", "scope", "col", 4, "ngFor", "ngForOf"], ["style", "width: 110px;", "scope", "col", 4, "ngIf"], [1, "govuk-warning-text", "pagination-limit-warning"], ["aria-hidden", "true", 1, "govuk-warning-text__icon"], [1, "govuk-warning-text__text"], [1, "govuk-warning-text__assistive"], [1, "pagination-top"], ["id", "search-result-summary__text", 1, "text-16"], [1, "govuk-!-font-weight-bold"], [1, "reset-selection"], ["href", "#", 1, "search-result-reset-link", 3, "click"], [1, "govuk-table__checkbox"], [1, "govuk-checkboxes__item"], ["id", "select-all", "name", "select-all", "type", "checkbox", 1, "govuk-checkboxes__input", 3, "change", "checked", "disabled"], ["for", "select-all", 1, "govuk-label", "govuk-checkboxes__label"], ["scope", "col", 1, "search-result-column-header"], [1, "search-result-column-label", 3, "click", "keyup"], ["class", "search-result-column-sort", 4, "ngIf"], [1, "search-result-column-sort"], ["href", "#", 1, "sort-widget", 3, "click", "keyup.enter", "innerHTML"], ["scope", "col", 2, "width", "110px"], [4, "ngFor", "ngForOf"], ["class", "govuk-table__checkbox", "scope", "col", 4, "ngIf"], ["class", "search-result-column-cell", "scope", "row", 4, "ngFor", "ngForOf"], ["scope", "col", 1, "govuk-table__checkbox"], ["type", "checkbox", 1, "govuk-checkboxes__input", 3, "change", "id", "name", "checked", "disabled"], [1, "govuk-label", "govuk-checkboxes__label", 3, "for"], ["scope", "row", 1, "search-result-column-cell"], ["class", "govuk-link", 3, "routerLink", 4, "ngIf"], ["class", "text-16", 3, "visibility", 4, "ngIf"], [1, "govuk-link", 3, "routerLink"], ["class", "text-16", 4, "ngIf"], [1, "text-16"], ["ccdLabelSubstitutor", "", 3, "caseField", "contextFields", "elementsToSubstitute", 4, "ngIf", "ngIfElse"], ["ccdLabelSubstitutor", "", 3, "caseField", "contextFields", "elementsToSubstitute"], [3, "caseId", "displayMode"], ["type", "checkbox", 1, "govuk-checkboxes__input", 3, "change", "keyup", "id", "name", "checked", "disabled"], [3, "pageChange", "visibilityLabel", "autoHide", "maxSize", "screenReaderPaginationLabel", "screenReaderPageLabel", "screenReaderCurrentLabel"], [1, "notification"]], template: function SearchResultComponent_Template(rf, ctx) { if (rf & 1) {
|
|
41388
41305
|
i0.ɵɵtemplate(0, SearchResultComponent_table_0_Template, 16, 11, "table", 1)(1, SearchResultComponent_ccd_pagination_1_Template, 1, 6, "ccd-pagination", 2)(2, SearchResultComponent_div_2_Template, 4, 6, "div", 3);
|
|
41389
41306
|
} if (rf & 2) {
|
|
@@ -41397,9 +41314,7 @@ class SearchResultComponent {
|
|
|
41397
41314
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SearchResultComponent, [{
|
|
41398
41315
|
type: Component,
|
|
41399
41316
|
args: [{ selector: 'ccd-search-result', standalone: false, template: "<table *ngIf=\"hasResults() || hasDrafts()\">\n <caption>\n <h2 class=\"heading-h2\" id=\"search-result-heading__text\" tabindex=\"-1\">{{ (caseState ? 'Your cases' : 'Search result') | rpxTranslate}}</h2>\n\n <div class=\"govuk-warning-text pagination-limit-warning\" *ngIf=\"paginationLimitEnforced\">\n <span class=\"govuk-warning-text__icon\" aria-hidden=\"true\">!</span>\n <strong class=\"govuk-warning-text__text\">\n <span class=\"govuk-warning-text__assistive\">{{'Warning' | rpxTranslate}}</span>\n {{'The total size of the result set is' | rpxTranslate}} {{paginationMetadata.totalResultsCount | number}}. {{'Only the first 10,000 records are available for display.' | rpxTranslate}}\n </strong>\n </div>\n\n <div *ngIf=\"(hasResults() || hasDrafts())\" class=\"pagination-top\">\n <output [attr.aria-label]=\"getTotalResults() + ' ' + ('results have been found' | rpxTranslate)\"></output>\n <span class=\"text-16\" id=\"search-result-summary__text\">{{'Showing' | rpxTranslate}}\n <span class=\"govuk-!-font-weight-bold\">{{ getFirstResult() }}</span>\n {{'to' | rpxTranslate}}\n <span class=\"govuk-!-font-weight-bold\">{{ getLastResult() }}</span>\n {{'of' | rpxTranslate}}\n <span class=\"govuk-!-font-weight-bold\">{{ getTotalResults() }}</span> {{'results' | rpxTranslate}}</span>\n </div>\n <div *ngIf=\"(hasResults() || hasDrafts()) && selectionEnabled\" class=\"reset-selection\"\n [attr.aria-label]=\"'Reset selection' | rpxTranslate\">\n <span><a class=\"search-result-reset-link\" href=\"#\" (click)=\"clearSelection(); $event.preventDefault()\">{{'Reset case selection' | rpxTranslate}}</a></span>\n </div>\n </caption>\n <thead>\n <tr scope=\"row\">\n <td *ngIf=\"selectionEnabled\" class=\"govuk-table__checkbox\">\n <div class=\"govuk-checkboxes__item\">\n <input class=\"govuk-checkboxes__input\" id=\"select-all\" name=\"select-all\" type=\"checkbox\" (change)=\"selectAll()\" [checked]=\"allOnPageSelected()\" [disabled]=\"!canAnyBeShared()\" />\n <label class=\"govuk-label govuk-checkboxes__label\" for=\"select-all\" [attr.aria-labelledby]=\"'select-all'\">\n </label>\n </div>\n </td>\n <th *ngFor=\"let col of resultView.columns\" class=\"search-result-column-header\"\n [attr.aria-sort]=\"isSortAscending(col) === null ? null : (isSortAscending(col) ? 'ascending' : 'descending')\" scope=\"col\">\n <div>\n <div class=\"search-result-column-label\" (click)=\"sort(col)\" (keyup)=\"noop()\">\n {{ isTranslatable(col) ? (col.label | rpxTranslate) : col.label }}\n </div>\n <div *ngIf=\"comparator(col)\" class=\"search-result-column-sort\">\n <a (click)=\"sort(col); $event.preventDefault()\" (keyup.enter)=\"sort(col)\" class=\"sort-widget\" [innerHTML]=\"sortWidget(col)\" [attr.aria-label]=\"'Sort ' + col.label | rpxTranslate\" href=\"#\"></a>\n </div>\n </div>\n </th>\n <th *ngIf=\"activityEnabled()\" style=\"width: 110px;\" scope=\"col\">​</th>\n </tr>\n </thead>\n\n <tbody>\n <!-- sorted by consumer -->\n <ng-container *ngIf=\"consumerSortingEnabled\">\n <tr *ngFor=\"let result of resultView.results | paginate: { itemsPerPage: paginationPageSize, currentPage: selected.page, totalItems: resultTotal }\">\n <td *ngIf=\"selectionEnabled\" class=\"govuk-table__checkbox\" scope=\"col\">\n <div class=\"govuk-checkboxes__item\">\n <input class=\"govuk-checkboxes__input\" id=\"select-{{ result.case_id }}\" name=\"select-{{ result.case_id }}\"\n type=\"checkbox\" (change)=\"changeSelection(result)\" [checked]=\"isSelected(result)\" [disabled]=\"!canBeShared(result)\" />\n <label class=\"govuk-label govuk-checkboxes__label\" for=\"select-{{ result.case_id }}\" [attr.aria-labelledby]=\"'select-' + result.case_id\">\n </label>\n </div>\n </td>\n <td class=\"search-result-column-cell\" *ngFor=\"let col of resultView.columns; let colIndex = index\" scope=\"row\">\n <a *ngIf=\"colIndex == 0\" [routerLink]=\"prepareCaseLinkUrl(result.case_id)\"\n attr.aria-label=\"go to case with Case reference:{{ result.case_id | ccdCaseReference }}\" class=\"govuk-link\">\n <ng-container class=\"text-16\" *ngIf=\"!hideRows\">\n <ccd-field-read *ngIf=\"draftPrefixOrGet(col, result); else case_reference\"\n ccdLabelSubstitutor [caseField]=\"getColumnsWithPrefix(result.columns[col.case_field_id], result)\"\n [contextFields]=\"result.hydrated_case_fields\"\n [elementsToSubstitute]=\"['value']\"></ccd-field-read>\n <ng-template #case_reference>{{result.case_id | ccdCaseReference}}</ng-template>\n </ng-container>\n </a>\n <div *ngIf=\"colIndex != 0\" class=\"text-16\" [style.visibility]=\"hideRows ? 'hidden' : 'visible'\">\n <ccd-field-read ccdLabelSubstitutor\n [caseField]=\"result.columns[col.case_field_id]\"\n [contextFields]=\"result.hydrated_case_fields\"\n [elementsToSubstitute]=\"['value']\"></ccd-field-read>\n </div>\n </td>\n <td *ngIf=\"activityEnabled()\">\n <div [style.visibility]=\"hideRows ? 'hidden' : 'visible'\">\n <ccd-activity [caseId]=\"result.case_id\" [displayMode]=\"ICON\"></ccd-activity>\n </div>\n </td>\n </tr>\n </ng-container>\n <!-- sorted by toolkit -->\n <ng-container *ngIf=\"!consumerSortingEnabled\">\n <tr *ngFor=\"let result of resultView.results | ccdSortSearchResult : sortParameters | paginate: { itemsPerPage: paginationPageSize, currentPage: selected.page, totalItems: resultTotal }\">\n <td *ngIf=\"selectionEnabled\" class=\"govuk-table__checkbox\" scope=\"col\">\n <div class=\"govuk-checkboxes__item\">\n <input class=\"govuk-checkboxes__input\" id=\"select-{{ result.case_id }}\" name=\"select-{{ result.case_id }}\"\n type=\"checkbox\" (change)=\"changeSelection(result)\" [checked]=\"isSelected(result)\" [disabled]=\"!canBeShared(result)\" (keyup)=\"onKeyUp($event, result)\" />\n <label class=\"govuk-label govuk-checkboxes__label\" for=\"select-{{ result.case_id }}\" [attr.aria-labelledby]=\"'select-' + result.case_id\">\n </label>\n </div>\n </td>\n <td class=\"search-result-column-cell\" *ngFor=\"let col of resultView.columns; let colIndex = index\" scope=\"row\">\n\n <a *ngIf=\"colIndex == 0\" [routerLink]=\"prepareCaseLinkUrl(result.case_id)\"\n attr.aria-label=\"go to case with Case reference:{{ result.case_id | ccdCaseReference }}\" class=\"govuk-link\">\n <ng-container class=\"text-16\" *ngIf=\"!hideRows\">\n <ccd-field-read *ngIf=\"draftPrefixOrGet(col, result); else case_reference\"\n ccdLabelSubstitutor [caseField]=\"getColumnsWithPrefix(result.columns[col.case_field_id], result)\"\n [contextFields]=\"result.hydrated_case_fields\"\n [elementsToSubstitute]=\"['value']\"></ccd-field-read>\n <ng-template #case_reference>{{result.case_id | ccdCaseReference}}</ng-template>\n </ng-container>\n </a>\n <div *ngIf=\"colIndex != 0\" class=\"text-16\" [style.visibility]=\"hideRows ? 'hidden' : 'visible'\">\n <ccd-field-read ccdLabelSubstitutor\n [caseField]=\"result.columns[col.case_field_id]\"\n [contextFields]=\"result.hydrated_case_fields\"\n [elementsToSubstitute]=\"['value']\"></ccd-field-read>\n </div>\n </td>\n <td *ngIf=\"activityEnabled()\">\n <div [style.visibility]=\"hideRows ? 'hidden' : 'visible'\">\n <ccd-activity [caseId]=\"result.case_id\" [displayMode]=\"ICON\"></ccd-activity>\n </div>\n </td>\n </tr>\n </ng-container>\n\n </tbody>\n</table>\n\n<ccd-pagination\n *ngIf=\"hasResults()\"\n (pageChange)=\"goToPage($event)\"\n [visibilityLabel]=\"hideRows ? 'hidden' : 'visible'\"\n [autoHide]=\"true\"\n [maxSize]=\"8\"\n [screenReaderPaginationLabel]=\"'Pagination'\"\n [screenReaderPageLabel]=\"page\"\n [screenReaderCurrentLabel]=\"'You\\'re on page'\"></ccd-pagination>\n\n<div *ngIf=\"!(hasResults() || hasDrafts())\" class=\"notification\"\n[attr.aria-describedby]=\"'No cases found. Try using different filters.' | rpxTranslate\">\n{{'No cases found. Try using different filters.' | rpxTranslate}}\n</div>\n", styles: ["table thead tr th{vertical-align:top}table tbody tr td{font-size:16px;word-wrap:break-word}table tbody tr td a{float:left}table .caseid-col{white-space:nowrap}.notification{text-align:center;padding:30px 0;margin-top:75px}a:hover{color:#005ea5}.search-result-reset-link{padding-right:15px;padding-left:15px}.search-result-column-header{width:unset;table-layout:normal}.search-result-column-header div{display:table-cell;width:auto}@media screen and (max-width:379px){.search-result-column-header div{display:block;float:right}}.search-result-column-label{font-size:16px;font-weight:700;word-wrap:break-word;cursor:pointer;padding-right:15px}.search-result-column-sort{font-size:16px}.sort-widget{cursor:pointer;text-decoration:none;color:#231f20}span.heading-medium{margin-top:-20px}.govuk-table__checkbox{vertical-align:middle;padding-left:3px}#search-result-heading__text:focus{outline:none}\n"] }]
|
|
41400
|
-
}], () => [{ type: SearchResultViewItemComparatorFactory }, { type: AbstractAppConfig }, { type: ActivityService }, { type: CaseReferencePipe }, { type: PlaceholderService }, { type: BrowserService }, { type: SessionStorageService }, {
|
|
41401
|
-
type: Optional
|
|
41402
|
-
}] }], { caseLinkUrlTemplate: [{
|
|
41317
|
+
}], () => [{ type: SearchResultViewItemComparatorFactory }, { type: AbstractAppConfig }, { type: ActivityService }, { type: CaseReferencePipe }, { type: PlaceholderService }, { type: BrowserService }, { type: SessionStorageService }], { caseLinkUrlTemplate: [{
|
|
41403
41318
|
type: Input
|
|
41404
41319
|
}], jurisdiction: [{
|
|
41405
41320
|
type: Input
|
|
@@ -41434,7 +41349,7 @@ class SearchResultComponent {
|
|
|
41434
41349
|
}], sortHandler: [{
|
|
41435
41350
|
type: Output
|
|
41436
41351
|
}] }); })();
|
|
41437
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SearchResultComponent, { className: "SearchResultComponent", filePath: "lib/shared/components/search-result/search-result.component.ts", lineNumber:
|
|
41352
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SearchResultComponent, { className: "SearchResultComponent", filePath: "lib/shared/components/search-result/search-result.component.ts", lineNumber: 19 }); })();
|
|
41438
41353
|
|
|
41439
41354
|
class SearchResultModule {
|
|
41440
41355
|
static ɵfac = function SearchResultModule_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SearchResultModule)(); };
|