public void AddOrUpdate(ProfileRealm profile, StudentRealm student) { if (student == null) { return; } this._studentRepository.AddOrUpdate(student, (Action <StudentRealm>)(s => s.ProfileId = profile.RolelessId)); }
public void Delete(StudentRealm student) { this._studentRepository.Remove(student); this._formteacherRepository.Remove(student.FormTeacher); foreach (TutelaryRealm tutelary in (IEnumerable <TutelaryRealm>)student.Tutelaries) { this._tutelaryRepository.Remove(tutelary); } }