SVN-Revision: r445
This commit is contained in:
tdx
2025-04-05 13:34:17 +00:00
parent 9cafae5f0a
commit e21b913f31
2 changed files with 26 additions and 0 deletions
+18
View File
@@ -167,7 +167,9 @@ namespace Lskj.PubBomImport
frmProgress.StartImportInQDFile(dirPath);
};
frmProgress.ImportTimer.Enabled = true;
frmProgress.OnImportCallBack += OnImportCallBack;
frmProgress.ShowDialog();
frmProgress.Dispose();
}
else
@@ -211,6 +213,22 @@ namespace Lskj.PubBomImport
this.Dispose();
}
}
/// <summary>
/// 导入后关闭回调
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void OnImportCallBack(object sender, EventArgs e)
{
FormDialogModel dialogModel = new FormDialogModel()
{
DialogDllName = "Lskj.PubBomImport.dll",
PubDialogType = DialogType.PubAddRecord,
ReturnTag = Model.ShowType
};
this.Tag = dialogModel;
}
/// <summary>
/// 读取按钮点击
/// </summary>
@@ -43,6 +43,10 @@ namespace Lskj.PubBomImport
/// </summary>
public partial class FrmProgress : Form
{
/// <summary>
/// Occurs when [on add record call back].
/// </summary>
public event EventHandler OnImportCallBack;
public FrmMain frmMain;
public DynamicBomImport Model;
public System.Windows.Forms.Timer ImportTimer = new System.Windows.Forms.Timer();
@@ -568,6 +572,8 @@ namespace Lskj.PubBomImport
}
finally
{
if (this.OnImportCallBack != null)
this.OnImportCallBack(null, null);
this.DialogResult = DialogResult.OK;
this.Close();
ImportTimer?.Dispose();
@@ -657,6 +663,8 @@ namespace Lskj.PubBomImport
}
finally
{
if (this.OnImportCallBack != null)
this.OnImportCallBack(null, null);
this.DialogResult = DialogResult.OK;
this.Close();
ImportTimer?.Dispose();