namespace HStation.WinFrmUI
|
{
|
public partial class ValveSingleMatchingDlg : DevExpress.XtraEditors.XtraForm
|
{
|
public ValveSingleMatchingDlg()
|
{
|
InitializeComponent();
|
}
|
|
public event Action<ValveMatchingViewModel> ReloadDataEvent;
|
|
private ValveMatchingViewModel _ValveMatchingView = null;
|
|
public void SetBindingData(ValveMatchingViewModel ValveMatchingViewModel)
|
{
|
this.xtraUserControl11.SetBindingData(ValveMatchingViewModel);
|
_ValveMatchingView = ValveMatchingViewModel;
|
}
|
|
//确定
|
private void btnComplete_Click(object sender, EventArgs e)
|
{
|
if (_ValveMatchingView.MatchingDbId == null || _ValveMatchingView.MatchingDbId == string.Empty)
|
{
|
TipFormHelper.ShowError("阀门型号选择错误");
|
return;
|
}
|
if (_ValveMatchingView.MatchingChartDbId == null || _ValveMatchingView.MatchingChartDbId == string.Empty)
|
{
|
TipFormHelper.ShowError("曲线选择错误");
|
return;
|
}
|
ReloadDataEvent.Invoke(_ValveMatchingView);
|
}
|
}
|
}
|