cancel
Showing results for 
Search instead for 
Did you mean: 

RAP: How to enrich displayed List Data (managed scenario with unmanaged save )

akoethe
Explorer
0 Kudos

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 🙂

Accepted Solutions (0)

Answers (2)

Answers (2)

Ramjee_korada
Active Contributor

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.

Andre_Fischer
Product and Topic Expert
Product and Topic Expert
0 Kudos

I have just posted a more lenghty answer that describes the same approach here:
https://answers.sap.com/answers/13629041/view.html

akoethe
Explorer
0 Kudos

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