From ba0c935cafc358cd8dc85b002ce8befba22c04a1 Mon Sep 17 00:00:00 2001 From: lu <123456> Date: 星期一, 11 八月 2025 08:42:59 +0800 Subject: [PATCH] bug --- DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_MesShouTui.cs | 65 ++++++++++++++++++-------------- 1 files changed, 37 insertions(+), 28 deletions(-) diff --git a/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_MesShouTui.cs b/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_MesShouTui.cs index ae48c2b..86547ec 100644 --- a/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_MesShouTui.cs +++ b/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_MesShouTui.cs @@ -75,7 +75,7 @@ this.txt_fStockId.Focus(); return; } - var frm = new SelectShuoTuiSq(this.txt_fCustId.GetId(), txt_fStockOrgId.GetId(), txt_fStockId.GetId(), txt_fIsLink.SelectedIndex.ToString()); + var frm = new SelectShuoTuiSq(this.txt_fCustId.GetId(), txt_fStockOrgId.GetId(), txt_fStockId.GetId(), txt_fHasLinkRad.SelectedIndex.ToString()); //璧嬪�肩粰鏄庣粏琛� frm.UpdateParent += (ss, ee) => { @@ -106,7 +106,7 @@ } catch (Exception ex) { - MessageBox.Show(ex.Message); + Gs.DevApp.ToolBox.MsgHelper.ShowError(ex.Message); } }; frm.ShowDialog(); @@ -206,7 +206,7 @@ lbGuid, txt_billNo, gridView1, "billNo"); if (string.IsNullOrEmpty(rowGuid)) { - MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); + MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); return; } if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾鍒犻櫎鍚楋紵")) @@ -224,20 +224,20 @@ var _rtn = UtilityHelper.ReturnToDynamic(strJson); if (_rtn.rtnCode > 0) { + MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg); if (xtraTabControl1.SelectedTabPageIndex == 0) { } else Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 2); getPageList(this.pageBar1.CurrentPage); } - - MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg); + else + MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg); } catch (Exception ex) { - MsgHelper.Warning("鎻愮ず锛�" + ex.Message); + MsgHelper.ShowError("鎻愮ず锛�" + ex.Message); } - } /// <summary> @@ -275,7 +275,7 @@ lbGuid, txt_billNo, gridView1); if (string.IsNullOrEmpty(rowGuid)) { - MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); + MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); return; } Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3); @@ -289,6 +289,10 @@ gvList.Add(gvMx1); UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, true, gvList); } + //2025/07/12鍔犱笂淇敼鐘舵�佷笅涓嶈兘淇敼 + txt_fStockOrgId.IsReadly = true; + txt_fCustId.IsReadly = true; + txt_fHasLinkRad.ReadOnly = true; } /// <summary> /// 鏂板浜嬩欢 @@ -318,28 +322,27 @@ var _ckId = txt_fStockId.GetId(); var _khId = txt_fCustId.GetId(); string _orgId = txt_fStockOrgId.GetId(); - int _fIsLink = txt_fIsLink.SelectedIndex == 0 ? 1 : 0; if (string.IsNullOrEmpty(_orgId)) { - MsgHelper.Warning("璇烽�夋嫨缁勭粐锛�"); + MsgHelper.ShowError("璇烽�夋嫨缁勭粐锛�"); txt_fStockOrgId.Focus(); return; } if (string.IsNullOrEmpty(_ckId)) { - MsgHelper.Warning("璇烽�夋嫨浠撳簱锛�"); + MsgHelper.ShowError("璇烽�夋嫨浠撳簱锛�"); txt_fStockId.Focus(); return; } if (string.IsNullOrEmpty(_khId)) { - MsgHelper.Warning("璇烽�夋嫨瀹㈡埛锛�"); + MsgHelper.ShowError("璇烽�夋嫨瀹㈡埛锛�"); txt_fCustId.Focus(); return; } if (txt_fReturnStyle.SelectedIndex <= 0) { - MsgHelper.Warning("璇烽�夋嫨閫�鏂欐柟寮忥紒"); + MsgHelper.ShowError("璇烽�夋嫨閫�鏂欐柟寮忥紒"); txt_fReturnStyle.Focus(); return; } @@ -350,14 +353,13 @@ Remark = txt_remark.Text.Trim(), //澶囨敞 CusId = int.Parse(_khId), DepotId = int.Parse(_ckId), - FIsLink = _fIsLink,//鏈夋棤婧愬崟 + FIsLink = txt_fHasLinkRad.SelectedIndex,//鏈夋棤婧愬崟 FReturnStyle = txt_fReturnStyle.Text,//閫�鏂欐柟寮� list = new List<dynamic>(), - }; gvMx1.PostEditor(); + }; + gvMx1.PostEditor(); gvMx1.CloseEditor(); gvMx1.UpdateCurrentRow(); - - if (gvMx1.DataRowCount <= 0) { MsgHelper.ShowError("鏄庣粏涓嶈兘涓虹┖锛岃閫夋嫨浣犵殑鏀舵枡鏄庣粏锛�"); @@ -397,9 +399,9 @@ _webServiceName + "EditModel", JsonConvert.SerializeObject(_obj)); var _rtn = UtilityHelper.ReturnToDynamic(strJson); - MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg); if (_rtn.rtnCode > 0) { + MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg); lbGuid.Text = _rtn.rtnData.outGuid; txt_billNo.Text = _rtn.rtnData.outNo; toolBarMenu1.isSetBtn = true; @@ -409,10 +411,12 @@ toolBarMenu1.currentAction = ""; Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 6); } + else + MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg); } catch (Exception ex) { - MsgHelper.Warning("鎻愮ず锛�" + ex.Message); + MsgHelper.ShowError("鎻愮ず锛�" + ex.Message); } } @@ -465,7 +469,7 @@ if (toolBarMenu1.currentAction == "edit") isEdit = true; if (string.IsNullOrEmpty(strGuid)) { - ToolBox.MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); + ToolBox.MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); return; } var _obj = new @@ -507,11 +511,11 @@ } } else - ToolBox.MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg); + ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg); } catch (Exception ex) { - ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message); + ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message); } } /// <summary> @@ -535,7 +539,7 @@ (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_billNo, gridView1, "billNo"); if (string.IsNullOrEmpty(rowGuid)) { - MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); + MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�"); return; } if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾" + strMsg + "鍚楋紵")) @@ -551,9 +555,10 @@ _webServiceName + "EditModelSubmit", JsonConvert.SerializeObject(_obj)); var _rtn = UtilityHelper.ReturnToDynamic(strJson); - MsgHelper.Warning(_rtn.rtnData.outMsg.ToString()); + if (_rtn.rtnCode > 0 && _rtn.rtnData.outSum * 1 > 0) { + MsgHelper.ShowInformation(_rtn.rtnData.outMsg.ToString()); if (xtraTabControl1.SelectedTabPageIndex == 1) { getModel(lbGuid.Text.Trim()); @@ -562,10 +567,12 @@ gridView1.FocusedRowHandle = rowHandle; UtilityHelper.SetCheckIco(gridView1, "isCheck", "checkBy", "checkDate", picCheckBox, this, _inFieldValue.ToString()); } + else + MsgHelper.ShowError(_rtn.rtnData.outMsg.ToString()); } catch (Exception ex) { - MsgHelper.Warning("鎻愮ず锛�" + ex.Message); + MsgHelper.ShowError("鎻愮ず锛�" + ex.Message); } } private void repositoryItemButtonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e) @@ -600,13 +607,15 @@ var _rtn = UtilityHelper.ReturnToDynamic(strJson); if (_rtn.rtnCode > 0) { - if (_rtn.rtnCode > 0) getModel(lbGuid.Text); + MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg); + getModel(lbGuid.Text); } - MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg); + else + MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg); } catch (Exception ex) { - MsgHelper.Warning("鎻愮ず锛�" + ex.Message); + MsgHelper.ShowError("鎻愮ず锛�" + ex.Message); } } } -- Gitblit v1.9.3