on 2025 Jan 23 10:40 AM
Hello,
I tried to add a custom filter field to a ListReportPage filterbar. I want to have a multi input field with a value help dialog in it.
<mdc:Field
id="AirportFromTo"
core:require="{handler: 'com/advades/flight/ext/fragment/AirportFromTo'}"
value="{path: 'filterValues>', type: 'sap.fe.macros.filter.type.Value', formatOptions: { operator: 'com.advades.flight.ext.fragment.AirportFromTo.filterItems' }}"
/>sap.ui.define(["sap/ui/model/Filter", "sap/ui/model/FilterOperator"], function (Filter, FilterOperator) {
"use strict";
return {
filterItems: function (sValue) {
debugger;
return new Filter({
filters: [
new Filter({ path: "AirportFromId", operator: FilterOperator.EQ, value1: sValue }),
new Filter({ path: "AirportToId", operator: FilterOperator.EQ, value1: sValue })
],
and: false
});
}
};
});
The filtering is working like expected but the value help is missing.
I tried it also with a macros:Field but it didnt work.
In my opinion there should be a easy way to add in custom filter without building the value help dialog by myself.
Request clarification before answering.
| User | Count |
|---|---|
| 17 | |
| 8 | |
| 7 | |
| 6 | |
| 4 | |
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.