I have class called Dossier which is my Base Class and a classes called PensioenDossier and AovDossier which inherits Dossier.
public partial class Dossier
{
public int ID { get; set; }
public int ProductID { get; set; }
public string Nummer { get; set; }
}
public partial class PensioenDossier : Dossier
{
public decimal Premie { get; set; }
public decimal? PartnerPensioen { get; set; }
}
public partial class AovDossier : Dossier
{
public decimal VerzekerdKapitaal { get; set; }
public decimal? MaandPremie { get; set; }
}
Now I have a process where I select a Product(Pensioen/AOV) and want to filter based on the selected Product. So I get the all Dossiers by
Context.Dossiers
I then filter on ProductID. And if its Pensioen I would like to filter on for example "Premie" and if it is AOV then I want to filter on "MaandPremie". But since I got Context.Dossiers I am wondering if it possible to filter on the derived class properties?