From 6db62ddd8db0a54afa15e06bb554950069e3859a Mon Sep 17 00:00:00 2001 From: lu <99954486@qq.com> Date: 星期一, 14 四月 2025 17:19:04 +0800 Subject: [PATCH] fqc --- DevApp/Gs.DevApp/DevFrm/FQC/Frm_FqcDetect01.cs | 105 +++++++++++++++++++++++++++++++++++++++------------- 1 files changed, 79 insertions(+), 26 deletions(-) diff --git a/DevApp/Gs.DevApp/DevFrm/FQC/Frm_FqcDetect01.cs b/DevApp/Gs.DevApp/DevFrm/FQC/Frm_FqcDetect01.cs index fc5edf2..6775bc9 100644 --- a/DevApp/Gs.DevApp/DevFrm/FQC/Frm_FqcDetect01.cs +++ b/DevApp/Gs.DevApp/DevFrm/FQC/Frm_FqcDetect01.cs @@ -51,16 +51,10 @@ gvMx1.FocusedRowChanged += GvMx1_FocusedRowChanged; btnIpt.Click += BtnIpt_Click; txt_suppId.getSuppler(""); - txt_lineId.getSuppler(""); - txt_itemId.Click += (s, e) => + //閫夋嫨宸ュ崟 + txt_lotNo.Click += (s, e) => { - string _lineId = txt_lineId.GetId(); - if (string.IsNullOrEmpty(_lineId)) - { - Gs.DevApp.ToolBox.MsgHelper.ShowInformation("璇峰厛閫夋嫨浜х嚎锛�"); - return; - } - var frm = new SelectFqcItem(_lineId); + var frm = new SelectFqcDaa(); frm.UpdateParent += (ss, ee) => { try @@ -72,6 +66,43 @@ txt_itemName.Text = lst[0].itemName; txt_itemNo.Text = lst[0].itemNo; txt_lotNo.Text = lst[0].gdbh; + txt_lineName.Text = lst[0].lineName; + txt_lineId.Text = lst[0].lineId; + txt_checkStates.Text = "W:鏈煡"; + txt_fcheckResu.Text = "W:鏈煡"; + txt_freceQty.Text = "W:鏈煡"; + } + catch (Exception ex) + { + MessageBox.Show(ex.Message); + } + }; + frm.ShowDialog(); + }; + //閫夋嫨绠辩爜 + txt_kbList.Click += (s, e) => + { + string _lotNo = txt_lotNo.Text.Trim(); + if (string.IsNullOrEmpty(_lotNo)) + { + Gs.DevApp.ToolBox.MsgHelper.ShowInformation("璇峰厛閫夋嫨宸ュ崟锛�"); + return; + } + var frm = new SelectFqcBox(_lotNo); + frm.UpdateParent += (ss, ee) => + { + try + { + var lst = new List<string>(); + lst = ee.StringList; + System.Text.StringBuilder sb = new System.Text.StringBuilder(); + foreach (var item in lst) + { + if (sb.Length > 0) + sb.Append(","); + sb.Append(item); + }; + txt_kbList.Text = sb.ToString(); } catch (Exception ex) { @@ -450,14 +481,15 @@ string _txt_fbatchQty = txt_fbatchQty.Text.Trim();//鎶芥鏁伴噺 string _txt_lifnr = txt_lifnr.Text.Trim();//瀹㈡埛璁㈠崟 string _txt_suppId = txt_suppId.GetId();//瀹㈡埛id - string _txt_lineId = txt_lineId.GetId();//浜х嚎 - string _txt_itemId = txt_itemId.Text.Trim();//浜у搧 + string _txt_lineId = "";//浜х嚎 + string _txt_itemId = "";//浜у搧 string _txt_remarks = txt_remarks.Text.Trim();//澶囨敞 string _txt_epTag = txt_epTag.Text.Trim();//鐜繚 string _txt_msg = txt_msg.TextTxt;//寮傚父 string _txt_fmanageNo = txt_fmanageNo.Text.Trim();//娴佺▼缂栧彿 string _txt_lotNo1 = txt_lotNo1.Text.Trim();//閫佹鎵瑰彿 string _txt_lotNo = txt_lotNo.Text.Trim();//鐢熶骇宸ュ崟 + string _kbList = txt_kbList.Text.Trim(); if (txt_djType.SelectedIndex <= 0) { Gs.DevApp.ToolBox.MsgHelper.Warning("鍗曟嵁绫诲瀷涓嶈兘涓虹┖锛�"); @@ -468,18 +500,6 @@ { Gs.DevApp.ToolBox.MsgHelper.Warning("鎶芥鏁伴噺涓嶈兘涓虹┖锛�"); txt_fbatchQty.Focus(); - return; - } - if (string.IsNullOrEmpty(_txt_lineId.Trim())) - { - Gs.DevApp.ToolBox.MsgHelper.Warning("浜х嚎涓嶈兘涓虹┖锛�"); - txt_lineId.Focus(); - return; - } - if (string.IsNullOrEmpty(_txt_itemId.Trim())) - { - Gs.DevApp.ToolBox.MsgHelper.Warning("浜у搧涓嶈兘涓虹┖锛�"); - txt_itemId.Focus(); return; } if (string.IsNullOrEmpty(_txt_lotNo.Trim())) @@ -504,6 +524,7 @@ lotNo1 = _txt_lotNo1,//閫佹鎵瑰彿 lotNo = _txt_lotNo,//鐢熶骇宸ュ崟 edtType = 0, + kbList = _kbList, list = new List<dynamic>(), }; gvMx1.CloseEditor(); @@ -678,6 +699,10 @@ { if (e.Page.Name == "tabMxPage2") { + getList14(); + } + if (e.Page.Name == "tabMxPage3") + { ucUpFileList1.getFileList(); } } @@ -723,9 +748,39 @@ } } + /// <summary> + /// 杩欐槸璁板綍琛� + /// </summary> + private void getList14() + { + var _obj = new + { + parentGuid = UtilityHelper.ToGuid(lbGuid.Text.Trim()), //涓诲缓 + }; + try + { + var strJson = UtilityHelper.HttpPost("", _webServiceName + "GetModel14", JsonConvert.SerializeObject(_obj)); + JObject _job = JObject.Parse(strJson); + JArray array = new JArray(); + foreach (var a in _job["rtnData"]["list"]) + { + array.Add(a); + } + DataTable dt = JsonConvert.DeserializeObject<DataTable>(array.ToString()); + gcMx14.BindingContext = new BindingContext(); + gcMx14.DataSource = dt; + gcMx14.ForceInitialize(); + gvMx14.BestFitColumns(); + } + catch (Exception ex) + { + MsgHelper.Warning("鎻愮ず锛�" + ex.Message); + } + } + private void setEable(bool bl) { - txtJianYan.ReadOnly = !bl; + txtChouJian.ReadOnly=txtJianYan.ReadOnly = !bl; btnLoad.Enabled = bl; btnIpt.Text = (bl == true ? "褰曞叆鏍锋湰" : "鏌ョ湅鏍锋湰"); } @@ -781,7 +836,5 @@ }; frm.ShowDialog(); } - - } } \ No newline at end of file -- Gitblit v1.9.3