Skip to Content

Backend service is not hitting breakpoint

Hi Experts,

I have one Gateway service which I wanted to use PUT method so that data what ever send from frontend can be saved using Method "ORDERINFO_HSET_UPDATE_ENTITY" of my Service Implementation.

I have written below code in

When I run this code I get below error:

In simple words I wanted to send data from Frontend using HTTP Method PUT so that I can use "UPDATE_ENTITY" method.

When I run Service from Gateway using PUT method passing two parameter it hits to "UPDATE_ENTITY" method but not from Frontend.

Please help me .

Thanks-

Abhishek

errorcode.PNG (26.5 kB)
error.PNG (9.7 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Nov 02, 2015 at 05:21 PM

    Hi Abhishek,

    You need to provide those parameters as you did in Gateway along with the path in Update mode, something like this:

    update("/ORDERINFO_HSet(par1=' "+ val1 +" ',par2=' " +val2 +" ')",oEntry,null)

    Hope this helps.

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 02, 2015 at 06:14 PM

    if you wanna use that old ugly format of

    https://sapui5.netweaver.ondemand.com/sdk/#docs/api/symbols/sap.ui.model.odata.ODataModel.html#update

    you have to pass 2 more parameters: success and error functions, like

    .update("...", oEntry, null, function(){}, function(){})

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Abhishek Sharma

      Hi,

      Are you testing this from WebIDE ?

      If so, Can you check your neo-app.json file contains the following destination(Back end destination Configuration).

      {

        "path": "/destinations/<DestinationName>",

        "target": {

        "type": "destination",

        "name": "<DestinationName>"

        },

        "description": "GatewaySystem"

      Then your oModel initialization in the component.js should have the service URL in the following format,

      var sServiceUrl = "/destinations/<DestinationName>/sap/opu/odata/sap/<YourServiceName>/";

      this.oModel = new sap.ui.model.odata.ODataModel(sServiceUrl);

      Thanks,

      Rumeshbabu S

  • Nov 03, 2015 at 12:57 AM

    Thanks Kedar, Dominik and Maksim for helping me.

    Thanks-

    Abhishek

    Add comment
    10|10000 characters needed characters exceeded