public void StopWorker(string project) { var data = WorkData.WorkData.ToList().First(w => w.Project.IDProject == int.Parse(project)); data.Status = 1; data.Date = WorkData.Date; Hour.CreateUpdate(data); }
public void UpdateWorker(string project, string worktime, string overtime) { var data = WorkData.WorkData.ToList().First(w => w.Project.IDProject == int.Parse(project)); data.Status = 3; data.Worktime = TimeSpan.Parse(worktime); data.Overtime = TimeSpan.Parse(overtime); data.Date = WorkData.Date; Hour.CreateUpdate(data); }