BaseTeacherTeachingView.cs 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.ComponentModel.DataAnnotations;
  6. using EMIS.ViewModel.CacheManage;
  7. using System.ComponentModel;
  8. namespace EMIS.ViewModel.EducationManage
  9. {
  10. public class BaseTeacherTeachingView
  11. {
  12. /// <summary>
  13. /// 用户ID
  14. /// </summary>
  15. [DisplayName("用户ID")]
  16. public Guid UserID { get; set; }
  17. /// <summary>
  18. /// 教职工号
  19. /// </summary>
  20. [DisplayName("教职工号")]
  21. public string LoginID { get; set; }
  22. /// <summary>
  23. /// 姓名
  24. /// </summary>
  25. [DisplayName("姓名")]
  26. public string Name { get; set; }
  27. /// <summary>
  28. /// 性别
  29. /// </summary>
  30. [DisplayName("性别")]
  31. public int? Sex { get; set; }
  32. /// <summary>
  33. /// 性别
  34. /// </summary>
  35. [DisplayName("性别")]
  36. public string SexName
  37. {
  38. get
  39. {
  40. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_Sex.ToString())
  41. .Where(x => x.Value == Sex).Select(x => x.Name).FirstOrDefault();
  42. }
  43. }
  44. /// <summary>
  45. /// 出生日期
  46. /// </summary>
  47. [DisplayName("出生日期")]
  48. public DateTime? BirthDate { get; set; }
  49. /// <summary>
  50. /// 教师类型
  51. /// </summary>
  52. [DisplayName("教师类型")]
  53. public int? TeacherType { get; set; }
  54. /// <summary>
  55. /// 教师类型
  56. /// </summary>
  57. [DisplayName("教师类型")]
  58. public string TeacherTypeName
  59. {
  60. get
  61. {
  62. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_TeacherType.ToString())
  63. .Where(x => x.Value == TeacherType).Select(x => x.Name).FirstOrDefault();
  64. }
  65. }
  66. /// <summary>
  67. /// 在职状态
  68. /// </summary>
  69. [DisplayName("在职状态")]
  70. public int? IncumbencyState { get; set; }
  71. /// <summary>
  72. /// 在职状态
  73. /// </summary>
  74. [DisplayName("在职状态")]
  75. public string IncumbencyStateName
  76. {
  77. get
  78. {
  79. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_IncumbencyState.ToString())
  80. .Where(x => x.Value == IncumbencyState).Select(x => x.Name).FirstOrDefault();
  81. }
  82. }
  83. /// <summary>
  84. /// 职称
  85. /// </summary>
  86. [DisplayName("职称")]
  87. public int? Title { get; set; }
  88. /// <summary>
  89. /// 职称
  90. /// </summary>
  91. [DisplayName("职称")]
  92. public string TitleName
  93. {
  94. get
  95. {
  96. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_Title.ToString())
  97. .Where(x => x.Value == Title).Select(x => x.Name).FirstOrDefault();
  98. }
  99. }
  100. /// <summary>
  101. /// 任课方式
  102. /// </summary>
  103. [Required]
  104. [DisplayName("任课方式")]
  105. public int? TeachingMethod { get; set; }
  106. /// <summary>
  107. /// 任课方式
  108. /// </summary>
  109. [DisplayName("任课方式")]
  110. public string TeachingMethodName
  111. {
  112. get
  113. {
  114. return IdNameExt.GetDictionaryItem(DictionaryItem.EM_TeachingMethod.ToString())
  115. .Where(x => x.Value == TeachingMethod).Select(x => x.Name).FirstOrDefault();
  116. }
  117. }
  118. /// <summary>
  119. /// 教研室ID
  120. /// </summary>
  121. [DisplayName("教研室ID")]
  122. public Guid? DepartmentID { get; set; }
  123. /// <summary>
  124. /// 教研室代码
  125. /// </summary>
  126. [DisplayName("教研室代码")]
  127. public string DepartmentCode { get; set; }
  128. /// <summary>
  129. /// 教研室
  130. /// </summary>
  131. [DisplayName("教研室")]
  132. public string DepartmentName { get; set; }
  133. /// <summary>
  134. /// 院系所ID
  135. /// </summary>
  136. [Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CollegeID")]
  137. public Guid? CollegeID { get; set; }
  138. /// <summary>
  139. /// 院系所代码
  140. /// </summary>
  141. [Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CollegeCode")]
  142. public string CollegeNo { get; set; }
  143. /// <summary>
  144. /// 院系所名称
  145. /// </summary>
  146. [Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "College")]
  147. public string CollegeName { get; set; }
  148. }
  149. }