@sapui5/sap.fe.macros 1.142.1 → 1.142.2
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/package.json +1 -1
- package/src/sap/fe/macros/.library +1 -1
- package/src/sap/fe/macros/controls/FileWrapper.js +4 -3
- package/src/sap/fe/macros/controls/FileWrapper.ts +3 -2
- package/src/sap/fe/macros/controls/Section.js +3 -2
- package/src/sap/fe/macros/controls/Section.ts +1 -1
- package/src/sap/fe/macros/field/FieldTemplating.js +1 -1
- package/src/sap/fe/macros/field/FieldTemplating.ts +1 -1
- package/src/sap/fe/macros/internal/field/DisplayStyle.js +3 -2
- package/src/sap/fe/macros/internal/field/DisplayStyle.tsx +1 -0
- package/src/sap/fe/macros/internal/valuehelp/ValueListHelper.js +23 -3
- package/src/sap/fe/macros/internal/valuehelp/ValueListHelper.ts +24 -2
- package/src/sap/fe/macros/library.js +1 -1
- package/src/sap/fe/macros/multivaluefield/MultiValueFieldDelegate.js +5 -1
- package/src/sap/fe/macros/multivaluefield/MultiValueFieldDelegate.ts +4 -0
- package/src/sap/fe/macros/table/MdcTableTemplate.js +5 -4
- package/src/sap/fe/macros/table/MdcTableTemplate.tsx +4 -3
- package/src/sap/fe/macros/table/TableAPI.js +17 -4
- package/src/sap/fe/macros/table/TableAPI.ts +15 -0
- package/src/sap/fe/macros/table/TableEventHandlerProvider.js +10 -1
- package/src/sap/fe/macros/table/TableEventHandlerProvider.ts +10 -0
- package/src/sap/fe/macros/table/TableRuntime.js +6 -4
- package/src/sap/fe/macros/table/TableRuntime.ts +16 -3
- package/src/sap/fe/macros/table/mixin/ContextMenuHandler.js +2 -4
- package/src/sap/fe/macros/table/mixin/ContextMenuHandler.ts +1 -2
- package/src/sap/fe/macros/table/mixin/EmptyRowsHandler.js +10 -4
- package/src/sap/fe/macros/table/mixin/EmptyRowsHandler.ts +9 -3
- package/src/sap/fe/macros/valuehelp/ValueHelpDelegate.js +25 -9
- package/src/sap/fe/macros/valuehelp/ValueHelpDelegate.ts +33 -17
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ConvertedMetadata,Property } from "@sap-ux/vocabularies-types";
|
|
1
|
+
import type { ConvertedMetadata, Property } from "@sap-ux/vocabularies-types";
|
|
2
2
|
import Log from "sap/base/Log";
|
|
3
3
|
import ObjectPath from "sap/base/util/ObjectPath";
|
|
4
4
|
import CommonUtils from "sap/fe/core/CommonUtils";
|
|
@@ -6,10 +6,10 @@ import { Activity } from "sap/fe/core/controllerextensions/collaboration/Collabo
|
|
|
6
6
|
import { convertTypes } from "sap/fe/core/converters/MetaModelConverter";
|
|
7
7
|
import type { PropertyInfo } from "sap/fe/core/converters/controls/ListReport/FilterBar";
|
|
8
8
|
import { isPathAnnotationExpression } from "sap/fe/core/helpers/TypeGuards";
|
|
9
|
-
import type { FieldDataType,ValueHelpHistoryService } from "sap/fe/core/services/ValueHelpHistoryServiceFactory";
|
|
9
|
+
import type { FieldDataType, ValueHelpHistoryService } from "sap/fe/core/services/ValueHelpHistoryServiceFactory";
|
|
10
10
|
import type { IFilterControl } from "sap/fe/macros/filter/FilterUtils";
|
|
11
11
|
import FilterUtils from "sap/fe/macros/filter/FilterUtils";
|
|
12
|
-
import type { InOutParameter,SorterType,ValueHelpPayload } from "sap/fe/macros/internal/valuehelp/ValueListHelper";
|
|
12
|
+
import type { InOutParameter, SorterType, ValueHelpPayload } from "sap/fe/macros/internal/valuehelp/ValueListHelper";
|
|
13
13
|
import ValueListHelper from "sap/fe/macros/internal/valuehelp/ValueListHelper";
|
|
14
14
|
import type Dialog from "sap/m/Dialog";
|
|
15
15
|
import type Table from "sap/m/Table";
|
|
@@ -34,6 +34,7 @@ import type FilterBarBase from "sap/ui/mdc/filterbar/FilterBarBase";
|
|
|
34
34
|
import TypeMap from "sap/ui/mdc/odata/v4/TypeMap";
|
|
35
35
|
import StateUtil from "sap/ui/mdc/p13n/StateUtil";
|
|
36
36
|
import type MDCPopover from "sap/ui/mdc/valuehelp/Popover";
|
|
37
|
+
import RequestShowContainerDefault from "sap/ui/mdc/valuehelp/RequestShowContainerDefault";
|
|
37
38
|
import type Container from "sap/ui/mdc/valuehelp/base/Container";
|
|
38
39
|
import type Content from "sap/ui/mdc/valuehelp/base/Content";
|
|
39
40
|
import type FilterableListContent from "sap/ui/mdc/valuehelp/base/FilterableListContent";
|
|
@@ -48,7 +49,6 @@ import type ODataModel from "sap/ui/model/odata/v4/ODataModel";
|
|
|
48
49
|
import type { Value } from "../field/FieldBaseDelegate";
|
|
49
50
|
import type { AdditionalValueType, BindingInfoParameters } from "../internal/valuehelp/AdditionalValueHelper";
|
|
50
51
|
import { AdditionalValueGroupKey, additionalValueHelper } from "../internal/valuehelp/AdditionalValueHelper";
|
|
51
|
-
import RequestShowContainerDefault from "sap/ui/mdc/valuehelp/RequestShowContainerDefault"
|
|
52
52
|
|
|
53
53
|
const FeCoreControlsFilterBar = "sap.fe.macros.controls.FilterBar";
|
|
54
54
|
const AnnotationIsDigitSequence = "@com.sap.vocabularies.Common.v1.IsDigitSequence";
|
|
@@ -787,7 +787,9 @@ This cannot happen in case of action parameter dialog, which can be identified b
|
|
|
787
787
|
const condition = this._createInitialFilterCondition(values[i], inParameter.initialValueIsSignificant);
|
|
788
788
|
|
|
789
789
|
if (condition) {
|
|
790
|
-
|
|
790
|
+
// Use conditionPath if available, otherwise fallback to helpPath for backward compatibility
|
|
791
|
+
const conditionKey = inParameter.conditionPath || inParameter.helpPath;
|
|
792
|
+
inConditions[conditionKey] = [condition];
|
|
791
793
|
}
|
|
792
794
|
}
|
|
793
795
|
}
|
|
@@ -859,7 +861,9 @@ This cannot happen in case of action parameter dialog, which can be identified b
|
|
|
859
861
|
|
|
860
862
|
const conditions = this._getConditionsFromInParameter(sourceField as string, state);
|
|
861
863
|
if (conditions) {
|
|
862
|
-
|
|
864
|
+
// Use conditionPath if available, otherwise fallback to helpPath for backward compatibility
|
|
865
|
+
const conditionKey = inParameter.conditionPath || inParameter.helpPath;
|
|
866
|
+
inConditions[conditionKey] = conditions;
|
|
863
867
|
}
|
|
864
868
|
}
|
|
865
869
|
return inConditions;
|
|
@@ -942,7 +946,9 @@ This cannot happen in case of action parameter dialog, which can be identified b
|
|
|
942
946
|
isObjectPage ? inParameter.initialValueIsSignificant : false // no filter with "empty" on ListReport
|
|
943
947
|
);
|
|
944
948
|
if (condition) {
|
|
945
|
-
|
|
949
|
+
// Use conditionPath if available, otherwise fallback to helpPath for backward compatibility
|
|
950
|
+
const conditionKey = inParameter.conditionPath || inParameter.helpPath;
|
|
951
|
+
inConditions[conditionKey] = [condition];
|
|
946
952
|
}
|
|
947
953
|
}
|
|
948
954
|
|
|
@@ -1184,16 +1190,26 @@ This cannot happen in case of action parameter dialog, which can be identified b
|
|
|
1184
1190
|
);
|
|
1185
1191
|
|
|
1186
1192
|
let recentValuesContextData: FieldDataType[] = [];
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1193
|
+
try {
|
|
1194
|
+
if (!payload.isValueListWithFixedValues) {
|
|
1195
|
+
// no history for values lists with fixed values (they are usually short)
|
|
1196
|
+
recentValuesContextData = await this._getHistoryData(payload, field);
|
|
1197
|
+
recentValuesContextData = additionalValueHelper.getRelevantRecentValuesContextData(
|
|
1198
|
+
othersValuesContextData,
|
|
1199
|
+
recentValuesContextData,
|
|
1200
|
+
valueHelpKeys,
|
|
1201
|
+
(bindingInfo.parameters as BindingInfoParameters).$search?.replaceAll('"', ""),
|
|
1202
|
+
bindingInfo
|
|
1203
|
+
);
|
|
1204
|
+
}
|
|
1205
|
+
} catch (error) {
|
|
1206
|
+
// For recently used values we use a UI5 json model.
|
|
1207
|
+
// We take the OData filter and apply it to the JSON model.
|
|
1208
|
+
// This works in most cases but not in a 1:n scenario where OData uses a Lambda Syntax.
|
|
1209
|
+
// To support this we would have to implement a converter which converters the Lambda filters into simple Javascript filters which can work on the JSON model.
|
|
1210
|
+
// As this is a corner case hence we just log the error and continue without recently used values.
|
|
1211
|
+
recentValuesContextData = [];
|
|
1212
|
+
Log.warning("Could not determine recently used values");
|
|
1197
1213
|
}
|
|
1198
1214
|
|
|
1199
1215
|
othersValuesContextData = additionalValueHelper.getRelevantOthersValuesContextData(
|