cancel
Showing results for 
Search instead for 
Did you mean: 

How to send data from sapui5 to R3 system?

former_member231869
Participant
0 Kudos
440

Hi...i want to send data from sapui5 to R3 system.

1. i have 1 table in R3 system from there i am able retrive the data through odata into my sapui5 application.

2.Now i want set flag in that table when user click on the button

plz all just guide me how to achive this scenario..

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

You can make use of Update method of OData service.Implement Update method in the service.

this may help

Update data in SAP Backend using OData Service | sap abap | sapui5 made easy

Regards

vijay_kumar49
Active Contributor
0 Kudos

Read the data from UI5 screen and send it OData as per below example code.

var oSalesOffice = this.getView().byId("VKBUR_id").getValue();

var oSalesGroup = this.getView().byId("VKGRP_id").getValue();

var uploadQuoteData = {               

                "VKBUR": oSalesOffice,

                "VKGRP": oSalesGroup

            };

// Set Data to ODataModel

this.getView().getModel("Model Alias Name").create('/EntitySet', uploadQuoteData, {

                success: function(uploadQuoteData) {

                    sap.m.MessageBox.show("Quotation Uploaded successfully ",{

                        icon: sap.m.MessageBox.Icon.SUCCESS,

                        title: "Success",

                        actions: [sap.m.MessageBox.Action.OK],                                 

                        onClose: function(oAction) {

                                      // Close the window.

                                }

                    });

                },

                error: function(oError) {

                    sap.m.MessageBox.show(JSON.stringify(oError.message),{

                                  icon: sap.m.MessageBox.Icon.ERROR,

                                  title: "Error",

                                  actions: [sap.m.MessageBox.Action.OK]                                 

                                });

                   

                }

            });

Regards

Vijay