ExaminationModeSettingView.cs 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.ComponentModel.DataAnnotations;
  6. using System.ComponentModel;
  7. using EMIS.ViewModel.CacheManage;
  8. namespace EMIS.ViewModel.ExaminationManage
  9. {
  10. public class ExaminationModeSettingView
  11. {
  12. public Guid ExaminationModeSettingID { get; set; }
  13. [Required]
  14. [DisplayName("考试方式")]
  15. public int? ExaminationModeID { get; set; }
  16. public string ExaminationModeDesc
  17. {
  18. get
  19. {
  20. return IdNameExt.GetDictionaryItem(DictionaryItem.CF_ExaminationMode)
  21. .Where(x => x.Value == ExaminationModeID)
  22. .Select(x => x.Name).FirstOrDefault();
  23. }
  24. }
  25. [DisplayName("是否生成考试计划")]
  26. public bool IsGeneratePlan { get; set; }
  27. public string IsGeneratePlanDesc
  28. {
  29. get
  30. {
  31. return IsGeneratePlan ? "是" : "否";
  32. }
  33. }
  34. }
  35. }