public void Delete(LastUserSettings lastUserSettings) { try { db.Entry(lastUserSettings).State = EntityState.Deleted; db.SaveChanges(); } catch (Exception ex) { Log.Error(ex.Message, ex); } }
public void Insert(LastUserSettings lastUserSettings) { try { db.LastUserSettings.Add(lastUserSettings); db.SaveChanges(); } catch (Exception ex) { Log.Error(ex.Message, ex); } }