using DevExpress.Utils.Svg; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace HStation.WinFrmUI { /// /// /// public class XhsSchemePipeChangeViewModel { /// /// /// public XhsSchemePipeChangeViewModel() { this.SvgImage = HStation.WinFrmUI.AssetsMainSvgImageHelper.Pipe; } /// /// /// public XhsSchemePipeChangeViewModel(HydroPipeViewModel rhs) { this.ViewModel = rhs; this.SvgImage = HStation.WinFrmUI.AssetsMainSvgImageHelper.Pipe; } /// /// 名称 /// public string Name { get { var name = this.ViewModel.Name; if (!string.IsNullOrEmpty(this.ViewModel.ModelType)) { name += $"({this.ViewModel.ModelType})"; } return name; } } /// /// 材质 /// [Display(Name = "材质")] public string Material { get { return this.ViewModel.Material; } set { this.ViewModel.Material = value; } } /// /// 直径 /// [Display(Name = "直径")] public double Diameter { get { return this.ViewModel.Diameter; } set { this.ViewModel.Diameter = value; } } /// /// 长度 /// [Display(Name = "长度")] public double Length { get { return this.ViewModel.Length; } set { this.ViewModel.Length = value; } } /// /// 粗糙系数 /// [Display(Name = "粗糙系数")] public double Roughness { get { return this.ViewModel.Roughness; } set { this.ViewModel.Roughness = value; } } /// /// ViewMdoel /// public HydroPipeViewModel ViewModel { get; set; } /// /// 图片 /// public SvgImage SvgImage { get; set; } /// /// 查看图片 /// public SvgImage ViewImage { get; set; } } }