| | |
| | | /// <summary> |
| | | /// 过渡件视图 |
| | | /// </summary> |
| | | public class HydroTranslationViewModel : HydroPipeViewModel |
| | | public class HydroTranslationViewModel : HydroPipeViewModel, IHydroCalcuTranslationResult |
| | | { |
| | | /// <summary> |
| | | /// |
| | |
| | | /// </summary> |
| | | public HydroTranslationViewModel(Yw.Model.HydroTranslationInfo rhs, Yw.Model.HydroModelInfo hydroInfo) : base(rhs, hydroInfo) |
| | | { |
| | | this.Vmo = rhs; |
| | | this.StartDiameter = Math.Round(rhs.StartDiameter, 0); |
| | | this.EndDiameter = Math.Round(rhs.EndDiameter, 0); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 直径 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [Display(Name = "直径(mm)")] |
| | | [DisplayName("直径")] |
| | | [DisplayUnit("mm")] |
| | | [PropertyOrder(2002)] |
| | | [Browsable(false)] |
| | | public override double Diameter { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 上游直径 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [Display(Name = "上游直径(mm)")] |
| | | [DisplayName("上游直径")] |
| | | [DisplayUnit("mm")] |
| | | [PropertyOrder(3001)] |
| | | [Browsable(true)] |
| | | public double StartDiameter { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 下游直径 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [Display(Name = "下游直径(mm)")] |
| | | [DisplayName("下游直径")] |
| | | [DisplayUnit("mm")] |
| | | [PropertyOrder(3002)] |
| | | [Browsable(true)] |
| | | public double EndDiameter { get; set; } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | [Browsable(false)] |
| | | public new Yw.Model.HydroTranslationInfo Vmo { get; set; } |
| | | public new Yw.Model.HydroTranslationInfo Vmo |
| | | { |
| | | get { return _vmo as Yw.Model.HydroTranslationInfo; } |
| | | set { _vmo = value; } |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 更新属性 |
| | | /// </summary> |
| | | public override void UpdateProperty() |
| | | { |
| | | base.UpdateProperty(); |
| | | this.StartDiameter = this.Vmo.StartDiameter; |
| | | this.EndDiameter = this.Vmo.EndDiameter; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public override void UpdateVmoProperty() |
| | | { |
| | | base.UpdateVmoProperty(); |
| | | this.Vmo.StartDiameter = this.StartDiameter; |
| | | this.Vmo.EndDiameter = this.EndDiameter; |
| | | } |
| | | |
| | | } |
| | | } |