Browse Source

BZD调整

master
张松男 1 year ago
parent
commit
dea7b53b54
  1. 8
      APPQ5/QMAPP.FJC.BLL/BZD/BZDConfigBLL.cs
  2. 21
      APPQ5/QMAPP.FJC.DAL/BZD/BZDConfigDAL.cs
  3. 8
      APPQ5/QMAPP.FJC.Entity/BZD/BZDConfig.cs
  4. 35
      APPQ5/QMAPP.WinForm/Forms/Operation/BZDRePrintForm.cs
  5. 10
      APPQ5/QMAPP.WinForm/Forms/Operation/BZDRePrintForm.designer.cs
  6. 3
      AppCommon/QMAPP.ServicesAgent/ServiceEnums.cs

8
APPQ5/QMAPP.FJC.BLL/BZD/BZDConfigBLL.cs

@ -106,6 +106,14 @@ namespace QMAPP.FJC.BLL.BZD
{ {
return new BZDConfigDAL().GetAllList(); return new BZDConfigDAL().GetAllList();
} }
/// <summary>
/// 获取全部条码格式规则
/// </summary>
/// <returns></returns>
public List<BZDConfig> GetGroupList(string str)
{
return new BZDConfigDAL().GetGroupList();
}
#endregion #endregion
#region 信息是否重复 #region 信息是否重复

21
APPQ5/QMAPP.FJC.DAL/BZD/BZDConfigDAL.cs

@ -119,6 +119,27 @@ namespace QMAPP.FJC.DAL.BZD
throw ex; throw ex;
} }
} }
/// <summary>
/// 获取全部规则
/// </summary>
/// <returns></returns>
public List<BZDConfig> GetGroupList()
{
try
{
string sql = "SELECT Column2 FROM [dbo].[T_BD_BZDConfig] GROUP BY Column2";
List<DataParameter> parameters = new List<DataParameter>();
using (IDataSession session = AppDataFactory.CreateSession("maindbBZD"))
{
return session.GetList<BZDConfig>(sql, parameters.ToArray()).ToList();
}
}
catch (Exception ex)
{
throw ex;
}
}
#endregion #endregion
#region 获取查询语句 #region 获取查询语句

8
APPQ5/QMAPP.FJC.Entity/BZD/BZDConfig.cs

@ -113,13 +113,17 @@ namespace QMAPP.FJC.Entity.BZD
[DBColumn(ColumnName = "CREATEDATE", DataType = DbType.DateTime)] [DBColumn(ColumnName = "CREATEDATE", DataType = DbType.DateTime)]
public DateTime CREATEDATE { get; set; } public DateTime CREATEDATE { get; set; }
/// <summary> /// <summary>
/// 有效标志 /// 有效标志
/// </summary> /// </summary>
[DBColumn(ColumnName = "FLGDEL", DataType = DbType.String)] [DBColumn(ColumnName = "FLGDEL", DataType = DbType.String)]
public string FLGDEL { get; set; } public string FLGDEL { get; set; }
/// <summary>
/// 备用字段
/// </summary>
[DBColumn(ColumnName = "Column2", DataType = DbType.String)]
public string Column2 { get; set; }
} }

35
APPQ5/QMAPP.WinForm/Forms/Operation/BZDRePrintForm.cs

@ -20,6 +20,7 @@ namespace QMAPP.WinForm.Forms.Operation
Product _CurrentProduct = null; Product _CurrentProduct = null;
private OperationForm _parentForm; private OperationForm _parentForm;
private OperationForm_316 operationForm_316; private OperationForm_316 operationForm_316;
public bool state = false;
public BZDRePrintForm(OperationForm parentForm) public BZDRePrintForm(OperationForm parentForm)
{ {
@ -27,18 +28,30 @@ namespace QMAPP.WinForm.Forms.Operation
infolabel.Text = ""; infolabel.Text = "";
infolabel.ForeColor = Color.Red; infolabel.ForeColor = Color.Red;
//产线 Line();
_parentForm = parentForm;
}
/// <summary>
/// 查询产线信息
/// </summary>
public void Line()
{
_bzdConfig = _agent.InvokeServiceFunction<List<BZDConfig>>(B9IPCService.BZDConfigBLL_GetGroupList.ToString(), "");
var list_line = new List<Lines>(); var list_line = new List<Lines>();
list_line.Add(new Lines { Code = "VW371仪表板", Name = "VW371仪表板" }); foreach (var t in _bzdConfig)
list_line.Add(new Lines { Code = "BC316仪表板", Name = "BC316仪表板" }); {
list_line.Add(new Lines { Code = "BC316-MP2仪表板", Name = "BC316-MP2仪表板" }); list_line.Add(new Lines { Code = t.Column2, Name = t.Column2 });
list_line.Add(new Lines { Code = "BC316-MP3仪表板", Name = "BC316-MP3仪表板" }); state = true;
}
//产线
this.cbLine.DataSource = list_line; this.cbLine.DataSource = list_line;
this.cbLine.DisplayMember = "Name"; this.cbLine.DisplayMember = "Name";
this.cbLine.ValueMember = "Code"; this.cbLine.ValueMember = "Code";
_parentForm = parentForm;
} }
public BZDRePrintForm(OperationForm_316 operationForm_316) public BZDRePrintForm(OperationForm_316 operationForm_316)
@ -207,22 +220,30 @@ namespace QMAPP.WinForm.Forms.Operation
/// <param name="sender"></param> /// <param name="sender"></param>
/// <param name="e"></param> /// <param name="e"></param>
private void PrintForm_Load(object sender, EventArgs e) private void PrintForm_Load(object sender, EventArgs e)
{
if (state)
{ {
_bzdConfig = _bzdConfig =
_agent.InvokeServiceFunction<List<BZDConfig>>(B9IPCService.BZDConfigBLL_GetAllList.ToString(), ""); _agent.InvokeServiceFunction<List<BZDConfig>>(B9IPCService.BZDConfigBLL_GetAllList.ToString(), "");
var list = new List<BZDConfig>(); var list = new List<BZDConfig>();
foreach (var t in _bzdConfig) foreach (var t in _bzdConfig)
{ {
if (!string.IsNullOrEmpty(cbLine.SelectedValue.ToString()) && t.configDetail.Contains(cbLine.SelectedValue.ToString())) if (!string.IsNullOrEmpty(cbLine.SelectedValue.ToString()))
{
if (t.Column2 == cbLine.SelectedValue.ToString())
{ {
t.MATERIALCODDE = t.MATERIALCODDE + "|" + t.ColorDetail + "|" + t.configDetail; t.MATERIALCODDE = t.MATERIALCODDE + "|" + t.ColorDetail + "|" + t.configDetail;
list.Add(t); list.Add(t);
} }
}
} }
_bzdConfig = list; _bzdConfig = list;
LoadAssyMaterial(); LoadAssyMaterial();
} }
}
#endregion #endregion
#region 加载总成物料 #region 加载总成物料

10
APPQ5/QMAPP.WinForm/Forms/Operation/BZDRePrintForm.designer.cs

@ -71,13 +71,13 @@ namespace QMAPP.WinForm.Forms.Operation
this.txtMainCode.Location = new System.Drawing.Point(260, 372); this.txtMainCode.Location = new System.Drawing.Point(260, 372);
this.txtMainCode.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.txtMainCode.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.txtMainCode.Name = "txtMainCode"; this.txtMainCode.Name = "txtMainCode";
this.txtMainCode.Size = new System.Drawing.Size(509, 49); this.txtMainCode.Size = new System.Drawing.Size(650, 49);
this.txtMainCode.TabIndex = 4; this.txtMainCode.TabIndex = 4;
// //
// button1 // button1
// //
this.button1.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.button1.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.button1.Location = new System.Drawing.Point(780, 372); this.button1.Location = new System.Drawing.Point(944, 372);
this.button1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.button1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.button1.Name = "button1"; this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(184, 53); this.button1.Size = new System.Drawing.Size(184, 53);
@ -116,7 +116,7 @@ namespace QMAPP.WinForm.Forms.Operation
this.cbMaterial.Location = new System.Drawing.Point(261, 222); this.cbMaterial.Location = new System.Drawing.Point(261, 222);
this.cbMaterial.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.cbMaterial.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.cbMaterial.Name = "cbMaterial"; this.cbMaterial.Name = "cbMaterial";
this.cbMaterial.Size = new System.Drawing.Size(703, 49); this.cbMaterial.Size = new System.Drawing.Size(934, 49);
this.cbMaterial.TabIndex = 7; this.cbMaterial.TabIndex = 7;
// //
// label2 // label2
@ -150,7 +150,7 @@ namespace QMAPP.WinForm.Forms.Operation
this.cbLine.Location = new System.Drawing.Point(261, 148); this.cbLine.Location = new System.Drawing.Point(261, 148);
this.cbLine.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.cbLine.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.cbLine.Name = "cbLine"; this.cbLine.Name = "cbLine";
this.cbLine.Size = new System.Drawing.Size(538, 49); this.cbLine.Size = new System.Drawing.Size(572, 49);
this.cbLine.TabIndex = 10; this.cbLine.TabIndex = 10;
this.cbLine.SelectedIndexChanged += new System.EventHandler(this.cbLine_SelectedIndexChanged); this.cbLine.SelectedIndexChanged += new System.EventHandler(this.cbLine_SelectedIndexChanged);
// //
@ -158,7 +158,7 @@ namespace QMAPP.WinForm.Forms.Operation
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F); this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(998, 599); this.ClientSize = new System.Drawing.Size(1306, 599);
this.Controls.Add(this.cbLine); this.Controls.Add(this.cbLine);
this.Controls.Add(this.label4); this.Controls.Add(this.label4);
this.Controls.Add(this.label2); this.Controls.Add(this.label2);

3
AppCommon/QMAPP.ServicesAgent/ServiceEnums.cs

@ -4181,6 +4181,9 @@ namespace QMAPP.ServicesAgent
[Description("查找316总成信息")] [Description("查找316总成信息")]
BZDRecorderBLL_Get316Record, BZDRecorderBLL_Get316Record,
[Description("查询")]
BZDConfigBLL_GetGroupList,
#endregion #endregion

Loading…
Cancel
Save