예제 #1
0
 public static void UpdateClaimFeeIfRequired(this Claim claim, DateTime operationDate)
 {
     if (claim.Project.ProjectFeeSettings.Any() && //If project has fee
         claim.CurrentFee == null && //and fee not already fixed for claim
         claim.ClaimPaidInFull(operationDate)    //and current fee is payed in full
         )
     {
         claim.CurrentFee = claim.ProjectFeeForDate(operationDate); //fix fee for claim
     }
 }