Skip to content

Inheritance support #598

Closed
Closed
@sebafelis

Description

@sebafelis

Description

Entity Framework Core Inheritance is not fully support now. It’s support only if for each inherited type is created separeate DBSet in DbContext. But if inheritance is define by FluentAPI then we can’t use this because Resource name is presently inseparable with type property in returning JSON.

Solution

I suggest adding a second string parameter (entityName) to ResourceAttribute and to AddResource method in ContextGraphBuilder. It allows to separate resource name and entity type and provides support for EF Core inheritance.

Environment

  • JsonApiDotNetCore Version: v4.0.0-alpha3
  • Entity Framework Core Versions: 2.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions