Just tried the FluentMapper and found a problem with abstract properties. RepoDb.FluentMapper.Entity().DbType(e => e.CustomerTypeId, DbType.Int32);
Created by @SpaceOgre from #633.
My classes look like this
public abstract record Customer
{
public int Id { get; init; }
abstract public CustomerType CustomerTypeId { get; }
public string CustomerNumber { get; init; }
}
public record PrivateCustomer : Customer
{
public override CustomerType CustomerTypeId => CustomerType.Private;
public string SocialSecurityNumber { get; init; }
public string FirstName { get; init; }
public string LastName { get; init; }
public string ChangedBy { get; init; }
}
If I use the Attribute it works, but not the FluentMapper. If I remove abstract and change override to new then the FluentMapper works.
Just tried the FluentMapper and found a problem with abstract properties. RepoDb.FluentMapper.Entity().DbType(e => e.CustomerTypeId, DbType.Int32);
Created by @SpaceOgre from #633.
My classes look like this
If I use the Attribute it works, but not the FluentMapper. If I remove abstract and change override to new then the FluentMapper works.