duheng
2024-11-08 5af88720773df7be98372ff8bce0acffa5dffb73
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
93
namespace Yw.WinFrmUI
{
    /// <summary>
    /// 扩散器视图
    /// </summary>
    public class HydroEmitterViewModel : HydroJunctionViewModel
    {
        /// <summary>
        /// 
        /// </summary>
        public HydroEmitterViewModel() : base() { }
 
        /// <summary>
        /// 
        /// </summary>
        public HydroEmitterViewModel(Yw.Model.HydroEmitterInfo rhs, Yw.Model.HydroModelInfo hydroInfo) : base(rhs, hydroInfo)
        {
            this.Material = rhs.Material;
            this.UpdatePropStatus(nameof(this.Material), rhs, nameof(rhs.Material));
            this.Caliber = rhs.Caliber;
            this.UpdatePropStatus(nameof(this.Caliber), rhs, nameof(rhs.Caliber));
            this.Coefficient = rhs.Coefficient;
            this.UpdatePropStatus(nameof(this.Coefficient), rhs, nameof(rhs.Coefficient));
 
            this.Vmo = rhs;
        }
 
        /// <summary>
        /// 材料
        /// </summary>
        [Category("数据")]
        [DisplayName("材料")]
        [Display(Name = "材料")]
        [PropertyOrder(3001)]
        [Browsable(true)]
        public string Material { get; set; }
 
        /// <summary>
        /// 口径
        /// </summary>
        [Category("数据")]
        [DisplayName("口径")]
        [Display(Name = "口径(mm)")]
        [DisplayUnit("mm")]
        [PropertyOrder(3002)]
        [Browsable(true)]
        public double? Caliber { get; set; }
 
        /// <summary>
        /// 喷射系数
        /// </summary>
        [Category("数据")]
        [DisplayName("喷射系数")]
        [PropertyOrder(3003)]
        [Browsable(true)]
        public virtual double Coefficient { get; set; }
 
        /// <summary>
        /// 
        /// </summary>
        [Browsable(false)]
        public new Yw.Model.HydroEmitterInfo Vmo { get; set; }
 
        /// <summary>
        /// 
        /// </summary>
        public override void UpdateProperty()
        {
            base.UpdateProperty();
            this.Material = this.Vmo.Material;
            this.UpdatePropStatus(nameof(this.Material), this.Vmo, nameof(this.Vmo.Material));
            this.Caliber = this.Vmo.Caliber;
            this.UpdatePropStatus(nameof(this.Caliber), this.Vmo, nameof(this.Vmo.Caliber));
            this.Coefficient = this.Vmo.Coefficient;
            this.UpdatePropStatus(nameof(this.Coefficient), this.Vmo, nameof(this.Vmo.Coefficient));
        }
 
        /// <summary>
        /// 
        /// </summary>
        public override void UpdateVmoProperty()
        {
            base.UpdateVmoProperty();
            this.Vmo.Material = this.Material;
            this.Vmo.UpdatePropStatus(nameof(this.Vmo.Material), this, nameof(this.Material));
            this.Vmo.Caliber = this.Caliber;
            this.Vmo.UpdatePropStatus(nameof(this.Vmo.Caliber), this, nameof(this.Caliber));
            this.Vmo.Coefficient = this.Coefficient;
            this.Vmo.UpdatePropStatus(nameof(this.Vmo.Coefficient), this, nameof(this.Coefficient));
        }
 
    }
}