public void UpdateExpense(CrewExpense crewExpense) { var attachedCrewExpense = CrewExpenseses.Find(crewExpense.Id); Entry(attachedCrewExpense).CurrentValues.SetValues(crewExpense); SaveChanges(); }
public void AddExpense(CrewExpense crewExpense) { CrewExpenseses.Add(crewExpense); SaveChanges(); }