cancel
Showing results for 
Search instead for 
Did you mean: 

Binding MDK Cell Values to OData Entity Create action not working

maxime_cnl
Discoverer
0 Kudos

Hello!

I'm a bit at a loss here.

I'm working on an app using MDK, which is connected to a separate CAP service. The two of them are correctly connected, as I'm able to retrieve data and send queries to the service.

Now, I'm working on a page to create an entity, binding my page's fields to the action's properties. I don't know why, but not matter what I do it's acting as if there was no binding.

For example, when my service receives the request, it complains that the properties are empty. On the mobile side, I tried printing the action's result and it's the same: the properties are empty, despite being bind to the fields.

Even the UserId from the AppData is empty, and I don't understand what's at cause.

Accepted Solutions (0)

Answers (1)

Answers (1)

bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos

I would recommend turning on Mobile Network Trace and "Log Message Header and Message Body" to capture the traffic between the MDK client and the backend service.

You can also add a Set Debug Settings action to your MDK application to enable tracing of some of the categories like Odata.

maxime_cnl
Discoverer
0 Kudos

Thank you for your answer.

The problem is, the MDK application doesn't populate the properties' fields of the OData action at all. I checked the outgoing request and the fields are empty, despite being bound to the cells of the page I set up.

Even values bound to things other than cells (for example, retrieving the AppData UserId) end up being empty in the action. I also tried outputting the action's result and same thing, the properties are empty.

bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos

I would recommend setting the log level to trace and enabling all the tracing categories and then check the client log to see if there are any messages that would be helpful. I would also still recommend turning on the Mobile Network Trace in Mobile Services to capture exactly what is being sent to the backend to verify it is blank when sent from the client.

Is your application an offline or online connection to the service?