public void ConvertSubjectAssignmentToSubjectAssignmentBDO(SubjectAssignment sa, SubjectAssignmentBDO sabdo)
        {
            sabdo.Deactivated = (bool)sa.Deactivated;
            GradeSectionDAO gd = new GradeSectionDAO();
            GradeSectionBDO g = new GradeSectionBDO();
            g = gd.GetGradeSectionBDO((int)sa.GradeSectionCode);
            sabdo.GradeSection = g;
            sabdo.GradeSectionCode = g.GradeSectionCode;
            RoomBDO r = new RoomBDO();
            RoomDAO rd = new RoomDAO();
            rd.ConvertRoomToRoomBDO(sa.Room, r);
            sabdo.Room = r;
            sabdo.RoomId = r.RoomId;
            SubjectDAO sd = new SubjectDAO();
            SubjectBDO sb = new SubjectBDO();
            sd.ConvertSubjectToSubjectBDO(sa.Subject, sb);
            sabdo.Subject = sb;
            sabdo.SubjectAssignmentsID = sa.SubjectAssignmentsID;
            sabdo.SubjectCode = sa.SubjectCode;
            sabdo.SY = sa.SY;
            TeacherDAO td = new TeacherDAO();
            TeacherBDO tb = new TeacherBDO();
            td.ConvertTeacherToTeacherBDO(sa.Teacher, tb);
            sabdo.Teacher = tb;
            sabdo.TeacherId = tb.TeacherId;
            TimeslotDAO tid = new TimeslotDAO();
            TimeslotBDO tib = new TimeslotBDO();
            tid.ConvertTimeslotToTimeslotBDO(sa.Timeslot, tib);
            sabdo.Timeslot = tib;
            sabdo.TimeSlotCode = tib.TimeSlotCode;

            sabdo.GradeLevel = g.GradeLevel;
        }
Exemple #2
0
 public void ConvertLearningAreaBDOToLearningArea(LearningAreaBDO labdo, LearningArea la)
 {
     SubjectDAO sdao = new SubjectDAO();
     la.Academic = labdo.Academic;
     la.Description = labdo.Description;
     la.LearningAreaCode = labdo.LearningAreaCode;
     la.Units = labdo.Units;
     la.RatePerUnit = labdo.RatePerUnit;
     la.Subjects = sdao.ToSubjectList(labdo.Subjects);
 }
Exemple #3
0
        public void ConvertLearningAreaBDOToLearningArea(LearningAreaBDO labdo, LearningArea la)
        {
            SubjectDAO sdao = new SubjectDAO();

            la.Academic         = labdo.Academic;
            la.Description      = labdo.Description;
            la.LearningAreaCode = labdo.LearningAreaCode;
            la.Units            = labdo.Units;
            la.RatePerUnit      = labdo.RatePerUnit;
            la.Subjects         = sdao.ToSubjectList(labdo.Subjects);
        }
Exemple #4
0
        public ICollection <Subject> ToSubjectList(List <SubjectBDO> slist)
        {
            SubjectDAO            sd          = new SubjectDAO();
            ICollection <Subject> subjectList = new List <Subject>();

            foreach (SubjectBDO sbdo in slist)
            {
                Subject subject = new Subject();
                sd.ConvertSubjectBDOToSubject(sbdo, subject);
                subjectList.Add(subject);
            }
            return(subjectList);
        }
Exemple #5
0
        public List <SubjectBDO> ToSubjectBDOList(ICollection <Subject> slist)
        {
            SubjectDAO        sd       = new SubjectDAO();
            List <SubjectBDO> sbdoList = new List <SubjectBDO>();

            foreach (Subject s in slist)
            {
                SubjectBDO sbdo = new SubjectBDO();
                sd.ConvertSubjectToSubjectBDO(s, sbdo);
                sbdoList.Add(sbdo);
            }
            return(sbdoList);
        }
        public void ConvertStuSubjectsToStuSubjectsBDO(StudentSubject s, StudentSubjectBDO sbdo)
        {
            StudentEnrolmentDAO  sed  = new StudentEnrolmentDAO();
            StudentEnrollmentBDO sedb = new StudentEnrollmentBDO();

            sed.ConvertEnrolToEnrolBDO(s.StudentEnrollment, sedb);
            sbdo.StudentEnrollment = sedb;

            StudentDAO sd = new StudentDAO();
            StudentBDO sb = new StudentBDO();

            sd.ConvertStudentToStudentBDO(s.StudentEnrollment.Student, sb);
            sbdo.StudentEnrollment.Student = sb;

            SubjectDAO subd = new SubjectDAO();
            SubjectBDO sbo  = new SubjectBDO();

            subd.ConvertSubjectToSubjectBDO(s.Subject, sbo);
            sbdo.Subject = sbo;

            sbdo.StudentSY         = s.StudentSY;
            sbdo.SubjectCode       = s.SubjectCode;
            sbdo.StudentSubjectsID = s.StudentSubjectsID;
            sbdo.StudentEnrSubCode = s.StudentEnrSubCode;
            sbdo.Remarks           = s.Remarks;

            sbdo.FirstPeriodicRating  = s.FirstPeriodicRating;
            sbdo.SecondPeriodicRating = s.SecondPeriodicRating;
            sbdo.ThirdPeriodicRating  = s.ThirdPeriodicRating;
            sbdo.FourthPeriodicRating = s.FourthPeriodicRating;

            sbdo.StudentEnrSubCode = s.StudentEnrSubCode;

            sbdo.SubjectAssignments = s.SubjectAssignments;

            sbdo.FirstEntered  = s.FirstEntered;
            sbdo.SecondEntered = s.SecondEntered;
            sbdo.FourthEntered = s.FourthEntered;
            sbdo.ThirdEntered  = s.ThirdEntered;

            sbdo.LockFirst  = s.LockFirst;
            sbdo.LockSecond = s.LockSecond;
            sbdo.LockThird  = s.LockThird;
            sbdo.LockFourth = s.LockFourth;

            sbdo.FirstLocked  = s.FirstLocked;
            sbdo.SecondLocked = s.SecondLocked;
            sbdo.ThirdLocked  = s.ThirdLocked;
            sbdo.FourthLocked = s.FourthLocked;
        }
Exemple #7
0
        public void ConvertStuSubjectsToStuSubjectsBDO(StudentSubject s, StudentSubjectBDO sbdo)
        {
            StudentEnrolmentDAO sed = new StudentEnrolmentDAO();
            StudentEnrollmentBDO sedb = new StudentEnrollmentBDO();
            sed.ConvertEnrolToEnrolBDO(s.StudentEnrollment, sedb);
            sbdo.StudentEnrollment = sedb;

            StudentDAO sd = new StudentDAO();
            StudentBDO sb = new StudentBDO();
            sd.ConvertStudentToStudentBDO(s.StudentEnrollment.Student, sb);
            sbdo.StudentEnrollment.Student = sb;

            SubjectDAO subd = new SubjectDAO();
            SubjectBDO sbo = new SubjectBDO();
            subd.ConvertSubjectToSubjectBDO(s.Subject, sbo);
            sbdo.Subject = sbo;

            sbdo.StudentSY = s.StudentSY;
            sbdo.SubjectCode = s.SubjectCode;
            sbdo.StudentSubjectsID = s.StudentSubjectsID;
            sbdo.StudentEnrSubCode = s.StudentEnrSubCode;
            sbdo.Remarks = s.Remarks;

            sbdo.FirstPeriodicRating = s.FirstPeriodicRating;
            sbdo.SecondPeriodicRating = s.SecondPeriodicRating;
            sbdo.ThirdPeriodicRating = s.ThirdPeriodicRating;
            sbdo.FourthPeriodicRating = s.FourthPeriodicRating;

            sbdo.StudentEnrSubCode = s.StudentEnrSubCode;

            sbdo.SubjectAssignments = s.SubjectAssignments;

            sbdo.FirstEntered = s.FirstEntered;
            sbdo.SecondEntered = s.SecondEntered;
            sbdo.FourthEntered = s.FourthEntered;
            sbdo.ThirdEntered = s.ThirdEntered;

            sbdo.LockFirst = s.LockFirst;
            sbdo.LockSecond = s.LockSecond;
            sbdo.LockThird = s.LockThird;
            sbdo.LockFourth = s.LockFourth;

            sbdo.FirstLocked = s.FirstLocked;
            sbdo.SecondLocked = s.SecondLocked;
            sbdo.ThirdLocked = s.ThirdLocked;
            sbdo.FourthLocked = s.FourthLocked;
        }
        private List<CurriculumSubjectBDO> ToCurriculumSubjectBDOList(List<CurriculumSubject> csList)
        {
            List<CurriculumSubjectBDO> csbdoList = new List<CurriculumSubjectBDO>();
            foreach (CurriculumSubject cs in csList)
            {
                SubjectDAO sDAO = new SubjectDAO();
                SubjectBDO sbdo = new SubjectBDO();
                CurriculumSubjectBDO csbdo = new CurriculumSubjectBDO();
                csbdo.CurriculumCode = cs.CurriculumCode;
                csbdo.CurrSubCode = cs.CurrSubCode;
                csbdo.Deactivated = cs.Deactivated;
                csbdo.SubjectCode = cs.SubjectCode;
                sbdo = sDAO.GetSubject(cs.SubjectCode);

                csbdo.Sub = sbdo;
                csbdoList.Add(csbdo);
            }
            return csbdoList;
        }
Exemple #9
0
        private List <CurriculumSubjectBDO> ToCurriculumSubjectBDOList(List <CurriculumSubject> csList)
        {
            List <CurriculumSubjectBDO> csbdoList = new List <CurriculumSubjectBDO>();

            foreach (CurriculumSubject cs in csList)
            {
                SubjectDAO           sDAO  = new SubjectDAO();
                SubjectBDO           sbdo  = new SubjectBDO();
                CurriculumSubjectBDO csbdo = new CurriculumSubjectBDO();
                csbdo.CurriculumCode = cs.CurriculumCode;
                csbdo.CurrSubCode    = cs.CurrSubCode;
                csbdo.Deactivated    = cs.Deactivated;
                csbdo.SubjectCode    = cs.SubjectCode;
                sbdo = sDAO.GetSubject(cs.SubjectCode);

                csbdo.Sub = sbdo;
                csbdoList.Add(csbdo);
            }
            return(csbdoList);
        }
Exemple #10
0
        public ICollection <Subject> ToSubjectList(List <SubjectBDO> slist)
        {
            SubjectDAO            sd          = new SubjectDAO();
            ICollection <Subject> subjectList = new List <Subject>();

            foreach (SubjectBDO sbdo in slist)
            {
                Subject subject = new Subject();
                sd.ConvertSubjectBDOToSubject(sbdo, subject);
                subjectList.Add(subject);
            }
            return(subjectList);
            //SubjectDAO sd = new SubjectDAO();
            //ICollection<Subject> sList = new List<Subject>();
            //foreach (SubjectBDO sbdo in slist)
            //{
            //    Subject s = new Subject();
            //    sd.ConvertSubjectToSubjectBDO(s, sbdo);
            //    sList.Add(s);
            //}
            //return sList;
        }
        public void ConvertSubjectAssignmentToSubjectAssignmentBDO(SubjectAssignment sa, SubjectAssignmentBDO sabdo)
        {
            sabdo.Deactivated = (bool)sa.Deactivated;
            GradeSectionDAO gd = new GradeSectionDAO();
            GradeSectionBDO g  = new GradeSectionBDO();

            g = gd.GetGradeSectionBDO((int)sa.GradeSectionCode);
            sabdo.GradeSection     = g;
            sabdo.GradeSectionCode = g.GradeSectionCode;
            RoomBDO r  = new RoomBDO();
            RoomDAO rd = new RoomDAO();

            rd.ConvertRoomToRoomBDO(sa.Room, r);
            sabdo.Room   = r;
            sabdo.RoomId = r.RoomId;
            SubjectDAO sd = new SubjectDAO();
            SubjectBDO sb = new SubjectBDO();

            sd.ConvertSubjectToSubjectBDO(sa.Subject, sb);
            sabdo.Subject = sb;
            sabdo.SubjectAssignmentsID = sa.SubjectAssignmentsID;
            sabdo.SubjectCode          = sa.SubjectCode;
            sabdo.SY = sa.SY;
            TeacherDAO td = new TeacherDAO();
            TeacherBDO tb = new TeacherBDO();

            td.ConvertTeacherToTeacherBDO(sa.Teacher, tb);
            sabdo.Teacher   = tb;
            sabdo.TeacherId = tb.TeacherId;
            TimeslotDAO tid = new TimeslotDAO();
            TimeslotBDO tib = new TimeslotBDO();

            tid.ConvertTimeslotToTimeslotBDO(sa.Timeslot, tib);
            sabdo.Timeslot     = tib;
            sabdo.TimeSlotCode = tib.TimeSlotCode;

            sabdo.GradeLevel = g.GradeLevel;
        }
 public ICollection<Subject> ToSubjectList(List<SubjectBDO> slist)
 {
     SubjectDAO sd = new SubjectDAO();
     ICollection<Subject> subjectList = new List<Subject>();
     foreach (SubjectBDO sbdo in slist)
     {
         Subject subject = new Subject();
         sd.ConvertSubjectBDOToSubject(sbdo, subject);
         subjectList.Add(subject);
     }
     return subjectList;
     //SubjectDAO sd = new SubjectDAO();
     //ICollection<Subject> sList = new List<Subject>();
     //foreach (SubjectBDO sbdo in slist)
     //{
     //    Subject s = new Subject();
     //    sd.ConvertSubjectToSubjectBDO(s, sbdo);
     //    sList.Add(s);
     //}
     //return sList;
 }
 public List<SubjectBDO> ToSubjectBDOList(ICollection<Subject> slist)
 {
     SubjectDAO sd = new SubjectDAO();
     List<SubjectBDO> sbdoList = new List<SubjectBDO>();
     foreach (Subject s in slist)
     {
         SubjectBDO sbdo = new SubjectBDO();
         sd.ConvertSubjectToSubjectBDO(s, sbdo);
         sbdoList.Add(sbdo);
     }
     return sbdoList;
 }
Exemple #14
0
  public ICollection<Subject> ToSubjectList(List<SubjectBDO> slist)
  {
      SubjectDAO sd = new SubjectDAO();
      ICollection<Subject> subjectList = new List<Subject>();
      foreach (SubjectBDO sbdo in slist)
      {
          Subject subject = new Subject();
          sd.ConvertSubjectBDOToSubject(sbdo, subject);
          subjectList.Add(subject);
      }
      return subjectList;
 
  }