123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.ComponentModel.DataAnnotations;
- using System.Linq;
- using System.Text;
- using EMIS.ViewModel.CacheManage;
- namespace EMIS.ViewModel.EvaluationManage.EvaluationTable
- {
- public class EvaluationTargetView
- {
- /// <summary>
- /// 主键ID
- /// </summary>
- [DisplayName("主键ID")]
- public Guid EvaluationTargetID { get; set; }
- /// <summary>
- /// 次序
- /// </summary>
- [Required]
- [DisplayName("次序")]
- [RegularExpression(@"^[1-9]\d*|0$", ErrorMessage = "请输入自然数")]
- public int? OrderNo { get; set; }
- /// <summary>
- /// 指标编号
- /// </summary>
- [Required]
- [DisplayName("指标编号")]
- [RegularExpression(@"^[0-9a-zA-Z\s?]+$", ErrorMessage = "请输入数字或英文字母")]
- public string Code { get; set; }
- /// <summary>
- /// 指标名称
- /// </summary>
- [Required]
- [DisplayName("指标名称")]
- public string Name { get; set; }
- /// <summary>
- /// 评价表ID
- /// </summary>
- [Required]
- [DisplayName("评价表ID")]
- public Guid? EvaluationTableID { get; set; }
- /// <summary>
- /// 评价表编号
- /// </summary>
- [DisplayName("评价表编号")]
- public string EvaluationTableCode { get; set; }
- /// <summary>
- /// 评价表名
- /// </summary>
- [DisplayName("评价表名")]
- public string EvaluationTableName { get; set; }
- /// <summary>
- /// 评价表权重
- /// </summary>
- [DisplayName("评价表权重")]
- public decimal? EvaluationTableWeight { get; set; }
- /// <summary>
- /// 参评类型ID
- /// </summary>
- [DisplayName("参评类型ID")]
- public Guid? EvaluationParticipateTypeID { get; set; }
- /// <summary>
- /// 参评类型
- /// </summary>
- [DisplayName("参评类型")]
- public int? ParticipateTypeID { get; set; }
- /// <summary>
- /// 参评代码
- /// </summary>
- [DisplayName("参评代码")]
- public string ParticipateTypeCode
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.EM_ParticipateType.ToString()).Where(x => x.Value == ParticipateTypeID).Select(x => x.Code).FirstOrDefault();
- }
- }
- /// <summary>
- /// 参评类型
- /// </summary>
- [DisplayName("参评类型")]
- public string ParticipateTypeName
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.EM_ParticipateType.ToString()).Where(x => x.Value == ParticipateTypeID).Select(x => x.Name).FirstOrDefault();
- }
- }
- /// <summary>
- /// 学生用
- /// </summary>
- [DisplayName("学生用")]
- public bool IsStudent { get; set; }
- /// <summary>
- /// 学生用
- /// </summary>
- [DisplayName("学生用")]
- public string IsStudentName
- {
- get { return this.IsStudent == true ? "是" : "否"; }
- }
- /// <summary>
- /// 评价类型ID
- /// </summary>
- [DisplayName("评价类型ID")]
- public Guid? EvaluationTypeID { get; set; }
- /// <summary>
- /// 评价类型编号
- /// </summary>
- [DisplayName("评价类型编号")]
- public string EvaluationTypeCode { get; set; }
- /// <summary>
- /// 评价类型
- /// </summary>
- [DisplayName("评价类型")]
- public string EvaluationTypeName { get; set; }
- /// <summary>
- /// 授课方式
- /// </summary>
- [DisplayName("授课方式")]
- public List<int?> TeachingModeIDList { get; set; }
- /// <summary>
- /// 授课方式(可存在多个授课方式--用顿号隔开)
- /// </summary>
- [DisplayName("授课方式")]
- public string TeachingModeIDListName
- {
- get
- {
- if (TeachingModeIDList != null && TeachingModeIDList.Count() > 0)
- {
- return string.Join("、", TeachingModeIDList.Select(x => IdNameExt.GetDictionaryItem(DictionaryItem.CF_TeachingMode.ToString()).Where(w => w.Value == x).Select(w => w.Name).FirstOrDefault()));
- }
- else
- {
- return "";
- }
- }
- }
- /// <summary>
- /// 评分标准ID
- /// </summary>
- [Required]
- [DisplayName("评分标准ID")]
- public Guid? EvaluationNormID { get; set; }
- /// <summary>
- /// 评分标准
- /// </summary>
- [DisplayName("评分标准")]
- public string EvaluationNormName { get; set; }
- /// <summary>
- /// 评分类型
- /// </summary>
- [DisplayName("评分类型")]
- public int? NormTypeID { get; set; }
- /// <summary>
- /// 评分类型
- /// </summary>
- [DisplayName("评分类型")]
- public string NormTypeName
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.EM_EvaluationNormType.ToString()).Where(x => x.Value == NormTypeID).Select(x => x.Name).FirstOrDefault();
- }
- }
- /// <summary>
- /// 权重
- /// </summary>
- [Required]
- [DisplayName("权重")]
- [RegularExpression(@"^\d+(\.\d{1})?$", ErrorMessage = "请输入整数或保留1位小数")]
- public decimal? Weight { get; set; }
- /// <summary>
- /// 项目个数
- /// </summary>
- [DisplayName("项目个数")]
- public int? ProjectCount { get; set; }
- /// <summary>
- /// 备注
- /// </summary>
- [DisplayName("备注")]
- public string Remark { get; set; }
- /// <summary>
- /// 状态
- /// </summary>
- [DisplayName("状态")]
- public int? RecordStatus { get; set; }
- /// <summary>
- /// 创建人
- /// </summary>
- [DisplayName("创建人")]
- public Guid? CreateUserID { get; set; }
- /// <summary>
- /// 创建人
- /// </summary>
- [DisplayName("创建人")]
- public string CreateUserName { get; set; }
- /// <summary>
- /// 创建时间
- /// </summary>
- [DisplayName("创建时间")]
- public DateTime? CreateTime { get; set; }
- /// <summary>
- /// 修改人
- /// </summary>
- [DisplayName("修改人")]
- public Guid? ModifyUserID { get; set; }
- /// <summary>
- /// 修改人
- /// </summary>
- [DisplayName("修改人")]
- public string ModifyUserName { get; set; }
- /// <summary>
- /// 修改时间
- /// </summary>
- [DisplayName("修改时间")]
- public DateTime? ModifyTime { get; set; }
- }
- }
|