public bool addShake(string name, string time) { var model = new Shake() { id = Guid.NewGuid(), username = name, shakeTime = DateTime.Parse(time), }; if (ShakeAccess.Exist(name)) { return(ShakeAccess.update(model)); } return(ShakeAccess.Add(model)); }
public List <Shake> getShakes(string name, string time) { ShakeAccess.DelOverdueData(DateTime.Parse(time)); return(ShakeAccess.GetShakes(name, DateTime.Parse(time))); }