StandardView.cs 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using EMIS.ViewModel.Cache;
  2. using System;
  3. using System.Collections.Generic;
  4. using System.ComponentModel;
  5. using System.Linq;
  6. using System.Text;
  7. namespace EMIS.ViewModel.SystemView
  8. {
  9. public class StandardView
  10. {
  11. /// <summary>
  12. /// 专业ID(Value)
  13. /// </summary>
  14. [DisplayName("专业ID(Value)")]
  15. public int? StandardID { get; set; }
  16. /// <summary>
  17. /// 专业代码
  18. /// </summary>
  19. [DisplayName("专业代码")]
  20. public string StandardCode
  21. {
  22. get
  23. {
  24. var inistStandardCode = IdNameExt.GetDictionaryItem(DictionaryItem.CF_Standard.ToString())
  25. .Where(x => x.Value == StandardID)
  26. .Select(x => x.Code).FirstOrDefault();
  27. return (inistStandardCode != null ? inistStandardCode.PadLeft(6, '0') : "");
  28. }
  29. }
  30. /// <summary>
  31. /// 专业名称
  32. /// </summary>
  33. [DisplayName("专业名称")]
  34. public string StandardName { get; set; }
  35. }
  36. }