public void Do_not_build_documents_brefore_payer_registration_period() { filter.Period = DateTime.Now.AddMonths(-1).ToPeriod(); var invoices = filter.BuildInvoices(DateTime.Now); Assert.That(invoices.Any(i => i.Payer == payer), Is.False); }
public void Build([ARDataBind("buildFilter", AutoLoad = AutoLoadBehavior.NullIfInvalidKey)] DocumentBuilderFilter filter, DateTime invoiceDate, string printer) { var createdTime = DateTime.Now; filter.BuildInvoices(invoiceDate); Notify("Счета сформированы"); var destinationFilter = filter.ToDocumentFilter(); destinationFilter.CreatedOn = createdTime; RedirectToAction("Index", destinationFilter.GetQueryString()); }