/// <summary> /// 增加数据-多芯 /// </summary> /// <param name="e"></param> public void Add_Pack2(Maticsoft.DAL.My_GetTestData.UpDataEventArgs e) { string dt = DateTime.Now.ToString(); int _temRecord = 0; int tem; foreach (DataRow dr in e.TestData.Tables[0].Rows) { Maticsoft.Model.Pack_3D PK_3D = DataRowToModel(dr); tem = (int.Parse(PK_3D.SN.Substring(11, 2).ToString()) - 1) * 8 + int.Parse(PK_3D.Name); PK_3D.OrderID = e.WorkOrder.OrderID; PK_3D.BatchNo = e.BatchNo; PK_3D.ClientSN = e.ClientSN; PK_3D.Name = tem.ToString(); PK_3D.PackDate = dt; dbs.Exists("delete from tb_Pack_3D WHERE SN ='" + PK_3D.SN + "' AND Name ='" + PK_3D.Name + "'"); if (Add(PK_3D) == 0) //返回更新结果 { ++_temRecord; } } /* * if (_temRecord != 0) * { * e.Result = false; * } * else { e.Result = true; } */ }
private void Inspect_One_Inspect_Exfo(InspectEventArgs e, ResultEventArgs _Result) { //检测-Exfo string temWhere_Exfo = _M_User_Exfo.GetSql_Where(_GLL_WorkOrder, _GLL_Standard_PigtailList, e.SN); Maticsoft.DAL.My_GetTestData.GetDataEventArgs GetData_Exfo_e = new Maticsoft.DAL.My_GetTestData.GetDataEventArgs(temWhere_Exfo, e.SN); _Result.Data_Exfo = _GLL_TestData.Start_GetData_Exfo(GetData_Exfo_e); ArrayList Inspect_Exfo = isEqual(_GLL_Standard_PigtailList, GetData_Exfo_e.PigtailList); if (Inspect_Exfo.Count > 0) { _Result.Fill_Exfo = ArrayListToString(Inspect_Exfo); _Result.Result_Exfo = false; } else { //更新数据 Maticsoft.DAL.My_GetTestData.UpDataEventArgs UpData_Exfo_e = new Maticsoft.DAL.My_GetTestData.UpDataEventArgs(GetData_Exfo_e.TestData, _GLL_WorkOrder, _GLL_PackBatch.BatchNo, e.SN); _GLL_TestData.Start_UpData_Exfo(UpData_Exfo_e); _Result.Result_Exfo = true; //判断3D是否OK 进行添加打印数据 if (_Result.Result_3D) { //如果需要打印标签 if (My_Print.IsPrint) { //添加打印数据 My_Print.Add_PrintData(_M_Pack_Exfo.GetList("ClientSN='" + e.SN + "' AND (Wave = '1550nm')")); } } } }
/// <summary> /// 两码两签 检测Exfo /// </summary> private void Inspect_TwoSnToLab_Inspect_Exfo(InspectEventArgs e, ResultEventArgs _Result) { //------------------------------------------------检测-Exfo string temWhere_Exfo = _M_User_Exfo.GetSql_Where(_GLL_WorkOrder, _GLL_Standard_PigtailList); Maticsoft.DAL.My_GetTestData.GetDataEventArgs GetData_Exfo_e = new Maticsoft.DAL.My_GetTestData.GetDataEventArgs(temWhere_Exfo, e.ClientSN); _Result.Data_Exfo = _GLL_TestData.Start_GetData_Exfo(GetData_Exfo_e); ArrayList Inspect_Exfo = isEqual(_GLL_Standard_PigtailList, GetData_Exfo_e.PigtailList); if (Inspect_Exfo.Count > 0) { _Result.Fill_Exfo = ArrayListToString(Inspect_Exfo); _Result.Result_Exfo = false; } else { //更新数据 Maticsoft.DAL.My_GetTestData.UpDataEventArgs UpData_Exfo_e = new Maticsoft.DAL.My_GetTestData.UpDataEventArgs(GetData_Exfo_e.TestData, _GLL_WorkOrder, _GLL_PackBatch.BatchNo, e.SN); _GLL_TestData.Start_UpData_Exfo(UpData_Exfo_e); _Result.Result_Exfo = true; if (_Result.Result_3D) //如果3D为良品 { //如果需要打印标签 if (My_Print.IsPrint) { foreach (string temSN in _GLL_Standard_PigtailList) { //添加打印数据 DataSet temds = _M_Pack_Exfo.GetList("ClientSN='" + temSN + "' AND (Wave = '1550nm')"); My_Print.Add_PrintData(temds); } } } } //设置配组 为未完成 因为不需要进行配组 _Result.Combination = false; }
private void Inspect_One_Inspect_3D(InspectEventArgs e, ResultEventArgs _Result) { //检测-3D string temWhere_3D = _M_User_3D.GetSql_Where(_GLL_WorkOrder, _GLL_Standard_PigtailList, e.SN); Maticsoft.DAL.My_GetTestData.GetDataEventArgs GetData_3D_e = new Maticsoft.DAL.My_GetTestData.GetDataEventArgs(temWhere_3D, e.SN); _Result.Data_3D = _GLL_TestData.Start_GetData_3D(GetData_3D_e); ArrayList Inspect_3D = isEqual(_GLL_Standard_PigtailList, GetData_3D_e.PigtailList); if (Inspect_3D.Count > 0) { _Result.Fill_3D = ArrayListToString(Inspect_3D); _Result.Result_3D = false; } else { //更新数据 Maticsoft.DAL.My_GetTestData.UpDataEventArgs UpData_3D_e = new Maticsoft.DAL.My_GetTestData.UpDataEventArgs(GetData_3D_e.TestData, _GLL_WorkOrder, _GLL_PackBatch.BatchNo, e.SN); _GLL_TestData.Start_UpData_3D(UpData_3D_e); _Result.Result_3D = true; } }
private void Inspect_Three_Inspect_Exfo(InspectEventArgs e, ResultEventArgs _Result) { //------------------------------------------------检测-Exfo string temWhere_Exfo = _M_User_Exfo.GetSql_Where(_GLL_WorkOrder, _GLL_Standard_PigtailList, e.SN); Maticsoft.DAL.My_GetTestData.GetDataEventArgs GetData_Exfo_e = new Maticsoft.DAL.My_GetTestData.GetDataEventArgs(temWhere_Exfo, e.ClientSN); _Result.Data_Exfo = _GLL_TestData.Start_GetData_Exfo(GetData_Exfo_e); ArrayList Inspect_Exfo = isEqual(_GLL_Standard_PigtailList, GetData_Exfo_e.PigtailList); if (Inspect_Exfo.Count > 0) { _Result.Fill_Exfo = ArrayListToString(Inspect_Exfo); _Result.Result_Exfo = false; } else { //更新数据 Maticsoft.DAL.My_GetTestData.UpDataEventArgs UpData_Exfo_e = new Maticsoft.DAL.My_GetTestData.UpDataEventArgs(GetData_Exfo_e.TestData, _GLL_WorkOrder, _GLL_PackBatch.BatchNo, e.SN); _GLL_TestData.Start_UpData_Exfo(UpData_Exfo_e); _Result.Result_Exfo = true; } }
/// <summary> /// 添加包装数据 /// </summary> /// <param name="e"></param> public void Add_Pack(Maticsoft.DAL.My_GetTestData.UpDataEventArgs e) { dal.Add_Pack(e); }