SVN r924
SVN-Revision: r924
This commit is contained in:
@@ -500,10 +500,11 @@ namespace Lskj.Control
|
||||
}
|
||||
else
|
||||
{
|
||||
this.TabObj.TabPages.Clear();
|
||||
DataRow rowItem = this.ModuleGridObj.GridControlObj.GetViewFocusedDataRow();
|
||||
if (rowItem == null) return;
|
||||
string mainModuleCode = (rowItem[SysModel.MainModuleCodeField] + "").ToLower();
|
||||
//mainModuleCode = String.Empty;
|
||||
this.TabObj.TabPages.Clear();
|
||||
//if (string.IsNullOrWhiteSpace(mainModuleCode)) return;
|
||||
if (!string.IsNullOrWhiteSpace(mainModuleCode) && this.tcButtom.DetailTabPagesDic.ContainsKey(mainModuleCode))
|
||||
{
|
||||
@@ -820,29 +821,6 @@ namespace Lskj.Control
|
||||
{
|
||||
moduleGridEx.ParentButtonState(rowItem);
|
||||
moduleGridEx.SelectTheSpecifiedRow();
|
||||
//主表,页签中的表格都设置了复选框,并且为第一个页签
|
||||
//if (this.ModuleGridObj.GridControlObj.GridView.OptionsSelection.MultiSelect == true && moduleGridEx.GridControlObj.GridView.OptionsSelection.MultiSelect == true && this.TabObj.TabPages[0] == tabPage)
|
||||
//{
|
||||
// if (this.SearchObj.DetailSelection.ContainsKey(model.DetailName))
|
||||
// {
|
||||
// Dictionary<DataRow, string> dictionary = this.SearchObj.DetailSelection[model.DetailName];
|
||||
// if (dictionary.ContainsKey(rowItem))
|
||||
// {
|
||||
// DataTable dataTable = moduleGridEx.GridControlObj.GridControl.DataSource as DataTable;
|
||||
// string value = dictionary[rowItem];
|
||||
// for (int rowHandle = 0; rowHandle < moduleGridEx.GridControlObj.GridView.RowCount; rowHandle++)
|
||||
// {
|
||||
// string cellValue = moduleGridEx.GridControlObj.GridView.GetRowCellValue(rowHandle, moduleGridEx.ParmaryKey) + "";
|
||||
// if (value.Split(',').Contains(cellValue))
|
||||
// {
|
||||
// moduleGridEx.GridControlObj.GridView.SelectRow(rowHandle); // 勾选
|
||||
// }
|
||||
// }
|
||||
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1352,4 +1330,40 @@ namespace Lskj.Control
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 判断是否有未保存的数据,并保存
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public bool VerificationInterface()
|
||||
{
|
||||
if (SystemInfo.Instance.EfficientVerification)
|
||||
{
|
||||
//页签验证
|
||||
if (!this.TcButtom.CheckIfSaved())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
//主表验证
|
||||
if (this.ModuleGridObj.GridControlObj.IsDataNotSaved())
|
||||
{
|
||||
DialogResult dialog = MessageUtil.Show("主表有数据未保存,是否保存", MessageBoxButtons.YesNo);
|
||||
if (dialog == DialogResult.Yes)
|
||||
{
|
||||
bool SaveResults = this.ModuleGridObj.SaveWhenSwitching();
|
||||
if (!SaveResults) return false;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user