예제 #1
0
        public StudentLecturerEntity Update(UserEntity userEntity, Guid StudentId, StudentLecturerEntity studentLectureEntity)
        {
            StudentLecturer studentLecturer = IMSContext.StudentLecturers.Where(sl => sl.StudentId == StudentId).FirstOrDefault();

            studentLectureEntity.ToModel(studentLecturer);
            IMSContext.SaveChanges();
            return(null);
        }
예제 #2
0
        public StudentLecturerEntity Create(UserEntity userEntity, StudentLecturerEntity studentLecturerEntity)
        {
            StudentLecturer studentLecturer = studentLecturerEntity.ToModel();

            IMSContext.StudentLecturers.Add(studentLecturer);
            IMSContext.SaveChanges();
            return(studentLecturerEntity);
        }
예제 #3
0
 public StudentLecturerEntity Update(Guid StudentId, [FromBody] StudentLecturerEntity studentLecturerEntity)
 {
     return(StudentLecturerService.Update(UserEntity, StudentId, studentLecturerEntity));
 }
예제 #4
0
 public StudentLecturerEntity Create([FromBody] StudentLecturerEntity studentLectureEntity)
 {
     return(StudentLecturerService.Create(UserEntity, studentLectureEntity));
 }