on 2021 Jun 07 10:15 AM
Hello,
I'm trying to extend the standard sap.ui.core.Item control with some new behaviour. It will be used in the MultiComboBox later.
I have made a new DetailItem.js file in my project and entered the following code:
sap.ui.define([
"sap/ui/core/Item"
], function (Item) {
"use strict";
return Item.extend("DetailItem", {
metadata: {
properties: {
detailText: {type: "string", defaultValue: ""},
}
},
renderer: { }
});
});
Now when I call the control in the view with the namespace xmlns:ownControl="ch.ckw.zmmuamovw.controls"
Then in the aggregation of the MultiComboBox, it should now load my extended component:
<items>
<ownControl:DetailItem key="{viewModel>key}" text="{viewModel>name}" detailText="test"/>
</items>
I try to achieve to access the property detailText in my extended logic, which actually should be possible.
Anyway I receive always the console log error:
Now what can I do, with this error, since I'm not able to create a custom control since the combo box requires an Item as children.
Request clarification before answering.
User | Count |
---|---|
75 | |
30 | |
9 | |
8 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.