-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide support for JsonPropertyName attribute #99
Comments
Helper method for getting attribute value:
|
JsonPropertyNameAttribute - I would like to avoid this dependency in this library. |
Could I suggest a similar approach to how Entity Framework does it with it's Fluent API Configuration? Example: public class SomeEntityConfiguration : IEntityTypeConfiguration<SomeEntity>
{
public void Configure(EntityTypeBuilder<SomeEntity> entity)
{
entity
.Property(e => e.Id)
.HasColumnName("entity_id");
}
} and then in the DbContext:
This keeps the entity classes clean of configuration logic. Also I believe this is a much desired feature, at least for me. The odata endpoint that you're implementing might be casing the entities and properties differently then how you might want to case them in your code. I see this as an urgent feature :) PS: the ability to do the same for the entity name itself would be a bonus. This way we can avoid |
FYI: There is a json independent attribute |
Output:
../bookings?$expand=BookingLines
Desired output:
../bookings?$expand=bookinglines
Please add support for respecting and applying name specified in
JsonPropertyName
attribute. Possibly as configuration as setting?The text was updated successfully, but these errors were encountered: