public void DeleteProject(int id) { PROJECT project = _context.PROJECT.Find(id); _context.PROJECT.Remove(project); _context.SaveChanges(); }
public long UpdateAddProject(PROJECT project) { int result = -1; if (project != null) { _context.Entry(project).State = EntityState.Modified; _context.SaveChanges(); result = project.PROJECT_ID; } return(result); }
public long AddProject(PROJECT project) { int result = -1; if (project != null) { _context.PROJECT.Add(project); _context.SaveChanges(); result = project.PROJECT_ID; } return(result); }