tx
2025-04-10 2538101febc78f525945da72c7cdcb2589f9e6ea
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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
using DevExpress.XtraEditors;
using DevExpress.XtraPrinting.Native;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using TProduct.Common;
using TProduct.Model; 
 
namespace TProduct.WinFrmUI.TValve
{
    /// <summary>
    /// 性能测试
    /// </summary>
    public partial class FeatTestIngMainPage
    {
        private void barBtn清空测试数据_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            if (this._allRecords == null || this._allRecords.Count() == 0)
                return;
            DialogResult result1 = MessageBox.Show("请问是否清空测试数据", "询问",
System.Windows.Forms.MessageBoxButtons.YesNo,
System.Windows.Forms.MessageBoxIcon.Warning);
            if (result1 != DialogResult.Yes)
            {
                return;
            }
 
            DialogResult result2 = MessageBox.Show("请问是否清空测试数据,删除后, 数据无法恢复,请再次确认", "询问",
System.Windows.Forms.MessageBoxButtons.YesNo,
System.Windows.Forms.MessageBoxIcon.Warning);
            if (result2 != DialogResult.Yes)
            {
                return;
            }
            new TProduct.BLL.ValveFeatTestRecord().ClearAllRecord(this._testItem);
            this._allRecords.Clear();
            this._monitorGridCtrl.ClearData();
            this._chartCtrl.EmptyRecordPoint();
            this._correctPtGridCtrl.ClearData();
        }
 
        private void barBtn导出测试数据_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            if (this._allRecords == null || this._allRecords.Count() == 0)
                return;
            this._monitorGridCtrl.ExportExcel();
        }
 
        private void barBtn测试台参数_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            if(this._workBenchInfo.LinkType == eLinkType.ShunZhou)
            {
                Data4Factory.ViewWorkBench4ShunDlg frm = new Data4Factory.ViewWorkBench4ShunDlg();
                frm.SetBindingData(this._workBenchInfo);
                frm.Show();
            }
 
 
        }
 
        private void barBtn仪表参数_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            Data4Factory.ListWorkBenchMonitorPointDlg frm = new Data4Factory.ListWorkBenchMonitorPointDlg();
            frm.SetBindingData(this._workBenchInfo);
            frm.Show();
        }
 
        private void barBtn设备参数_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
 
        }
 
 
        //List<TProduct.Model.TestJudgeItemResultViewModel> _testJudgeResults = null;
        private void barBtn合格判定_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            if(this._allRecords == null || this._allRecords.Count() < 4)
            {
                MessageBox.Show("点数量过少,暂时无法判断");
                return;
            }
            //TProduct.Common.PumpTestJudgeHelper helper = new TProduct.Common.PumpTestJudgeHelper();
            //helper.SetRatedParas(this._ratedParas);
            //helper.SetStandard(this._testStandard, this._testGrade, this._testJudgeItems);
 
        
            //var isQualified = helper.JudgeQH(this._allRecords,out _testJudgeResults);
            //if(isQualified)
            //{
            //    MessageBox.Show("合格");
            //    return;
            //}
            //else
            //{
            //    MessageBox.Show("不合格");
            //    return;
            //}
        }
 
        private void barBtn判定详情_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            //if (this._allRecords == null || this._allRecords.Count() < 4)
            //{
            //    MessageBox.Show("点数量过少,暂时无法判断");
            //    return;
            //}
            //if (_testJudgeResults == null)
            //{
            //    TProduct.Common.PumpTestJudgeHelper helper = new TProduct.Common.PumpTestJudgeHelper();
            //    helper.SetRatedParas(this._ratedParas);
            //    helper.SetStandard(this._testStandard, this._testGrade, this._testJudgeItems);
            //    helper.JudgeQH(this._allRecords, out _testJudgeResults);
            //}
           
            //ResultJudgeForm frm = new ResultJudgeForm();
            //frm.SetRatedParas(this._ratedParas);
            //frm.SetBindingData(this._testStandard, this._testGrade, this._testJudgeItems,_testJudgeResults);
            //frm.Show();
        }
    }
}