Exemple #1
0
 public static List<Appointment> ListAppointments(bool? active)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcListAppointments(active).ToList();
     }
 }
Exemple #2
0
 public static BasicWorkshopWaiting GetWorkshopWaiting(int workshopId, string studentId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetWorkshopWaiting(workshopId, studentId).FirstOrDefault();
     }
 }
Exemple #3
0
 public static List<Campus> ListCampuses(bool? active)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcListCampuses(active).ToList();
     }
 }
Exemple #4
0
 public static List<SessionType> ListSessionTypes(bool? active)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcListSessionTypes(active).ToList();
     }
 }
Exemple #5
0
 public static BasicSession GetSession(int sessionId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetSession(sessionId).FirstOrDefault();
     }
 }
Exemple #6
0
 public static BasicSessionBooking GetSessionBooking(int sessionId, string studentId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetSessionBooking(sessionId, studentId).FirstOrDefault();
     }
 }
Exemple #7
0
 public static void CancelWorkshopBooking(int workshopId, string studentId, int userId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         ctx.prcCancelWorkshopBooking(workshopId, studentId, userId);
     }
 }
Exemple #8
0
 public static List<Lecturer> ListLecturers(bool? active)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcListLecturers(active).ToList();
     }
 }
Exemple #9
0
 public static List<BasicWorkshopWaiting> GetWorkshopWaitingList(int workshopId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetWorkshopWaitingList(workshopId).ToList();
     }
 }
Exemple #10
0
 public static BasicWorkshopBooking GetWorkshopBooking(int workshopId, string studentId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetWorkshopBooking(workshopId, studentId).FirstOrDefault(x => x.archived == null);
     }
 }
Exemple #11
0
 public static Workshop GetWorkshopDetail(int workshopId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetWorkshopDetail(workshopId).FirstOrDefault();
     }
 }
Exemple #12
0
 public static int?[] GetProgramWorkshops(int programId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetProgramWorkshops(programId).ToArray();
     }
 }
Exemple #13
0
 public static void CreateWorkshopWaiting(int workshopId, string studentId, int? priority, int userId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         ctx.prcCreateWorkshopWaiting(workshopId, studentId, priority, userId);
     }
 }
Exemple #14
0
 public static Student GetStudent(string studentId)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcGetStudent(studentId).FirstOrDefault();
     }
 }
Exemple #15
0
 public static List<WorkShopSet> ListWorkShopSets(bool? active)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcListWorkShopSets(active).ToList();
     }
 }
Exemple #16
0
 public static List<SessionBooking> SearchSessionBookings(SessionBookingSearch bookingSearch)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcSearchSessionBookings(bookingSearch.StudentId, bookingSearch.StartingDtBegin, bookingSearch.StartingDtEnd,
             bookingSearch.EndingDtBegin, bookingSearch.EndingDtEnd, bookingSearch.Campus,
             bookingSearch.LecturerId, bookingSearch.SessionTypeId, bookingSearch.Active,
             bookingSearch.Page, bookingSearch.PageSize).ToList();
     }
 }
Exemple #17
0
 public static void UpdateSessionBooking(UpdateSessionBooking update)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         ctx.prcUpdateSessionBooking(update.SessionId, update.StudentId, update.Cancel, update.Assistance,
             update.Reason, update.Attended, update.WaitingId, update.IsGroup, update.NumPeople,
             update.LecturerComment, update.LearningIssues, update.IsLocked, update.AssignType,
             update.AssignTypeOther, update.Subject, update.Appointments, update.AppointmentsOther,
             update.AssistanceText, update.UserId);
     }
 }
Exemple #18
0
        public static void RegisterStudent(StudentReg studentReg)
        {
            string gender = studentReg.Gender.HasValue ? studentReg.Gender.ToString() : null;

            using (HELPSEntities ctx = new HELPSEntities())
            {
                ctx.prcCreateStudent(studentReg.StudentId, studentReg.DateOfBirth, gender, studentReg.Degree.ToString(),
                    studentReg.Status.ToString(), studentReg.FirstLanguage, studentReg.CountryOrigin,
                    studentReg.Background,
                    studentReg.HSC, studentReg.HSCMark, studentReg.IELTS, studentReg.IELTSMark,
                    studentReg.TOEFL, studentReg.TOEFLMark, studentReg.TAFE, studentReg.TAFEMark,
                    studentReg.CULT, studentReg.CULTMark, studentReg.InsearchDEEP, studentReg.InsearchDEEPMark,
                    studentReg.InsearchDiploma, studentReg.InsearchDiplomaMark, studentReg.FoundationCourse,
                    studentReg.FoundationCourseMark,
                    studentReg.CreatorId, studentReg.DegreeDetails, studentReg.AltContact, studentReg.PreferredName);
            }
        }
Exemple #19
0
 public static void UpdateWorkshopBooking(UpdateWorkshopBooking update)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         ctx.prcUpdateWorkshopBooking(update.WorkshopId, update.StudentId,
             update.Canceled, update.Attended, update.UserId, update.Notes);
     }
 }
Exemple #20
0
 public static List<Workshop> SearchWorkshops(WorkshopSearch workshopSearch)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcSearchWorkshops(workshopSearch.WorkshopSetId, workshopSearch.Topic,
             workshopSearch.StartingDtBegin, workshopSearch.StartingDtEnd, workshopSearch.EndingDtBegin,
             workshopSearch.EndingDtEnd, workshopSearch.CampusId, workshopSearch.Active, workshopSearch.Page,
             workshopSearch.PageSize).ToList();
     }
 }
Exemple #21
0
 public static List<WorkshopBooking> SearchWorkshopBookings(WorkshopBookingSearch bookingSearch)
 {
     using (HELPSEntities ctx = new HELPSEntities())
     {
         return ctx.prcSearchWorkshopBookings(bookingSearch.StudentId,
                 bookingSearch.StartingDtBegin, bookingSearch.StartingDtEnd,
                 bookingSearch.EndingDtBegin, bookingSearch.EndingDtEnd, bookingSearch.CampusId,
                 bookingSearch.Active, bookingSearch.Page, bookingSearch.PageSize).ToList();
     }
 }