using HStation.Service.Assets; namespace HStation.WinFrmUI { /// /// /// public class AssetsTankMainMgrViewModel { /// /// /// public AssetsTankMainMgrViewModel() { } /// /// /// public AssetsTankMainMgrViewModel(HStation.Vmo.AssetsTankMainVmo rhs) { this.ID = rhs.ID; this.SeriesID = rhs.SeriesID; this.Name = rhs.Name; this.DN = rhs.DN; this.MinLevel = rhs.MinLevel; this.MaxLevel = rhs.MaxLevel; this.OverFlow = rhs.OverFlow; this.MinVol = rhs.MinVol; this.KeyWords = KeyWordHelper.ToString(rhs.KeyWords); this.Flags = Yw.Untity.FlagsHelper.ToString(rhs.Flags); this.TagName = rhs.TagName; this.Description = rhs.Description; this.Vmo = rhs; } /// /// /// public void Reset(HStation.Vmo.AssetsTankMainVmo rhs) { this.ID = rhs.ID; this.SeriesID = rhs.SeriesID; this.Name = rhs.Name; this.DN = rhs.DN; this.MinLevel = rhs.MinLevel; this.MaxLevel = rhs.MaxLevel; this.OverFlow = rhs.OverFlow; this.MinVol = rhs.MinVol; this.KeyWords = KeyWordHelper.ToString(rhs.KeyWords); this.Flags = Yw.Untity.FlagsHelper.ToString(rhs.Flags); this.TagName = rhs.TagName; this.Description = rhs.Description; this.Vmo = rhs; } /// /// id /// [Display(Name = "ID")] public long ID { get; set; } /// /// 系列id /// [Display(Name = "系列ID")] public long SeriesID { get; set; } /// /// 名称 /// [Display(Name = "名称")] public string Name { get; set; } /// /// 最低水位 /// [DisplayName("最低水位")] public double MinLevel { get; set; } /// /// 最高水位 /// [DisplayName("最高水位")] public double MaxLevel { get; set; } /// /// 公称直径 /// [DisplayName("公称直径")] public double DN { get; set; } /// /// 最小容积 /// [DisplayName("最小容积")] public double MinVol { get; set; } /// /// 是否溢流 /// [DisplayName("是否溢流")] public bool OverFlow { get; set; } /// /// 关键字 /// [Display(Name = "关键字")] public string KeyWords { get; set; } /// /// 标签 /// [Display(Name = "标签")] public string Flags { get; set; } /// /// 标志 /// [Display(Name = "标志")] public string TagName { get; set; } /// /// 排序码 /// [Display(Name = "排序码")] public int SortCode { get { return this.Vmo.SortCode; } set { this.Vmo.SortCode = value; } } /// /// 说明 /// [Display(Name = "说明")] public string Description { get; set; } /// /// /// public HStation.Vmo.AssetsTankMainVmo Vmo { get; set; } } }