on 04-25-2022 10:52 AM
Hi everyone,
we are currently developing a RAP model having a root entity and one child entity ( 0...*) .
We decided so far for a managed implementation with unmanaged save.
Now my question:
When displaying the list of child entity we need to add some additional lines, which are read-only. These lines won't be saved until the user changes some status field.
Thus, before the status change, we need to add these additinal lines every time a user opens the app.
Is it possible to implement this without changing from managed to unmanaged implementation?
Or if this only works in an unmanaged scenario: Can we only have the child entity unmanaged, but stay with managed for the root entity?
Any help is welcome 🙂
Hi ,
If those records needs to be read only, then you can mark "update" as instance feature at child node.
update ( features : instance );<br>
Then in implementation method, based on your logic ( header status ) , you can set %update = X or '' .
result = VALUE #( FOR <fs_key> IN keys ( %tky = <fs_key>-%tky
%update = if_abap_behv=>fc-o-disabled ) )<br>
If you set to ' ', those records will be read only. This can be done with "managed" scenario.
Is it draft or without-draft application ?
Best wishes,
Ramjee Korada.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have just posted a more lenghty answer that describes the same approach here:
https://answers.sap.com/answers/13629041/view.html
Hi Ramjee,
thanks for your feedback.
I managed to implement the feature control. So my data can be changed depending on my state.
However, I still have the problem, that I would like to add some extra data lines (schedule lines of a sales Order) which are not on the data base of my child entity.
I change to a unmanged szenario (with draft) and hoped that I can read the schedule lines in the read method to display them. But then I realized, that the displayed child entities are only those on my data base. Actually the read method is not called for reading the data.
Is there a way how to add some extra lines? I need to be sure to display the current state of the sales order.
Best regards,
Alexandra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.