[Question] Does this work with odata API?
Will the dynamic entity(s) show up in the EDM out of the box? Or is there additional work required?
Hello, I am late and have not done any operation for the EDM of OData.
private static IEdmModel GetEdmModel()
{
var builder = new ODataConventionModelBuilder();
builder.EntitySet<Book>("Books");
return builder.GetEdmModel();
}
<edmx:Edmx xmlns:edmx="http://docs.oasis-open.org/odata/ns/edmx" Version="4.0">
<edmx:DataServices>
<Schema xmlns="http://docs.oasis-open.org/odata/ns/edm" Namespace="Default">
<EntityType Name="Book">
<Key>
<PropertyRef Name="Id"/>
</Key>
<Property Name="Id" Type="Edm.Int32" Nullable="false"/>
</EntityType>
</EntityContainer>
</Schema>
</edmx:DataServices>
</edmx:Edmx>
As shown above, what you said way of EDM is introduced into?
Hello, let me try to clarify. Let's say the Book entity is a dynamic entity. Just like the computer entity in your sample project. It would be really sweet if you could use that computer model in the API just like a regular model. So you could create add a new computer to the database by doing a post to /api/Computer
Hi @sNakiex, the DynamicEntity module doesn't have separated HTTP APIs for each entity.
DynamicEntityAppService provides unified APIs for them.
But I'm sure you'll be interested in the EntityUi module, which provides real-time generated CRUD pages. It supports traditional entities and dynamic entities.
See: https://github.com/EasyAbp/Abp.EntityUi
Sorry for the late response, I haven't really had a lot of free time ^^ Would it be worthwhile to invest some time into researching if this is possible?