/scripts/ahub.form.attachments.js
0

SAPUI5: extend oData model at frontend

Jan 30, 2017 at 11:59 AM

100

avatar image
Former Member

Hi,

I ran into the following problem: I bind an oDataModel to a TableSelectDialog and I would like to add a new column (property) to the table what is not included by the oData service. So when the user selected some of the records and set the "new" property and "Confirm" the TableSelectDialog, I would like to merge the oData model's record with the new property and create a new JSONModel.

For example, there is an oDataModel with P1, P2, P3 property, a TableSelectDialog with C1, C2, C3, C4 columns, I bind P1-C1, P2-C2, P3-C3. When I confirm the TableSelectDialog I would like to create a new record to a JSONModel with properties Q1, Q2, Q3, Q4, where Q1=C1-P1, Q2=C2-P2, Q3=C3-P3, Q4=C4.

I already tried to bind the new JSONModel to the TableSelectDialog too, but in this way only one record created and bound for the all row (so when I set the C4 column in one row, the new value applied to the all row).

Is there any solution for? I know there is workaround like create a new "blank" property for the oDataModel's service and use it, but I would like to implement a correct solution.

Thanks,

Andras Konya

10 |10000 characters needed characters left characters exceeded

Hi Andras,

Can you provide your code , so that made us clear what exactly you tried and what is your requirement

thanks

Viplove

0
* Please Login or Register to Answer, Follow or Comment.

0 Answers

Skip to Content