using Yw.Model;
|
|
namespace HStation.WinFrmUI.Xhs.PumpProduct
|
{
|
public class CurrentTreeViewModel
|
{
|
public CurrentTreeViewModel(PumpSeriesDto rhs) : base()
|
{
|
this.ID = rhs.ID;
|
this.CatalogID = rhs.CatalogID;
|
this.Name = rhs.Name;
|
this.Paras = rhs.Paras;
|
this.Flags = rhs.Flags;
|
this.TagName = rhs.TagName;
|
this.UseStatus = rhs.UseStatus;
|
this.SortCode = rhs.SortCode;
|
this.Description = rhs.Description;
|
this.Model = rhs;
|
this.ImageIndex = ImageLib.Series;
|
}
|
|
public CurrentTreeViewModel(PumpGroupDto rhs) : base()
|
{
|
this.ID = rhs.ID;
|
this.Name = rhs.Name;
|
this.ParentID = rhs.PumpSeriesID;
|
this.TagName = rhs.TagName;
|
this.SortCode = rhs.SortCode;
|
this.Description = rhs.Description;
|
this.Model = rhs;
|
this.IsGroup = true;
|
this.ImageIndex = ImageLib.Group;
|
}
|
|
public void Reset(UpdatePumpSeriesDto rhs)
|
{
|
this.ID = rhs.ID;
|
this.CatalogID = rhs.CatalogID;
|
this.Name = rhs.Name;
|
this.Paras = rhs.Paras;
|
this.Flags = rhs.Flags;
|
this.TagName = rhs.TagName;
|
this.SortCode = rhs.SortCode;
|
this.Description = rhs.Description;
|
this.Model = rhs;
|
}
|
|
public void Reset(UpdatePumpGroupDto rhs)
|
{
|
this.ID = rhs.ID;
|
this.Name = rhs.Name;
|
this.TagName = rhs.TagName;
|
this.SortCode = rhs.SortCode;
|
this.Description = rhs.Description;
|
this.Model = rhs;
|
}
|
|
public long ID { get; set; }
|
public long CatalogID { get; set; }
|
public long ParentID { get; set; }
|
public string Name { get; set; }
|
public Dictionary<string, string> Paras { get; set; }
|
public List<string> Flags { get; set; }
|
public string TagName { get; set; }
|
public eUseStatus UseStatus { get; set; }
|
public int SortCode { get; set; }
|
public string MotorFrequency { get; set; }
|
public string Description { get; set; }
|
public object Model { get; set; }
|
public bool IsGroup { get; set; } = false;
|
public int ImageIndex { get; set; }
|
}
|
}
|