Exemplo n.º 1
0
 public static Lesson LessonConvertDAL(LessonDTO l)
 {
     return(new Lesson()
     {
         LessonId = l.LessonId,
         LessonName = l.LessonName,
         Describe = l.Describe,
         LessonSub = l.LessonSub,
         IdCourse = l.IdCourse,
         Link = l.Link
     });
 }
Exemplo n.º 2
0
        public static Lesson GetLesson(DTO.LessonDTO LessonDto)
        {
            Lesson Lesson = new Lesson();

            Lesson.LessonId       = LessonDto.LessonId;
            Lesson.ScheduleId     = LessonDto.ScheduleId;
            Lesson.Date           = LessonDto.Date;
            Lesson.LessonDescribe = LessonDto.LessonDescribe;
            Lesson.H_W            = LessonDto.H_W;

            return(Lesson);
        }
Exemplo n.º 3
0
        public static LessonDTO ConvertToDTO(Lesson lesson)
        {
            LessonDTO lessonDTO = new LessonDTO();

            lessonDTO.Id                      = lesson.Id;
            lessonDTO.Name                    = lesson.Name;
            lessonDTO.TeacherId               = lesson.TeacherId;
            lessonDTO.Day                     = lesson.Day;
            lessonDTO.StartHower              = lesson.StartHower;
            lessonDTO.FinishHower             = lesson.FinishHower;
            lessonDTO.MaxStudensNum           = lesson.MaxStudensNum;
            lessonDTO.MaxSerologersStudensNum = lesson.MaxSerologersStudensNum;
            lessonDTO.LessonKind              = lesson.LessonKind;
            return(lessonDTO);
        }
        public static Lesson ConvertFromDTO(LessonDTO lessonDTO)
        {
            Lesson lesson = new Lesson();

            lesson.Id                      = lessonDTO.Id;
            lesson.Name                    = lessonDTO.Name;
            lesson.TeacherId               = lessonDTO.TeacherId;
            lesson.Day                     = lessonDTO.Day;
            lesson.StartHower              = lessonDTO.StartHower;
            lesson.FinishHower             = lessonDTO.FinishHower;
            lesson.MaxStudensNum           = lessonDTO.MaxStudensNum;
            lesson.MaxSerologersStudensNum = lessonDTO.MaxSerologersStudensNum;

            return(lesson);
        }