using DevExpress.XtraEditors;
|
using System;
|
using System.Windows.Forms;
|
|
namespace ISupply.WinFrm.Main
|
{
|
/// <summary>
|
/// 设置排序码
|
/// </summary>
|
public partial class SetSortCodeDlg : XtraForm
|
{
|
public SetSortCodeDlg()
|
{
|
InitializeComponent();
|
}
|
|
/// <summary>
|
/// 回调事件
|
/// </summary>
|
public event Func<int, bool> ReloadDataEvent;
|
|
|
public void SetBindingData(int sortcode)
|
{
|
this.txtSortCode.EditValue = sortcode;
|
}
|
|
|
|
|
private void btnOk_Click(object sender, EventArgs e)
|
{
|
if (this.ReloadDataEvent.Invoke(Convert.ToInt32(this.txtSortCode.EditValue)))
|
{
|
XtraMessageBox.Show("修改成功!");
|
}
|
else
|
{
|
XtraMessageBox.Show("修改失败!");
|
return;
|
}
|
this.Close();
|
}
|
}
|
}
|