public void SaveLong(ConfigPropertiesLong stat) { using (var context = new ShardDbContext()) { context.Entry(stat).State = EntityState.Modified; context.SaveChanges(); } }
public void AddLong(string key, long value, string description = null) { var stat = new ConfigPropertiesLong { Key = key, Value = value, Description = description }; using (var context = new ShardDbContext()) { context.ConfigPropertiesLong.Add(stat); context.SaveChanges(); } }