@hmcts/ccd-case-ui-toolkit 6.13.9-rc4 → 6.13.9-rc5
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/bundles/hmcts-ccd-case-ui-toolkit.umd.js +13 -10
- package/bundles/hmcts-ccd-case-ui-toolkit.umd.js.map +1 -1
- package/bundles/hmcts-ccd-case-ui-toolkit.umd.min.js +1 -1
- package/bundles/hmcts-ccd-case-ui-toolkit.umd.min.js.map +1 -1
- package/esm2015/lib/shared/pipes/complex/ccd-read-fields-filter.pipe.js +14 -11
- package/fesm2015/hmcts-ccd-case-ui-toolkit.js +13 -10
- package/fesm2015/hmcts-ccd-case-ui-toolkit.js.map +1 -1
- package/lib/shared/pipes/complex/ccd-read-fields-filter.pipe.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -25012,23 +25012,26 @@
|
|
|
25012
25012
|
|| !ReadFieldsFilterPipe.isEmpty(value[field.id]);
|
|
25013
25013
|
};
|
|
25014
25014
|
ReadFieldsFilterPipe.getValue = function (field, values, index) {
|
|
25015
|
-
|
|
25016
|
-
|
|
25017
|
-
|
|
25018
|
-
|
|
25019
|
-
|
|
25020
|
-
|
|
25015
|
+
if (ReadFieldsFilterPipe.isEmpty(field.value)) {
|
|
25016
|
+
var value = void 0;
|
|
25017
|
+
if (index >= 0) {
|
|
25018
|
+
value = values[index].value[field.id];
|
|
25019
|
+
}
|
|
25020
|
+
else {
|
|
25021
|
+
value = values[field.id];
|
|
25022
|
+
}
|
|
25023
|
+
return value;
|
|
25021
25024
|
}
|
|
25022
|
-
return
|
|
25025
|
+
return field.value;
|
|
25023
25026
|
};
|
|
25024
|
-
ReadFieldsFilterPipe.evaluateConditionalShow = function (field, formValue, path,
|
|
25027
|
+
ReadFieldsFilterPipe.evaluateConditionalShow = function (field, formValue, path, formGroupAvailable, fieldId) {
|
|
25025
25028
|
if (field.display_context === 'HIDDEN') {
|
|
25026
25029
|
field.hidden = true;
|
|
25027
25030
|
}
|
|
25028
25031
|
else if (field.show_condition) {
|
|
25029
25032
|
var cond = void 0;
|
|
25030
|
-
if (fieldId && field.show_condition.indexOf(fieldId) > -1 && !
|
|
25031
|
-
var search = fieldId +
|
|
25033
|
+
if (fieldId && field.show_condition.indexOf(fieldId + ".") > -1 && !formGroupAvailable && !!Object.keys(formValue).length) {
|
|
25034
|
+
var search = fieldId + ".";
|
|
25032
25035
|
var searchRegExp = new RegExp(search, 'g');
|
|
25033
25036
|
var replaceWith = '';
|
|
25034
25037
|
cond = ShowCondition.getInstance(field.show_condition.replace(searchRegExp, replaceWith));
|