private static void SetDateOffset(IChequeVouchersRepo chqsRepo) { var all = chqsRepo.GetAll(); foreach (var chq in all) { SetRequestOffset(chq.Request); } chqsRepo.DropAndInsert(all, false, true); }
private static void ProcessRequests(IChequeVouchersRepo repo) { foreach (var chk in repo.GetAll()) { if (IsBuggy(chk.Request, out AccountAllocation bdo1Alloc)) { FixBuggyAlloc(bdo1Alloc); if (!repo.Update(chk)) { throw new Exception("Check Update failed"); } } } }