EducationSchedulingView.cs 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using EMIS.ViewModel.CalendarManage;
  6. using EMIS.ViewModel.CacheManage;
  7. using Bowin.Common.Utility;
  8. using EMIS.ViewModel.EducationManage;
  9. namespace EMIS.ViewModel.EducationSchedule
  10. {
  11. public class EducationSchedulingView
  12. {
  13. /// <summary>
  14. /// 排课课表ID
  15. /// </summary>
  16. public System.Guid EducationSchedulingID { get; set; }
  17. /// <summary>
  18. /// 学年学期
  19. /// </summary>
  20. public Nullable<System.Guid> SchoolyearID { get; set; }
  21. /// <summary>
  22. /// 学年学期
  23. /// </summary>
  24. public string SchoolyearCode { get; set; }
  25. /// <summary>
  26. /// 课程ID
  27. /// </summary>
  28. public Guid? CoursematerialID { get; set; }
  29. /// <summary>
  30. /// 课程名称
  31. /// </summary>
  32. public string CoursematerialName { get; set; }
  33. /// <summary>
  34. /// 授课方式
  35. /// </summary>
  36. public int? TeachingModeID { get; set; }
  37. public string TeachingModeName
  38. {
  39. get
  40. {
  41. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_TeachingMode.ToString())
  42. .Where(x => x.Value == TeachingModeID)
  43. .Select(x => x.Name).FirstOrDefault();
  44. }
  45. }
  46. /// <summary>
  47. /// 排课班ID
  48. /// </summary>
  49. public Nullable<System.Guid> EducationSchedulingClassID { get; set; }
  50. /// <summary>
  51. /// 排课班
  52. /// </summary>
  53. public string TaskGroupName { get; set; }
  54. /// <summary>
  55. /// 任务班
  56. /// </summary>
  57. public Guid? EducationMissionClassID { get; set; }
  58. /// <summary>
  59. /// 任务班
  60. /// </summary>
  61. public string EducationMissionClassName { get; set; }
  62. /// <summary>
  63. /// 上课周次
  64. /// </summary>
  65. public List<int?> WeekNumList { get; set; }
  66. /// <summary>
  67. /// 上课周字符串
  68. /// </summary>
  69. public string WeeklyNumString
  70. {
  71. get
  72. {
  73. return WeekNumList.GetWeekNumString();
  74. }
  75. }
  76. /// <summary>
  77. /// 星期
  78. /// </summary>
  79. public Nullable<int> Weekday { get; set; }
  80. /// <summary>
  81. /// 课程时间
  82. /// </summary>
  83. public Nullable<System.Guid> CoursesTimeID { get; set; }
  84. /// <summary>
  85. /// 课程时间视图
  86. /// </summary>
  87. public BaseWorkTimeView CoursesTime { get; set; }
  88. /// <summary>
  89. /// ClassroomTypeID
  90. /// </summary>
  91. public Nullable<int> ClassroomTypeID { get; set; }
  92. /// <summary>
  93. /// ClassroomID
  94. /// </summary>
  95. public Nullable<System.Guid> ClassroomID { get; set; }
  96. public string ClassroomName { get; set; }
  97. /// <summary>
  98. /// RecordStatus
  99. /// </summary>
  100. public Nullable<int> RecordStatus { get; set; }
  101. /// <summary>
  102. /// CreateTime
  103. /// </summary>
  104. public Nullable<System.DateTime> CreateTime { get; set; }
  105. /// <summary>
  106. /// CreateUserID
  107. /// </summary>
  108. public Nullable<System.Guid> CreateUserID { get; set; }
  109. /// <summary>
  110. /// ModifyUserID
  111. /// </summary>
  112. public Nullable<System.Guid> ModifyUserID { get; set; }
  113. /// <summary>
  114. /// ModifyTime
  115. /// </summary>
  116. public Nullable<System.DateTime> ModifyTime { get; set; }
  117. /// <summary>
  118. /// 教师列表
  119. /// </summary>
  120. public List<BaseTeacherTeachingView> TeacherTeachingViewList { get; set; }
  121. public List<Guid> ClassMajorIDList { get; set; }
  122. public string TeacherNames
  123. {
  124. get
  125. {
  126. return string.Join(",", TeacherTeachingViewList.Select(x => x.Name).Distinct().ToList());
  127. }
  128. }
  129. public string TeracherNamesWithLink
  130. {
  131. get
  132. {
  133. string anchorStart = "<a href=#this class=\"scheduleItemTeacherLink\" style=\"color: blue;\" onclick=popupTeacherReport('";
  134. string anchorMiddle = "')>";
  135. string anchorEnd = "</a>";
  136. var teacherLinkList = TeacherTeachingViewList.Select(x =>
  137. anchorStart + x.UserID.ToString() + anchorMiddle + x.Name + anchorEnd).Distinct().ToList();
  138. return string.Join(",", teacherLinkList);
  139. }
  140. }
  141. public List<CourseProcessView> CourseProcessViewList { get; set; }
  142. public Guid? CollegeID { get; set; }
  143. public Guid? CourseCollegeID { get; set; }
  144. public int? StudentCount { get; set; }
  145. /// <summary>
  146. /// 根据院系优先级设置,判断该教学任务是否在可编辑时间段内
  147. /// </summary>
  148. public bool IsCanEdit { get; set; }
  149. }
  150. }