asp.net web api2 - Web API OData ignore properties added by client-side -


When I call my server using the WebAPI Odata v4 call I get no error. {"Code": "code": "" "message": ": message": "work: property 'test type' is not present on 'model request is invalid", "Innererror." Be sure to use {{. "Temporary" property only names that are defined by type. \ R \ n "," type .. ":" "" StackTrace ":" "}}}

This error occurs because the property "test" model is not set to "Temp". It is actually added by Javascript, and used only in client-side

I have so much That OData will not pay attention to the properties that are not available in the model.

There is a way to deal with your scenario. It is not to ignore the properties, but to define the entity type as an open type, it is not acceptable to accept dynamic properties that are not defined in the model from the client, and if necessary, the future They store them for inquiry.

You can find the following tutorials for applying Open Type support:

Comments

Popular posts from this blog

java - ImportError: No module named py4j.java_gateway -

python - Receiving "KeyError" after decoding json result from url -

C++ Array Type Not Assignable in Copy Constructor -