@hmcts/ccd-case-ui-toolkit 4.8.4-EUI-4329-data-validation → 4.8.4-EUI-4329-data-validation-r3
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/dist/index.umd.js +11 -4
- package/dist/index.umd.js.map +1 -1
- package/dist/index.umd.min.js +1 -1
- package/dist/index.umd.min.js.LICENSE.txt +1 -1
- package/dist/index.umd.min.js.map +1 -1
- package/dist/shared/components/case-editor/case-edit-page/case-edit-page.component.js +3 -1
- package/dist/shared/components/case-editor/case-edit-page/case-edit-page.component.js.map +1 -1
- package/dist/shared/components/palette/case-link/write-case-link-field.component.js +7 -2
- package/dist/shared/components/palette/case-link/write-case-link-field.component.js.map +1 -1
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @hmcts/ccd-case-ui-toolkit - Case UI Toolkit
|
|
3
|
-
* @version v4.8.4-EUI-4329-data-validation
|
|
3
|
+
* @version v4.8.4-EUI-4329-data-validation-r3
|
|
4
4
|
* @link undefined
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
@@ -12983,7 +12983,9 @@ var CaseEditPageComponent = /** @class */ (function () {
|
|
|
12983
12983
|
if (this.currentPageIsNotValid()) {
|
|
12984
12984
|
this.generateErrorMessage(this.currentPage.case_fields);
|
|
12985
12985
|
}
|
|
12986
|
-
|
|
12986
|
+
else {
|
|
12987
|
+
this.showSpinner = true;
|
|
12988
|
+
}
|
|
12987
12989
|
if (!this.isSubmitting && !this.currentPageIsNotValid()) {
|
|
12988
12990
|
this.isSubmitting = true;
|
|
12989
12991
|
this.error = null;
|
|
@@ -20555,12 +20557,12 @@ var WriteCaseLinkFieldComponent = /** @class */ (function (_super) {
|
|
|
20555
20557
|
WriteCaseLinkFieldComponent.prototype.ngOnInit = function () {
|
|
20556
20558
|
if (this.caseField.value) {
|
|
20557
20559
|
this.caseLinkGroup = this.registerControl(new forms_1.FormGroup({
|
|
20558
|
-
'CaseReference': new forms_1.FormControl(this.caseField.value.CaseReference),
|
|
20560
|
+
'CaseReference': new forms_1.FormControl(this.caseField.value.CaseReference, forms_1.Validators.required),
|
|
20559
20561
|
}), true);
|
|
20560
20562
|
}
|
|
20561
20563
|
else {
|
|
20562
20564
|
this.caseLinkGroup = this.registerControl(new forms_1.FormGroup({
|
|
20563
|
-
'CaseReference': new forms_1.FormControl(),
|
|
20565
|
+
'CaseReference': new forms_1.FormControl(null, forms_1.Validators.required),
|
|
20564
20566
|
}), true);
|
|
20565
20567
|
}
|
|
20566
20568
|
this.caseReferenceControl = this.caseLinkGroup.controls['CaseReference'];
|
|
@@ -20583,6 +20585,11 @@ var WriteCaseLinkFieldComponent = /** @class */ (function (_super) {
|
|
|
20583
20585
|
}
|
|
20584
20586
|
return { 'error': 'Please use a valid 16 Digit Case Reference' };
|
|
20585
20587
|
}
|
|
20588
|
+
else {
|
|
20589
|
+
if (control.touched) {
|
|
20590
|
+
return { 'error': 'Please use a valid 16 Digit Case Reference' };
|
|
20591
|
+
}
|
|
20592
|
+
}
|
|
20586
20593
|
return null;
|
|
20587
20594
|
};
|
|
20588
20595
|
};
|