public void RebuildSectionStudentRelationships(SectionStudentModel model)
 {
     _sectionsRepository.ClearSectionStudents(model.SectionId);
     _sectionsRepository.Save();
     _sectionsRepository.AssignStudents(model.SectionId, model.StudenstIds);
     _sectionsRepository.Save();
 }
 public IHttpActionResult PostReassignStudents(SectionStudentModel model)
 {
     _sectionServices.RebuildSectionStudentRelationships(model);
     return(Ok());
 }
 public IHttpActionResult PostRemoveStudents(SectionStudentModel model)
 {
     _sectionServices.RemoveStudents(model);
     return(Ok());
 }
 public bool RemoveStudents(SectionStudentModel model)
 {
     _sectionsRepository.RemoveStudents(model.SectionId, model.StudenstIds);
     _sectionsRepository.Save();
     return(true);
 }