lixiaojun
2025-02-13 bfd1b73be85fd66ee37031eadcd4d09e7dafb52f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
namespace Yw.WinFrmUI
{
    /// <summary>
    /// 
    /// </summary>
    public class HydroSinglePumpListItemExtendViewModel
    {
 
        /// <summary>
        /// 
        /// </summary>
        public HydroSinglePumpListItemExtendViewModel() { }
 
        /// <summary>
        /// 
        /// </summary>
        public HydroSinglePumpListItemExtendViewModel(Yw.Model.HydroPumpInfo rhs, bool isRated)
        {
            if (isRated)
            {
                this.Name = "额定曲线";
                this.Color = Color.Black;
                this.Hz = rhs.RatedHz;
                this.Extend = 100;
 
            }
            else
            {
                this.Name = "设定曲线";
                this.Color = Color.Red;
                this.Hz = Math.Round(rhs.RatedHz * rhs.SpeedRatio, 1);
                this.Extend = 100;
            }
            this.IsRated = isRated;
 
            this.Vmo = rhs;
        }
 
        /// <summary>
        /// 名称
        /// </summary>
        [Display(Name = "名称")]
        public string Name { get; set; }
 
        /// <summary>
        /// 颜色
        /// </summary>
        [Display(Name = "颜色")]
        public Color Color { get; set; }
 
        /// <summary>
        /// 频率
        /// </summary>
        [Display(Name = "频率(hz)")]
        public double Hz { get; set; }
 
        /// <summary>
        /// 转速
        /// </summary>
        [Display(Name = "转速(r/min)")]
        public double N
        {
            get
            {
                if (this.Vmo == null)
                {
                    return default;
                }
                return Math.Round(this.Hz / this.Vmo.RatedHz * this.Vmo.RatedN, 1);
            }
        }
 
        /// <summary>
        /// 延长
        /// </summary>
        [Display(Name = "延长(%)")]
        public double Extend { get; set; }
 
        /// <summary>
        /// 额定
        /// </summary>
        [Display(Name = "额定")]
        public bool IsRated { get; set; }
 
        /// <summary>
        /// 
        /// </summary>
        public Yw.Model.HydroPumpInfo Vmo { get; set; }
 
 
    }
}