Esempio n. 1
0
 public AttendanceClass1Helper(API.LABURNUM.COM.AttendanceClass1 Class)
 {
     if (Class == null)
     {
         throw new Exception(API.LABURNUM.COM.Component.Constants.ERRORMESSAGES.PARAMETER_CANNOT_BE_NULL);
     }
     ;
     this.AttendanceClass1 = new List <API.LABURNUM.COM.AttendanceClass1>();
     this.AttendanceClass1.Add(Class);
 }
Esempio n. 2
0
 private DTO.LABURNUM.COM.AttendanceClass1Model MapCore(API.LABURNUM.COM.AttendanceClass1 apiclass)
 {
     DTO.LABURNUM.COM.AttendanceClass1Model dtoClass = new DTO.LABURNUM.COM.AttendanceClass1Model()
     {
         AttendanceClass1Id    = apiclass.AttendanceClass1Id,
         ClassId               = apiclass.ClassId,
         SectionId             = apiclass.SectionId,
         StudentId             = apiclass.StudentId,
         MorningAttendanceDate = apiclass.MorningAttendanceDate,
         LunchAttendanceDate   = apiclass.LunchAttendanceDate.GetValueOrDefault().Year != 0001 ? apiclass.LunchAttendanceDate : null,
         IsPresentAfterLuch    = apiclass.IsPresentAfterLuch,
         IsPresentInMorning    = apiclass.IsPresentInMorning,
         CreatedOn             = apiclass.CreatedOn,
         IsActive              = apiclass.IsActive,
         LastUpdated           = apiclass.LastUpdated,
         StudentName           = apiclass.Student.FirstName + " " + apiclass.Student.MiddleName + " " + apiclass.Student.LastName,
         FatherName            = apiclass.Student.FatherName,
         AttendanceId          = apiclass.AttendanceClass1Id,
     };
     return(dtoClass);
 }