cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Enabling draft scenario in SAP Free style application ?

Ramjee_korada
Active Contributor
0 Likes
1,422

Hello Experts,

this is generic question!!!

Can we enable draft capabilities in SAP free style application also ?

In my current project, applications are huge and not that friendly for fiori elements and drive by annotations.

I am a backend developer and cant decide . As per the tutorials on RAP/BOPF, it is clear that it is possible in SAP Fiori elements.

Best wishes,

Ramjee Korada

Accepted Solutions (0)

Answers (2)

Answers (2)

MioYasutake
SAP Champion
SAP Champion

Hi koradaramjee789,

Below sample is a draft enabled free style app built on top of CAP.

https://github.com/SAP-samples/ui5-cap-event-app/blob/main/docs/documentation.md

I think it gives you an idea of how the frontend deals with draft.

Ramjee_korada
Active Contributor
0 Likes

thank you Mio. I will go through

abhirup
Advisor
Advisor
0 Likes

Hi Ramjee,

Though it is in principal technically possible to develop a service that would behave like a normal draft enabled service leveraging the SAP Fiori Programming model we would not recommend to try it out.

Rather check out the following blogs whether these are helpful:

https://blogs.sap.com/2019/01/09/abap-programming-model-for-sap-fiori-draft-based-for-non-guid-keys-...

https://blogs.sap.com/2018/06/24/abap-programming-model-for-fiori-transactional-apps-with-draft-capa...

If this doesn't help, you can try out to built your app based on the below approach ,

you can create an app that persists the data in database tables.

Then you add an action that would then save the data into the "real" database tables.

So it would not automatically store the data and would not offer other draft capabilities but it would allow you to add some logic before "really" saving the data.

Hope this helps

Best Regards,

Abhirup

Ramjee_korada
Active Contributor
0 Likes

thanks Abhirup

mouradche
Explorer
0 Likes

Hi Abhirup,

Your answer is a copy of the one posted by Andre Fischer answering a different question in 2020

https://community.sap.com/t5/technology-q-a/draft-functionality-for-sap-free-style-app/qaq-p/1224067...

This answer doesn't fit the case exposed in this conversation. Ramjee dosent want to develop a service with Draft capabilities without using RAP or BOPF. He wanted to know if there is a possibility to consume Draft enabled service using Fiori Freestyle apps. And it's in fact possible although it's not as easy as in the non-draft scenario. One must manage switching between draft and non-draft contexts and manage the call of draft actions...etc 
MioYasutake gave an example of implementation 

Best regards