lixiaojun
2025-01-20 6e1306ab578ed1ad79fc33b0bb7e496b897bf4a4
WinFrmUI/HStation.WinFrmUI.Assets.Core/21-compressor/02-main/AddAssetsCompressorMainDlg.cs
@@ -1,16 +1,6 @@
using DevExpress.XtraEditors;
using DevExpress.XtraScheduler.Outlook.Interop;
using HStation.Service.Assets;
using HStation.Service.Assets;
using HStation.Vmo;
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 Yw;
namespace HStation.WinFrmUI
@@ -71,19 +61,9 @@
                this.dxErrorProvider1.SetError(this.txtName, "必填项");
                return false;
            }
            if (string.IsNullOrEmpty(this.txtMaterial.Text.Trim()))
            {
                this.dxErrorProvider1.SetError(this.txtMaterial, "必填项");
                return false;
            }
            if (string.IsNullOrEmpty(this.txtMinorLoss.Text.Trim()))
            {
                this.dxErrorProvider1.SetError(this.txtMinorLoss, "必填项");
                return false;
            }
            if (string.IsNullOrEmpty(this.txtLowerLimit.Text.Trim()))
            {
                this.dxErrorProvider1.SetError(this.txtLowerLimit, "必填项");
                return false;
            }
            var tagname = this.txtTagName.Text.Trim();
@@ -148,12 +128,13 @@
            }
            return _allFactorList;
        }
        private List<AssetsCompressorFactorVmo> _allFactorList = null;
        //匹配系数
        private async void MatchingFactor()
        {
            if (this.txtMinorLoss.EditValue == null && this.txtLowerLimit.EditValue == null)
            if (this.txtMinorLoss.EditValue == null)
            {
                var allFactorList = await GetAllFactorList();
                if (allFactorList != null && allFactorList.Count > 0)
@@ -188,7 +169,5 @@
        {
            MatchingFactor();
        }
    }
}