123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using EMIS.ViewModel.CacheManage;
- using System.ComponentModel;
- using System.ComponentModel.DataAnnotations;
- using EMIS.Entities;
- using EMIS.ViewModel.EducationManagement;
- namespace EMIS.ViewModel.EducationSchedule
- {
- public class ScheduleStopEditView
- {
- public Guid? EducationSchedulingID { get; set; }
- public Guid? EducationSchedulingWeekNumID { get; set; }
- public Guid EducationMissionClassID { get; set; }
- public Guid? SchoolyearID { get; set; }
- public string EducationMissionClassName { get; set; }
- public Guid? CoursematerialID { get; set; }
- public string CourseCode { get; set; }
- public string CourseName { get; set; }
- public int? EducationMissionClassStartWeekNum { get; set; }
- public int? EducationMissionClassEndWeekNum { get; set; }
- public List<int?> EducationMissionClassWeekNumList
- {
- get
- {
- List<int?> weekList = new List<int?>();
- for (var i = this.EducationMissionClassStartWeekNum; i <= this.EducationMissionClassEndWeekNum; i++)
- {
- weekList.Add(i);
- }
- return weekList;
- }
- }
- public Guid? UserID { get; set; }
- public string UserName { get; set; }
- public int? WeekNum { get; set; }
- public int? Weekday { get; set; }
- public string WeekdayDesc
- {
- get
- {
- return WeekDayView.GetWeekdayName(Weekday);
- }
- }
- public int? TimesSegment { get; set; }
- public string TimesSegmentDesc
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.CF_TimesSegment.ToString())
- .Where(x => x.Value == TimesSegment)
- .Select(x => x.Name).FirstOrDefault();
- }
- }
- public Guid? CoursesTimeID { get; set; }
- public int? StartHour { get; set; }
- public int? StartMinutes { get; set; }
- public int? EndHour { get; set; }
- public int? EndMinutes { get; set; }
- [Required(ErrorMessage = "请填写要调整到星期几")]
- public int? ToWeekday { get; set; }
- [Required(ErrorMessage = "请填写要调整到哪一节")]
- public Guid? ToCoursesTimeID { get; set; }
- public string CoursesTimeName
- {
- get
- {
- return (StartHour ?? 0).ToString().PadLeft(2, '0')
- + ":"
- + (StartMinutes ?? 0).ToString().PadLeft(2, '0')
- + "-"
- + (EndHour ?? 0).ToString().PadLeft(2, '0')
- + ":"
- + (EndMinutes ?? 0).ToString().PadLeft(2, '0');
- }
- }
- public int? ClassroomTypeID { get; set; }
- public string ClassroomTypeName
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.CF_ClassroomType.ToString())
- .Where(x => x.Value == ClassroomTypeID)
- .Select(x => x.Name).FirstOrDefault();
- }
- }
- public int? ToClassroomTypeID { get; set; }
- public string ToClassroomTypeName
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.CF_ClassroomType.ToString())
- .Where(x => x.Value == ToClassroomTypeID)
- .Select(x => x.Name).FirstOrDefault();
- }
- }
- public Guid? ClassroomID { get; set; }
- public string ClassroomName { get; set; }
- [Required(ErrorMessage = "请填写要调整后的教室")]
- public Guid? ToClassroomID { get; set; }
- public int? ToWeekNum { get; set; }
- public Guid? ToUserID { get; set; }
- public string CollegeName { get; set; }
- public IEnumerable<MissionClassTeacherView> TeacherList { get; set; }
- public string TeacherNames
- {
- get
- {
- string name = string.Empty;
- if (TeacherList != null)
- name = string.Join(",", TeacherList.Select(s => s.Name));
- if (string.IsNullOrEmpty(name))
- {
- return "";
- }
- else
- {
- return name;
- }
- }
- }
- }
- }
|