on 2020 Jul 08 9:22 AM
Hello everyone,
Problem with binding of 2 tables in the DetailDetail View. There is a table with elements in the MasterPage, by clicking on one of the elements i need to open a detailView with 2 tables (with different IDs) and transfer data to them. Data is in the same data model, but in different arrays.
this.getView().bindElement– binding first table successful
this.getView().byId("positionTable")– binding doesn't work
Detail.controller.js
_onProductMatched: function (oEvent) {
this._product = oEvent.getParameter("arguments").product || "0";
this.index = oEvent.getParameter("arguments").index || "0";
this.getView().bindElement({
path: "/anfragekurzdata/" + this.index,
model: "detail-data"
});
////////////what i need to bind. this code doesn't work
var oTable = this.getView().byId("positionTable");
oTable.bindElement({
path: "/positionendata/" + this.index,
model: "detail-data"
});
Hi,
For binding tables, I would use bindItems or bindRows (in case of sap.ui.table.Table).
oTable.bindItems({
path: "/positionendata/" + this.index,
model: "detail-data"
})
If the data is not displayed, there could be issue in view.
Since you're using named model, all the property bindings need 'detail-data>' before property name.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
64 | |
8 | |
8 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.