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.UniversityManage.ClassroomManage
{
public class BuildingsInfoView
{
///
/// 主键ID
///
[DisplayName("主键ID")]
public Guid BuildingsInfoID { get; set; }
///
/// 建筑编号
///
[Required]
[DisplayName("建筑编号")]
[RegularExpression(@"^[0-9a-zA-Z\s?]+$", ErrorMessage = "请输入数字或英文字母")]
public string Code { get; set; }
///
/// 建筑名称
///
[Required]
[DisplayName("建筑名称")]
public string Name { get; set; }
///
/// 校区ID
///
[Required]
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "Campus")]
public Guid? CampusID { get; set; }
///
/// 校区代码
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CampusCode")]
public string CampusCode { get; set; }
///
/// 校区名称
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CampusName")]
public string CampusName { get; set; }
///
/// 院系所ID(此为建筑信息所属的院系所ID)
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "College")]
public Guid? CollegeID { get; set; }
///
/// 院系所代码(此为建筑信息所属的院系所代码)
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CollegeCode")]
public string CollegeCode { get; set; }
///
/// 院系所(此为建筑信息所属的院系所)
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CollegeName")]
public string CollegeName { get; set; }
///
/// 校区ID(此为建筑信息所属的院系所对应的校区ID)
///
[Required]
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "Campus")]
public Guid? CollegeCampusID { get; set; }
///
/// 校区代码(此为建筑信息所属的院系所对应的校区代码)
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CampusCode")]
public string CollegeCampusCode { get; set; }
///
/// 校区(此为建筑信息所属的院系所对应的校区)
///
[Display(ResourceType = typeof(EMIS.Resources.DataAnnotations.Label), Name = "CampusName")]
public string CollegeCampusName { get; set; }
///
/// 建筑类型
///
[Required]
[DisplayName("建筑类型")]
public int? BuildingsTypeID { get; set; }
///
/// 建筑类型(Excel导入)
///
[DisplayName("建筑类型")]
public string BuildingsTypeStr { get; set; }
///
/// 建筑类型
///
[DisplayName("建筑类型")]
public string BuildingsTypeName
{
get
{
return IdNameExt.GetDictionaryItem(DictionaryItem.CF_BuildingsType.ToString()).Where(x => x.Value == BuildingsTypeID).Select(x => x.Name).FirstOrDefault();
}
}
///
/// 建筑状况
///
[Required]
[DisplayName("建筑状况")]
public int? BuildingsStatusID { get; set; }
///
/// 建筑状况(Excel导入)
///
[DisplayName("建筑状况")]
public string BuildingsStatusStr { get; set; }
///
/// 建筑状况
///
[DisplayName("建筑状况")]
public string BuildingsStatusName
{
get
{
return IdNameExt.GetDictionaryItem(DictionaryItem.CF_BuildingsStatus.ToString()).Where(x => x.Value == BuildingsStatusID).Select(x => x.Name).FirstOrDefault();
}
}
///
/// 建筑层数
///
[DisplayName("建筑层数")]
public decimal? BuildingsLevel { get; set; }
///
/// 建筑层数(Excel导入)
///
[DisplayName("建筑层数")]
public string BuildingsLevelStr { get; set; }
///
/// 建筑面积
///
[DisplayName("建筑面积")]
public decimal? BuildingsArea { get; set; }
///
/// 建筑面积(Excel导入)
///
[DisplayName("建筑面积")]
public string BuildingsAreaStr { get; set; }
///
/// 使用面积
///
[DisplayName("使用面积")]
public decimal? UseArea { get; set; }
///
/// 使用面积(Excel导入)
///
[DisplayName("使用面积")]
public string UseAreaStr { get; set; }
///
/// 地址
///
[DisplayName("地址")]
public string Position { get; set; }
///
/// 是否可用
///
[DisplayName("是否可用")]
public bool IsSpecial { get; set; }
///
/// 是否可用(Excel导入)
///
[DisplayName("是否可用")]
public string IsSpecialStr { get; set; }
///
/// 是否可用
///
[DisplayName("是否可用")]
public string IsSpecialName
{
get
{
return IsSpecial == true ? "是" : "否";
}
}
///
/// 教室间数
///
[DisplayName("教室间数")]
public int? ClassroomCount { get; set; }
///
/// 备注
///
[DisplayName("备注")]
public string Remark { get; set; }
///
/// 错误信息(Excel导入)
///
[DisplayName("未导入原因")]
public string ErrorMessage { get; set; }
///
/// 状态
///
[DisplayName("状态")]
public int? RecordStatus { get; set; }
///
/// 创建人
///
[DisplayName("创建人")]
public Guid? CreateUserID { get; set; }
///
/// 创建时间
///
[DisplayName("创建时间")]
public DateTime? CreateTime { get; set; }
///
/// 修改人
///
[DisplayName("修改人")]
public Guid? ModifyUserID { get; set; }
///
/// 修改时间
///
[DisplayName("修改时间")]
public DateTime? ModifyTime { get; set; }
}
}