public void SaveChanges(Type typeBeingEdited) { _context.SaveChanges(); if (typeBeingEdited == typeof(Samurai)) { if (_context.Samurais.Local.Any()) { SamuraisListInMemory().ToList().ForEach(s => s.IsDirty = false); } } if (typeBeingEdited == typeof(Battle)) { if (_context.Battles.Local.Any()) { BattlesListInMemory().ToList().ForEach(s => s.IsDirty = false); } } }
public void SaveChanges(Type typeBeingEdited) { _context.SaveChanges(); }
public void SaveChanges() { _context.SaveChanges(); }