public void Save(MarketAuditViewModel marketAuditViewModel) { MarketAudit marketAudit = new MarketAudit(marketAuditViewModel.Id) { Question=marketAuditViewModel.Question, StartDate=marketAuditViewModel.StartDate, EndDate=marketAuditViewModel.EndDate }; _marketAuditRepository.Save(marketAudit ); }
private void AssertMarketAudit(MarketAudit infection, MarketAudit savedInfection) { Assert.AreEqual(infection.Question, savedInfection.Question); Assert.AreEqual(infection.StartDate, savedInfection.StartDate); Assert.AreEqual(infection.EndDate, savedInfection.EndDate); Assert.AreEqual(infection._Status, savedInfection._Status); }
MarketAuditViewModel Map(MarketAudit marketAudit) { return new MarketAuditViewModel { Id = marketAudit.Id, Question = marketAudit.Question, StartDate = marketAudit.StartDate, EndDate = marketAudit.EndDate, IsActive = marketAudit._Status == EntityStatus.Active ? true : false }; }