| | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public HydroPumpPropertyViewModel() { } |
| | | public HydroPumpPropertyViewModel() : base() { } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public HydroPumpPropertyViewModel(Yw.Model.HydroPumpInfo rhs) : base(rhs) |
| | | { |
| | | this.RatedPower = rhs.RatedPower; |
| | | this.CurveQH = rhs.CurveQH; |
| | | this.RatedP = rhs.RatedP; |
| | | this.UpdatePropStatus(nameof(this.RatedP), rhs, nameof(rhs.RatedP)); |
| | | this.RatedQ = rhs.RatedQ; |
| | | this.UpdatePropStatus(nameof(this.RatedQ), rhs, nameof(rhs.RatedQ)); |
| | | this.RatedH = rhs.RatedH; |
| | | this.UpdatePropStatus(nameof(this.RatedH), rhs, nameof(rhs.RatedH)); |
| | | this.RatedN = rhs.RatedN; |
| | | this.UpdatePropStatus(nameof(this.RatedN), rhs, nameof(rhs.RatedN)); |
| | | this.RatedHz = rhs.RatedHz; |
| | | this.UpdatePropStatus(nameof(this.RatedHz), rhs, nameof(rhs.RatedHz)); |
| | | this.SpeedRatio = rhs.SpeedRatio; |
| | | this.UpdatePropStatus(nameof(this.SpeedRatio), rhs, nameof(rhs.SpeedRatio)); |
| | | this.SpeedRatioPattern = rhs.SpeedRatioPattern; |
| | | this.Price = rhs.Price; |
| | | this.PricePattern = rhs.PricePattern; |
| | | this.UpdatePropStatus(nameof(this.SpeedRatioPattern), rhs, nameof(rhs.SpeedRatioPattern)); |
| | | this.CurveQH = rhs.CurveQH; |
| | | this.UpdatePropStatus(nameof(this.CurveQH), rhs, nameof(rhs.CurveQH)); |
| | | this.CurveQP = rhs.CurveQP; |
| | | this.UpdatePropStatus(nameof(this.CurveQP), rhs, nameof(rhs.CurveQP)); |
| | | this.CurveQE = rhs.CurveQE; |
| | | this.UpdatePropStatus(nameof(this.CurveQE), rhs, nameof(rhs.CurveQE)); |
| | | this.Price = rhs.Price; |
| | | this.UpdatePropStatus(nameof(this.Price), rhs, nameof(rhs.Price)); |
| | | this.PricePattern = rhs.PricePattern; |
| | | this.UpdatePropStatus(nameof(this.PricePattern), rhs, nameof(rhs.PricePattern)); |
| | | this.Curve = string.IsNullOrEmpty(rhs.CurveQH) ? "未设置" : "已设置"; |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 水泵状态 |
| | |
| | | [DisplayName("水泵状态")] |
| | | [PropertyOrder(13)] |
| | | [Browsable(true)] |
| | | [TypeConverter(typeof(HydroPumpStatusConverter))] |
| | | public override string LinkStatus { get; set; } |
| | | |
| | | /// <summary> |
| | |
| | | [Category("数据")] |
| | | [DisplayName("额定功率")] |
| | | [PropertyOrder(101)] |
| | | [DisplayUnit("kW")] |
| | | [Browsable(true)] |
| | | public double RatedPower { get; set; } |
| | | public double RatedP { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 流量扬程曲线 |
| | | /// 额定流量 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("流量扬程曲线")] |
| | | [DisplayName("额定流量")] |
| | | [PropertyOrder(102)] |
| | | [DisplayUnit("m³/h")] |
| | | [Browsable(true)] |
| | | public string CurveQH { get; set; } |
| | | public double? RatedQ { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 额定扬程 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("额定扬程")] |
| | | [PropertyOrder(103)] |
| | | [DisplayUnit("m")] |
| | | [Browsable(true)] |
| | | public double? RatedH { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 额定转速 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("额定转速")] |
| | | [PropertyOrder(104)] |
| | | [DisplayUnit("r/min")] |
| | | [Browsable(true)] |
| | | public double? RatedN { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 额定频率 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("额定频率")] |
| | | [PropertyOrder(105)] |
| | | [DisplayUnit("hz")] |
| | | [Browsable(true)] |
| | | public double RatedHz { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 频率 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("频率")] |
| | | [PropertyOrder(106)] |
| | | [DisplayUnit("hz")] |
| | | [Browsable(true)] |
| | | public double CurrentHz |
| | | { |
| | | get { return this.SpeedRatio * this.RatedHz; } |
| | | set |
| | | { |
| | | if (this.RatedHz <= 0) |
| | | { |
| | | return; |
| | | } |
| | | this.SpeedRatio = value / this.RatedHz; |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 转速比 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("转速比")] |
| | | [PropertyOrder(103)] |
| | | [PropertyOrder(107)] |
| | | [Browsable(true)] |
| | | public double? SpeedRatio { get; set; } |
| | | public double SpeedRatio { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 转速比模式 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("转速比模式")] |
| | | [PropertyOrder(104)] |
| | | [PropertyOrder(108)] |
| | | [Browsable(true)] |
| | | public string SpeedRatioPattern { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 性能曲线 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("性能曲线")] |
| | | [PropertyOrder(110)] |
| | | [Browsable(true)] |
| | | [IsHydroCurvePro(HydroCurve.Pump)] |
| | | public string Curve { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 流量扬程曲线 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("流量扬程曲线")] |
| | | [PropertyOrder(111)] |
| | | [IsHydroCurvePro(HydroCurve.PumpQH)] |
| | | [Browsable(true)] |
| | | public string CurveQH { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 流量功率曲线 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("流量功率曲线")] |
| | | [PropertyOrder(112)] |
| | | [IsHydroCurvePro(HydroCurve.PumpQP)] |
| | | [Browsable(true)] |
| | | public string CurveQP { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 流量效率曲线 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("流量效率曲线")] |
| | | [PropertyOrder(113)] |
| | | [IsHydroCurvePro(HydroCurve.PumpQE)] |
| | | [Browsable(true)] |
| | | public string CurveQE { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 能耗价格 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("能耗价格")] |
| | | [PropertyOrder(105)] |
| | | [PropertyOrder(114)] |
| | | [Browsable(true)] |
| | | public double? Price { get; set; } |
| | | |
| | |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("价格模式")] |
| | | [PropertyOrder(106)] |
| | | [PropertyOrder(115)] |
| | | [Browsable(true)] |
| | | public string PricePattern { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 流量效率曲线 |
| | | /// </summary> |
| | | [Category("数据")] |
| | | [DisplayName("流量效率曲线")] |
| | | [PropertyOrder(107)] |
| | | [Browsable(true)] |
| | | public string CurveQE { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 更新属性 |
| | | /// </summary> |
| | | /// <param name="rhs"></param> |
| | | /// <param name="allParterList"></param> |
| | | public override void UpdateProperty(HydroParterInfo rhs, List<HydroParterInfo> allParterList) |
| | | { |
| | | base.UpdateProperty(rhs, allParterList); |
| | | if (rhs is Yw.Model.HydroPumpInfo hydroPumpInfo) |
| | | { |
| | | this.RatedPower = hydroPumpInfo.RatedPower; |
| | | this.CurveQH = hydroPumpInfo.CurveQH; |
| | | this.RatedP = hydroPumpInfo.RatedP; |
| | | this.UpdatePropStatus(nameof(this.RatedP), hydroPumpInfo, nameof(hydroPumpInfo.RatedP)); |
| | | this.RatedQ = hydroPumpInfo.RatedQ; |
| | | this.UpdatePropStatus(nameof(this.RatedQ), hydroPumpInfo, nameof(hydroPumpInfo.RatedQ)); |
| | | this.RatedH = hydroPumpInfo.RatedH; |
| | | this.UpdatePropStatus(nameof(this.RatedH), hydroPumpInfo, nameof(hydroPumpInfo.RatedH)); |
| | | this.RatedN = hydroPumpInfo.RatedN; |
| | | this.UpdatePropStatus(nameof(this.RatedN), hydroPumpInfo, nameof(hydroPumpInfo.RatedN)); |
| | | this.RatedHz = hydroPumpInfo.RatedHz; |
| | | this.UpdatePropStatus(nameof(this.RatedHz), hydroPumpInfo, nameof(hydroPumpInfo.RatedHz)); |
| | | this.SpeedRatio = hydroPumpInfo.SpeedRatio; |
| | | this.UpdatePropStatus(nameof(this.SpeedRatio), hydroPumpInfo, nameof(hydroPumpInfo.SpeedRatio)); |
| | | this.SpeedRatioPattern = hydroPumpInfo.SpeedRatioPattern; |
| | | this.Price = hydroPumpInfo.Price; |
| | | this.PricePattern = hydroPumpInfo.PricePattern; |
| | | this.UpdatePropStatus(nameof(this.SpeedRatioPattern), hydroPumpInfo, nameof(hydroPumpInfo.SpeedRatioPattern)); |
| | | this.CurveQH = hydroPumpInfo.CurveQH; |
| | | this.UpdatePropStatus(nameof(this.CurveQH), hydroPumpInfo, nameof(hydroPumpInfo.CurveQH)); |
| | | this.CurveQP = hydroPumpInfo.CurveQP; |
| | | this.UpdatePropStatus(nameof(this.CurveQP), hydroPumpInfo, nameof(hydroPumpInfo.CurveQP)); |
| | | this.CurveQE = hydroPumpInfo.CurveQE; |
| | | this.UpdatePropStatus(nameof(this.CurveQE), hydroPumpInfo, nameof(hydroPumpInfo.CurveQE)); |
| | | this.Price = hydroPumpInfo.Price; |
| | | this.UpdatePropStatus(nameof(this.Price), hydroPumpInfo, nameof(hydroPumpInfo.Price)); |
| | | this.PricePattern = hydroPumpInfo.PricePattern; |
| | | this.UpdatePropStatus(nameof(this.PricePattern), hydroPumpInfo, nameof(hydroPumpInfo.PricePattern)); |
| | | |
| | | this.Curve = string.IsNullOrEmpty(hydroPumpInfo.CurveQH) ? "未设置" : "已设置"; |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | } |
| | | } |