SVN-Revision: r795
This commit is contained in:
cyf
2025-06-27 01:58:24 +00:00
parent 505dc2d949
commit d7a2307850
2 changed files with 70 additions and 62 deletions
+22 -15
View File
@@ -220,6 +220,10 @@ namespace Lskj.PubBillSpecial
/// 扫码框
/// </summary>
public TextEdit ScanCodeTextEdit = null;
/// <summary>
/// 右侧表格
/// </summary>
public ModuleGridEx gridEx = null;
public BillModule()
{
@@ -634,15 +638,15 @@ namespace Lskj.PubBillSpecial
/// </summary>
private void InitializeModuleGridex()
{
DynamicModel dyncModel = new DynamicModel(new string[] {"", ERPInfo.Instance.UserId, ERPInfo.Instance.UserName, this.SysModel.Privilege, this.BillModel.RightModuleCode, "0" });
DataRow moduleInformation = MainImpl.GetSystemdllTab(this.BillModel.RightModuleCode);
DynamicModel dyncModel = new DynamicModel(new string[] { "", ERPInfo.Instance.UserId, ERPInfo.Instance.UserName, this.SysModel.Privilege, this.BillModel.RightModuleCode, "0" });
DataRow moduleInformation = MainImpl.GetSystemdllTab(this.BillModel.RightModuleCode);
if (moduleInformation == null)
{
MessageUtil.Show("没有找到编号为" + this.BillModel.RightModuleCode + "的模块信息");
return;
}
ModuleModel model = new ModuleModel(moduleInformation);
ModuleGridEx gridEx = new ModuleGridEx();
this.gridEx = new ModuleGridEx();
model.ParmaryKey = BaseImpl.GetBasePrimaryKey(this.BillModel.RightModuleCode);
gridEx.OnSaveGridCallBack += OnDetailSaveGridCallBack;
gridEx.DetailRightGridCallBack += OnDetailRightCallback;
@@ -651,7 +655,7 @@ namespace Lskj.PubBillSpecial
gridEx.Dock = DockStyle.Fill;
gridEx.OperShortMode = false; // 不显示简短模式
gridEx.VisibleSearchPanel = false;
gridEx.VisibleOperPanel =true;
gridEx.VisibleOperPanel = true;
gridEx.InitializeControl(model, dyncModel);
gridEx.GridControlObj.Tag = model;//都在本地图可留着备用
//gridEx.ParentControlEx = this.gcMain;
@@ -659,6 +663,9 @@ namespace Lskj.PubBillSpecial
gridEx.ParentGridEx = this.gcMain;//父级关联明细可扩展
//gridEx.ParentKeyField = string.IsNullOrEmpty(model.UnionParentField) ? model.SystemModel.ParmaryKey : model.UnionParentField;
//gridEx.DetailKeyField = model.UnionValue;//新增关联可拖拽刷新数据源
gridEx.VisibleSearchPanel = false;
gridEx.GridControlObj.ParentControl = gridEx.SearchObj;
this.splitMainControl.Panel2.Controls.Add(gridEx);
gridEx.SearchObj.SearchGrid();
@@ -667,11 +674,11 @@ namespace Lskj.PubBillSpecial
#region
private void OnDetailRightCallback(object sender, EventArgs e)
{
throw new NotImplementedException();
}
private void OnDetailSaveGridCallBack(object sender, EventArgs e)
{
throw new NotImplementedException();
}
#endregion
@@ -6485,11 +6492,11 @@ namespace Lskj.PubBillSpecial
{
Type = "B";
}
else
else
{
string Sql = string.Format("select line_str from wms_ScanCodeLinetab a where modid='{0}' and hl_tig='{1}'", this.SysModel.ModuleCode, DocumentColor);
Type = SqlHelper.ExecuteScalar(Sql) + "";
if (string.IsNullOrWhiteSpace(Type))
if (string.IsNullOrWhiteSpace(Type))
{
MessageUtil.Show("扫码配置错误,请联系朗速服务人员");
return;
@@ -6498,11 +6505,11 @@ namespace Lskj.PubBillSpecial
switch (Type.ToUpper())
{
case "A":
FrmAdd frmAdd = new FrmAdd();
if (frmAdd.ShowDialog() == DialogResult.OK)
{
@@ -6514,7 +6521,7 @@ namespace Lskj.PubBillSpecial
textEdit.Focus();
return;
}
this.ExecuteWcanningSQL(MainRowItem, Quantity+"", DocumentColor, inputText);
this.ExecuteWcanningSQL(MainRowItem, Quantity + "", DocumentColor, inputText);
break;
case "B":
this.ExecuteWcanningSQL(MainRowItem, Quantity + "", DocumentColor, inputText);
@@ -6561,7 +6568,7 @@ namespace Lskj.PubBillSpecial
}
}
break;
}
}
@@ -6578,7 +6585,7 @@ namespace Lskj.PubBillSpecial
///<param name="Quantity">数量</param>
///<param name="DocumentColor">红蓝单据字段</param>
///<param name="Codes">串码,多个用;隔开</param>
public void ExecuteWcanningSQL(DataRow MainRowItem, string Quantity, string DocumentColor,string Codes)
public void ExecuteWcanningSQL(DataRow MainRowItem, string Quantity, string DocumentColor, string Codes)
{
int j = 0;
foreach (string code in Codes.TrimEnd(';').Split(';'))
@@ -6657,11 +6664,11 @@ namespace Lskj.PubBillSpecial
if (string.IsNullOrWhiteSpace(varchar))
{
//刷新当前单据
if (j == Codes.TrimEnd(';').Split(';').Length - 1 )
if (j == Codes.TrimEnd(';').Split(';').Length - 1)
{
this.SetBillStatus(BillImpl.GetDataRowResult(string.Format("select * from {0} where {1}='{2}'", BillModel.MasterTable, BillModel.PrimaryKey, this.lblOrderNo.Text)));
}
}
else
{