Skip to Content

Sapui5 error 404 (not found) in CheckFlightAvailability function

Hi to all,

I'm a sapui5 begginer and I'm traying to do an odata call function with CheckFlightAvailability from sap gateway demo system. I'm using a default model for this exercise, but when I call function, it returns 404 as response, this is the code for my controller file:

I checked the network window on my browser and the metafile is loaded so I assume that my connection is ok, does anybody could help on this issue ?

Greetings,

Moisés.

code.png (19.7 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Jul 13, 2017 at 04:26 AM

    Hi Moises Gomez Quintero,

    Please try the following code to fetch the data.

    oODataModel.read("/CheckFlightAvailability",{
    success:function(odata){
    sap.m.MessageToast.show("success");
    }, error:function(oerror){ sap.m.MessageToast.show("error"); } })

    Regards

    GB

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      this call will give you details of all the flights, if you want to send filters then there is an option to add filters.

      regards

      GB

  • Jul 15, 2017 at 01:44 AM

    Issue solved, I corrected parameters declaration,

    Greetings

    Add comment
    10|10000 characters needed characters exceeded