Update models

This commit is contained in:
2023-04-28 13:01:43 +02:00
parent 351a0b8d57
commit 3f11a498bc
6 changed files with 82 additions and 3 deletions

View File

@ -165,9 +165,8 @@ namespace Elwig.Models {
public virtual ISet<Contract> Contracts { get; private set; }
[NotMapped]
public virtual ISet<Contract> ActiveContracts => Contracts
.Where(c => c.YearFrom <= Utils.CurrentSeason && (c.YearTo ?? int.MaxValue) >= Utils.CurrentSeason)
.ToHashSet();
public virtual IEnumerable<Contract> ActiveContracts => Contracts
.Where(c => c.YearFrom <= Utils.CurrentSeason && (c.YearTo ?? int.MaxValue) >= Utils.CurrentSeason);
[InverseProperty("Member")]
public virtual BillingAddr? BillingAddress { get; private set; }