FreeSelectionCourseApplySpecialtyListView.cs 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.ComponentModel;
  6. using System.ComponentModel.DataAnnotations;
  7. using EMIS.ViewModel.CacheManage;
  8. using EMIS.ViewModel.EnrollManage.SpecialtyManage;
  9. namespace EMIS.ViewModel.SelectCourse
  10. {
  11. public class FreeSelectionCourseApplySpecialtyListView : SpecialtyView
  12. {
  13. public Guid FreeSelectionCourseApplyID { get; set; }
  14. /// <summary>
  15. /// 主键ID
  16. /// </summary>
  17. [DisplayName("主键ID")]
  18. public Guid? SpecialtyID { get; set; }
  19. /// <summary>
  20. /// 专业名称
  21. /// </summary>
  22. [Required]
  23. [DisplayName("专业名称")]
  24. public int? StandardID { get; set; }
  25. public string InitStandardCode { get; set; }
  26. /// <summary>
  27. /// 专业名称
  28. /// </summary>
  29. [DisplayName("专业名称")]
  30. public string StandardName
  31. {
  32. get;
  33. set;
  34. }
  35. /// <summary>
  36. /// 专业代码
  37. /// </summary>
  38. [DisplayName("专业代码")]
  39. public string Code
  40. {
  41. get { return (this.InitStandardCode != null ? this.InitStandardCode.PadLeft(6, '0') : ""); }
  42. }
  43. /// <summary>
  44. /// 学制
  45. /// </summary>
  46. [Required]
  47. [DisplayName("学制")]
  48. [DisplayFormat(DataFormatString = "{0:#.#}")]
  49. [RegularExpression(@"^[0-9]+([.]{1}[0-9]+){0,1}$", ErrorMessage = "请输入数字")]
  50. public decimal? LearnSystem { get; set; }
  51. /// <summary>
  52. /// 学制
  53. /// </summary>
  54. public string LearnSystemStr { get; set; }
  55. /// <summary>
  56. /// 专业科类
  57. /// </summary>
  58. [DisplayName("专业科类")]
  59. public int? ScienceclassID { get; set; }
  60. /// <summary>
  61. /// 专业科类
  62. /// </summary>
  63. [DisplayName("专业科类")]
  64. public string ScienceclassStr { get; set; }
  65. /// <summary>
  66. /// 专业科类名称
  67. /// </summary>
  68. [DisplayName("专业科类名称")]
  69. public string ScienceclassName
  70. {
  71. get
  72. {
  73. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_Scienceclass.ToString())
  74. .Where(x => x.Value == ScienceclassID).Select(x => x.Name).FirstOrDefault();
  75. }
  76. }
  77. /// <summary>
  78. /// 学习形式
  79. /// </summary>
  80. [Required]
  81. [DisplayName("学习形式")]
  82. public int? LearningformID { get; set; }
  83. /// <summary>
  84. /// 学习形式
  85. /// </summary>
  86. [DisplayName("学习形式")]
  87. public string LearningformStr { get; set; }
  88. /// <summary>
  89. /// 学习形式名称
  90. /// </summary>
  91. [DisplayName("学习形式名称")]
  92. public string LearningformName
  93. {
  94. get
  95. {
  96. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_Learningform.ToString())
  97. .Where(x => x.Value == LearningformID).Select(x => x.Name).FirstOrDefault();
  98. }
  99. }
  100. /// <summary>
  101. /// 培养层次
  102. /// </summary>
  103. [Required]
  104. [Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "EducationID")]
  105. public int? EducationID { get; set; }
  106. /// 培养层次名称
  107. public string EducationStr { get; set; }
  108. /// <summary>
  109. /// 培养层次名称
  110. /// </summary>
  111. [Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "EducationName")]
  112. public string EducationName
  113. {
  114. get
  115. {
  116. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_Education.ToString())
  117. .Where(x => x.Value == EducationID)
  118. .Select(x => x.Name).FirstOrDefault();
  119. }
  120. }
  121. /// <summary>
  122. /// 专业属性
  123. /// </summary>
  124. [DisplayName("专业属性")]
  125. public int? PropertyID { get; set; }
  126. /// <summary>
  127. /// 专业属性
  128. /// </summary>
  129. [DisplayName("专业属性")]
  130. public string PropertyStr { get; set; }
  131. /// <summary>
  132. /// 专业属性名称
  133. /// </summary>
  134. [DisplayName("专业属性名称")]
  135. public string PropertyName
  136. {
  137. get
  138. {
  139. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_Property.ToString())
  140. .Where(x => x.Value == PropertyID).Select(x => x.Name).FirstOrDefault();
  141. }
  142. }
  143. /// <summary>
  144. /// 年级
  145. /// </summary>
  146. [DisplayName("年级")]
  147. public int? SchoolyearID { get; set; }
  148. /// <summary>
  149. /// 专业称号
  150. /// </summary>
  151. [DisplayName("专业称号")]
  152. public int? StandardTitle { get; set; }
  153. /// <summary>
  154. /// 专业称号
  155. /// </summary>
  156. [DisplayName("专业称号")]
  157. public string StandardTitleStr { get; set; }
  158. /// <summary>
  159. /// 专业称号
  160. /// </summary>
  161. [DisplayName("专业称号")]
  162. public string StandardTitleName
  163. {
  164. get
  165. {
  166. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_StandardTitle.ToString())
  167. .Where(x => x.Value == StandardTitle).Select(x => x.Name).FirstOrDefault();
  168. }
  169. }
  170. /// <summary>
  171. /// 称号级别
  172. /// </summary>
  173. [DisplayName("称号级别")]
  174. public int? StandardLevel { get; set; }
  175. /// <summary>
  176. /// 称号级别
  177. /// </summary>
  178. [DisplayName("称号级别")]
  179. public string StandardLevelStr { get; set; }
  180. /// <summary>
  181. /// 称号级别
  182. /// </summary>
  183. [DisplayName("称号级别")]
  184. public string StandardLevelName
  185. {
  186. get
  187. {
  188. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_StandardLevel.ToString())
  189. .Where(x => x.Value == StandardLevel)
  190. .Select(x => x.Name).FirstOrDefault();
  191. }
  192. }
  193. /// <summary>
  194. /// 备注
  195. /// </summary>
  196. [DisplayName("备注")]
  197. public string Remarks { get; set; }
  198. /// <summary>
  199. /// 错误信息
  200. /// </summary>
  201. [DisplayName("错误信息")]
  202. public string ErrorMessage { get; set; }
  203. /// <summary>
  204. /// 创建人
  205. /// </summary>
  206. [DisplayName("创建人")]
  207. public Guid? CreateUserID { get; set; }
  208. /// <summary>
  209. /// 创建时间
  210. /// </summary>
  211. [DisplayName("创建时间")]
  212. public DateTime? CreateTime { get; set; }
  213. private bool _isExcelVaildateOK = true;
  214. /// <summary>
  215. /// Excel验证是否通过,默认为true
  216. /// <para>true:通过;false:不通过</para>
  217. /// </summary>
  218. public bool IsExcelVaildateOK
  219. {
  220. get { return _isExcelVaildateOK; }
  221. set { _isExcelVaildateOK = value; }
  222. }
  223. }
  224. }