public void AddTestPassing(TestPassing testPassing) { using (var context = new FinalProjectDBEntities1()) { context.TestPassings.Add(testPassing); } }
public void DeleteTestPassing(int Id) { using (var context = new FinalProjectDBEntities1()) { TestPassing testPassing = context.TestPassings.Find(Id); context.TestPassings.Remove(testPassing); } }
public static TestPassingDto ToTestPassingDto(this TestPassing testPassing) { if (testPassing == null) { return(null); } var testPassingDto = new TestPassingDto { Id = testPassing.Id, Date = testPassing.Date.Value }; return(testPassingDto); }