From d4e0269da1cc87d42918cdda6afaa005b6c47a0e Mon Sep 17 00:00:00 2001
From: lg <123456>
Date: 星期三, 19 十一月 2025 13:40:46 +0800
Subject: [PATCH] 按大类维护
---
DevApp/Gs.DevApp/DevFrm/QC/Frm_MesQaItemsDetect01.cs | 438 ++++++++++++++++++++++++++++++++++++++++++++---------
1 files changed, 359 insertions(+), 79 deletions(-)
diff --git a/DevApp/Gs.DevApp/DevFrm/QC/Frm_MesQaItemsDetect01.cs b/DevApp/Gs.DevApp/DevFrm/QC/Frm_MesQaItemsDetect01.cs
index fd90553..b3463fe 100644
--- a/DevApp/Gs.DevApp/DevFrm/QC/Frm_MesQaItemsDetect01.cs
+++ b/DevApp/Gs.DevApp/DevFrm/QC/Frm_MesQaItemsDetect01.cs
@@ -6,28 +6,48 @@
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
+using System.Configuration;
using System.Data;
+using System.Net;
using System.Threading.Tasks;
+using System.Timers;
using System.Windows.Forms;
namespace Gs.DevApp.DevFrm
{
public partial class Frm_MesQaItemsDetect01 : DevExpress.XtraEditors.XtraForm
{
+ string _strTag = "N:涓嶅悎鏍�";
string _webServiceName = "MesQaItemsDetect01Manager/";
List<FilterEntity> _filterList = new List<FilterEntity>();
+ /// <summary>
+ /// 瀹氭椂鍒锋柊
+ /// </summary>
+ System.Timers.Timer timer;
+
public Frm_MesQaItemsDetect01()
{
InitializeComponent();
+
+ #region 璁剧疆鏃堕棿
+ int int32 = 3000;
+ string _vanishingSeconds = ConfigurationManager.AppSettings["IqcGetWeight"];
+ if (!string.IsNullOrEmpty(_vanishingSeconds))
+ int32 = int.Parse(_vanishingSeconds);
+ timer = new System.Timers.Timer(int32);
+ #endregion
+
this.toolBarMenu1.btnEdtClick += ToolBarMenu1_btnEdtClick;
this.toolBarMenu1.btnSaveClick += ToolBarMenu1_btnSaveClick;
this.toolBarMenu1.btnLoadClick += ToolBarMenu1_btnLoadClick;
this.toolBarMenu1.btnEscClick += ToolBarMenu1_btnEscClick;
this.toolBarMenu1.btnQueryClick += ToolBarMenu1_btnQueryClick;
toolBarMenu1.btnLogClick += ToolBarMenu1_btnLogClick;
- toolBarMenu1.btnJianYanClick += ToolBarMenu1_btnJianYanClick;
+ toolBarMenu1.btnChkClick += ToolBarMenu1_btnChkClick;
+ toolBarMenu1.btnFChkClick += ToolBarMenu1_btnFChkClick;
+ toolBarMenu1.btnOutClick += ToolBarMenu1_btnOutClick;
this.toolBarMenu1.getXmlConfig();
- Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1);
+ Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1, tips);
Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx2);
Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx3);
Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, picCheckBox, this, "fsubmitTxt", "", (value) =>
@@ -48,7 +68,159 @@
xtraTabControl2.SelectedPageChanged += XtraTabControl2_SelectedPageChanged;
gvMx1.FocusedRowChanged += GvMx1_FocusedRowChanged;
btnIpt.Click += BtnIpt_Click;
+ btnYcReport.Click += BtnYcReport_Click;
+ #region 浜旀閲嶉噺
+ //鍏抽棴鏃堕噴鏀総imer
+ this.Disposed += (s, e) =>
+ {
+ // MessageBox.Show("ddddddd");
+ if (timer != null)
+ {
+ timer.Stop();
+ timer.Dispose();
+ }
+ };
+ timer.Elapsed += (s, e) =>
+ {
+ var _obj = new
+ {
+
+ };
+ try
+ {
+ var strReturn = UtilityHelper.HttpPost("", "WorkWeight/GetIqcWeight", JsonConvert.SerializeObject(_obj), false);
+ var dd = UtilityHelper.ReturnToDynamic(strReturn);
+ if (dd.rtnCode > 0)
+ {
+ BeginInvoke(new Action(() =>
+ {
+ txtWCurrent.Text = dd.rtnData;
+ }));
+ }
+ }
+ catch (Exception ex)
+ {
+ Gs.DevApp.ToolBox.LogHelper.Debug(this.ToString(), "WorkWeight/GetIqcWeight:" + ex.Message);
+ }
+ };
+ timer.AutoReset = true; // 璁剧疆涓簍rue琛ㄧず閲嶅鎵ц锛宖alse琛ㄧず鎵ц涓�娆″悗鍋滄
+ timer.Enabled = true; // 寮�濮嬭鏃�
+ //璇诲彇閲嶉噺
+ this.btnW.Click += (s, e) =>
+ {
+ string _strCurrent = this.txtWCurrent.Text.Trim();
+ bool _isNumeric = decimal.TryParse(_strCurrent, out _);
+ if (!_isNumeric)
+ {
+ ToolBox.MsgHelper.ShowError("璇锋鏌ョО閲嶈缃紒");
+ return;
+ }
+ decimal _decCurrent = decimal.Parse(_strCurrent);
+ if (_decCurrent * 1 <= 0)
+ {
+ ToolBox.MsgHelper.ShowError("璇锋鏌ョО閲嶈缃紒");
+ return;
+ }
+ if (txt_weight1.Text.Trim().Length <= 0)
+ {
+ _setWeigth(1, _strCurrent);
+ return;
+ }
+ if (txt_weight2.Text.Trim().Length <= 0)
+ {
+ _setWeigth(2, _strCurrent);
+ return;
+ }
+ if (txt_weight3.Text.Trim().Length <= 0)
+ {
+ _setWeigth(3, _strCurrent);
+ return;
+ }
+ if (txt_weight4.Text.Trim().Length <= 0)
+ {
+ _setWeigth(4, _strCurrent);
+ return;
+ }
+ if (txt_weight5.Text.Trim().Length <= 0)
+ {
+ _setWeigth(5, _strCurrent);
+ return;
+ }
+ ToolBox.MsgHelper.ShowError("閲嶉噺宸茶幏鍙栧畬姣曪紒");
+ return;
+ };
+ //娓呯┖
+ this.btnClean.Click += (s, e) =>
+ {
+ if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + txt_releaseNo.Text.Trim() + "銆戯紝纭畾娓呴櫎鎵�鏈夌О閲嶆暟鎹悧锛�"))
+ return;
+ _setWeigth(99, "");
+
+ };
+ #endregion
+
}
+ /// <summary>
+ /// 鎻愪氦绉伴噸
+ /// </summary>
+ /// <param name="_weightType"></param>
+ /// <param name="_weight"></param>
+ private void _setWeigth(int _weightType, string _weight)
+ {
+ var _obj = new
+ {
+ iqcGuid = this.txt_guid.Text.Trim(),
+ weightType = _weightType,
+ weight = _weight
+ };
+ try
+ {
+ var strReturn = UtilityHelper.HttpPost("", "WorkWeight/EditIqcWeight", JsonConvert.SerializeObject(_obj), false);
+ var dd = UtilityHelper.ReturnToDynamic(strReturn);
+ if (dd.rtnCode <= 0)
+ {
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + dd.rtnMsg);
+ }
+ else
+ {
+ if (_weightType == 1)
+ {
+ txt_weight1.Text = _weight;
+ return;
+ }
+ if (_weightType == 2)
+ {
+ txt_weight2.Text = _weight;
+ return;
+ }
+ if (_weightType == 3)
+ {
+ txt_weight3.Text = _weight;
+ return;
+ }
+ if (_weightType == 4)
+ {
+ txt_weight4.Text = _weight;
+ return;
+ }
+ if (_weightType == 5)
+ {
+ txt_weight5.Text = _weight;
+ return;
+ }
+ if (_weightType == 99)
+ {
+ this.txt_weight1.Text = this.txt_weight2.Text = this.txt_weight3.Text = this.txt_weight4.Text = this.txt_weight5.Text = "";
+ return;
+ }
+ }
+ }
+ catch (Exception ex)
+ {
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
+ }
+ }
+
/// <summary>
/// 鎵归噺褰曞叆
/// </summary>
@@ -68,6 +240,11 @@
Task.Delay(100);
getPageList(1);
}
+ /// <summary>
+ /// 5琛ㄧ劍鐐规椂锛岄噸鏂拌鍙�12琛�
+ /// </summary>
+ /// <param name="sender"></param>
+ /// <param name="e"></param>
private void GvMx1_FocusedRowChanged(object sender, DevExpress.XtraGrid.Views.Base.FocusedRowChangedEventArgs e)
{
if (e.FocusedRowHandle >= 0)
@@ -86,12 +263,12 @@
/// <param name="e"></param>
private void BtnLoad_Click(object sender, EventArgs e)
{
- if (!MsgHelper.AskQuestion("纭畾閲嶆柊鍔犺浇妫�楠岄」鐩悧锛岃鎿嶄綔灏嗕細娓呯┖涔嬪墠鐨勬楠岃褰曪紵"))
+ if (!MsgHelper.AskQuestion("璇ユ搷浣滃皢浼氭竻绌烘楠岃褰曪紙鍖呮嫭鏍峰搧妫�楠岃褰曪級锛岀‘瀹氶噸鏂板姞杞芥楠岄」鐩悧锛�"))
return;
string strGuid = lbGuid.Text.Trim();
if (string.IsNullOrEmpty(strGuid))
{
- ToolBox.MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ ToolBox.MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
var _obj = new
@@ -113,7 +290,7 @@
}
catch (Exception ex)
{
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
/// <summary>
@@ -126,7 +303,7 @@
int intHandle = this.gvMx1.FocusedRowHandle;
if (intHandle < 0)
{
- ToolBox.MsgHelper.Warning("鎻愮ず锛氳閫夋嫨妫�楠岄」鐩紒");
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛氳閫夋嫨妫�楠岄」鐩紒");
return;
}
if (e.KeyCode == Keys.Enter)
@@ -175,7 +352,7 @@
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
}
@@ -226,62 +403,15 @@
lbGuid, txt_releaseNo, gridView1);
toolBarMenu1.guidKey = rowGuid;
}
- /// <summary>
- ///鎻愪氦妫�楠屼簨浠�
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- /// <exception cref="NotImplementedException"></exception>
- private void ToolBarMenu1_btnJianYanClick(object sender, EventArgs e)
- {
- toolBarMenu1.guidKey = "";
- string rowGuid, rowName;
- (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
- lbGuid, txt_releaseNo, gridView1, "lotNo");
- toolBarMenu1.guidKey = rowGuid;
- if (string.IsNullOrEmpty(rowGuid))
- {
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
- return;
- }
- if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾鎻愪氦妫�楠屽悧锛�"))
- return;
- if (txt_fcheckResu.Text.Trim() == "涓嶅悎鏍�")
- {
- if (string.IsNullOrEmpty(txt_remarks.Text.Trim()))
- {
- MsgHelper.Warning("鍗曟嵁涓轰笉鍚堟牸鏃讹紝璇峰~鍐欏娉ㄨ鏄庯紒");
- return;
- }
- };
- var _obj = new
- {
- guid = rowGuid,
- };
- try
- {
- var strJson = UtilityHelper.HttpPost("",
- _webServiceName + "EditModelSubmit",
- JsonConvert.SerializeObject(_obj));
- var _rtn = UtilityHelper.ReturnToDynamic(strJson);
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnData.outMsg);
- if (_rtn.rtnCode > 0 && _rtn.rtnData.outSum * 1 > 0)
- {
- if (xtraTabControl1.SelectedTabPageIndex == 1)
- {
- getModel(lbGuid.Text.Trim(), "0");
- }
- int rowHandle = gridView1.LocateByValue(1, gridView1.Columns["guid"], rowGuid);
- gridView1.FocusedRowHandle = rowHandle;
- int _inFieldValue = 1;
- UtilityHelper.SetCheckIco(gridView1, "fsubmitTxt", "", "iqcDate", picCheckBox, this, _inFieldValue.ToString());
- }
- }
- catch (Exception ex)
- {
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
- }
+
+ private void ToolBarMenu1_btnChkClick(object sender, EventArgs e)
+ {
+ _toolCk("EditModelSubmit");
+ }
+ private void ToolBarMenu1_btnFChkClick(object sender, EventArgs e)
+ {
+ _toolCk("EditModelSubmitZhiLiang");
}
/// <summary>
@@ -293,7 +423,63 @@
{
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 1);
}
-
+ /// <summary>
+ /// 瀵煎嚭
+ /// </summary>
+ /// <param name="sender"></param>
+ /// <param name="e"></param>
+ /// <exception cref="NotImplementedException"></exception>
+ private void ToolBarMenu1_btnOutClick(object sender, EventArgs e)
+ {
+ string rowGuid = "", rowName = "";
+ (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
+ lbGuid, txt_releaseNo, gridView1, "releaseNo");
+ if (string.IsNullOrEmpty(rowGuid))
+ {
+ MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ return;
+ }
+ if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾瀵煎嚭鍚楋紵"))
+ return;
+ using (FolderBrowserDialog folderBrowserDialog = new FolderBrowserDialog())
+ {
+ folderBrowserDialog.Description = "閫夋嫨瀵煎嚭鏂囦欢鐨勪繚瀛樿矾寰�";
+ DialogResult dialogResult = folderBrowserDialog.ShowDialog();
+ if (dialogResult == DialogResult.OK)
+ {
+ string _folder = folderBrowserDialog.SelectedPath;
+ var _obj = new
+ {
+ guid = rowGuid,
+ };
+ try
+ {
+ string strJson = UtilityHelper.HttpPost("", "XlsInOut/XlsOutIqc", JsonConvert.SerializeObject(_obj));
+ ReturnModel<dynamic> _rtn = ToolBox.UtilityHelper.ReturnToDynamic(strJson);
+ if (_rtn.rtnCode > 0)
+ {
+ string _file = _rtn.rtnData.fileUrl.ToString();
+ string _folderName = _folder + "\\" + _file.Replace("down/", "");
+ string _url = ConfigurationManager.AppSettings["WebApiUrl"].ToString() + _file;
+ using (WebClient client = new WebClient())
+ {
+ client.DownloadFile(_url, _folderName);
+ }
+ var frm = new Gs.DevApp.DevFrm.QC.Xls(_folderName);
+ frm.ShowDialog();
+ }
+ else
+ {
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
+ }
+ }
+ catch (Exception ex)
+ {
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
+ }
+ }
+ }
+ }
/// <summary>
/// 鍒锋柊浜嬩欢
@@ -329,7 +515,7 @@
(rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_releaseNo, gridView1, "releaseNo");
if (string.IsNullOrEmpty(rowGuid))
{
- ToolBox.MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ ToolBox.MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3);
@@ -355,24 +541,32 @@
private void ToolBarMenu1_btnSaveClick(object sender, EventArgs e)
{
toolBarMenu1.isSetBtn = false;
- if (txt_fcheckResu.Text.Trim() == "N:涓嶅悎鏍�" && string.IsNullOrEmpty(txt_remarks.Text.Trim()))
+ if (txt_fcheckResu.Text.Trim() == _strTag && string.IsNullOrEmpty(txt_fngDesc.TextTxt.Trim()))
{
- Gs.DevApp.ToolBox.MsgHelper.Warning("褰撴楠岀粨鏋滀笉鍚堟牸鏃讹紝璇峰~鍐欏娉ㄨ鏄庯紒");
- txt_remarks.Focus();
+ Gs.DevApp.ToolBox.MsgHelper.ShowError("褰撴楠岀粨鏋滀笉鍚堟牸鏃讹紝璇峰~鍐欏紓甯告弿杩帮紒");
+ txt_fngDesc.Focus();
+ return;
+ }
+ if (txt_fcheckResu.Text.Trim() == _strTag && string.IsNullOrEmpty(txt_xblb.TextTxt.Trim()))
+ {
+ Gs.DevApp.ToolBox.MsgHelper.ShowError("褰撴楠岀粨鏋滀笉鍚堟牸鏃讹紝璇峰~鍐欓�夊埆绫诲埆锛�");
+ txt_xblb.Focus();
return;
}
var _obj = new
{
guid = UtilityHelper.ToGuid(lbGuid.Text.Trim()), //涓诲缓
- remarks = txt_remarks.Text.Trim(),
+ fngDesc = txt_fngDesc.TextTxt.Trim(),
+ iqcRemark= txt_iqcRemark.Text.Trim(),
+ iqcXblb = txt_xblb.TextTxt.Trim(),
};
try
{
string strJson = UtilityHelper.HttpPost("", _webServiceName + "EditModel", JsonConvert.SerializeObject(_obj));
ReturnModel<dynamic> _rtn = ToolBox.UtilityHelper.ReturnToDynamic(strJson);
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
if (_rtn.rtnCode > 0)
{
+ ToolBox.MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg);
lbGuid.Text = _rtn.rtnData;
toolBarMenu1.isSetBtn = true;
UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, false);
@@ -380,10 +574,12 @@
toolBarMenu1.currentAction = "";
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 6);
}
+ else
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
@@ -394,8 +590,11 @@
/// <param name="pageSize">姣忛〉鍑犳潯</param>
private void getPageList(int curPage)
{
- var _sbSqlWhere = UtilityHelper.GetSearchWhere(_filterList);
- // _sbSqlWhere += " and isnull(fsubmit,0)=0";
+ gcMain1.DataSource = null;
+ System.Text.StringBuilder _sbSqlWhere = new System.Text.StringBuilder();
+ _sbSqlWhere.Append(" and a.ReceiveOrgId in");
+ _sbSqlWhere.Append(ToolBox.UtilityHelper.GetOrgWhere());
+ _sbSqlWhere.Append(UtilityHelper.GetSearchWhere(_filterList));
PageQueryModel pgq = new PageQueryModel(curPage, this.pageBar1.RowsCount, "release_no", "asc", "", _sbSqlWhere.ToString());
string json = JsonConvert.SerializeObject(pgq);
try
@@ -427,10 +626,15 @@
}
catch (Exception ex)
{
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
+ /// <summary>
+ /// 璇诲彇瀹炰綋
+ /// </summary>
+ /// <param name="strGuid"></param>
+ /// <param name="guid5"></param>
private void getModel(string strGuid, string guid5)
{
bool isEdit = false;
@@ -438,7 +642,7 @@
if (toolBarMenu1.currentAction == "edit") isEdit = true;
if (string.IsNullOrEmpty(strGuid))
{
- ToolBox.MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ ToolBox.MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
var _obj = new
@@ -452,6 +656,7 @@
if (_rtn.rtnCode > 0)
{
dynamic dy = _rtn.rtnData;
+ btnYcReport.ToolTip = dy.toGuid.ToString();
lbGuid.Text = strGuid;
List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>();
gvList.Add(gvMx1);
@@ -471,6 +676,7 @@
gcMx1.DataSource = dt;
gcMx1.ForceInitialize();
gvMx1.BestFitColumns();
+ Gs.DevApp.ToolBox.UtilityHelper.SetGridLayout(gvMx1);
ucUpFileList1.pGuid = lbGuid.Text.Trim();
if (guid5.Length > 10)
{
@@ -488,11 +694,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);
}
}
@@ -548,16 +754,90 @@
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
-
+ /// <summary>
+ /// 绂佺敤妫�楠屾+閲嶆柊鍔犺浇鎸夐挳
+ /// </summary>
+ /// <param name="bl"></param>
private void setEable(bool bl)
{
-
txtJianYan.ReadOnly = !bl;
btnLoad.Enabled = bl;
btnIpt.Text = (bl == true ? "褰曞叆鏍锋湰" : "鏌ョ湅鏍锋湰");
+ btnW.Enabled = btnClean.Enabled = bl;
}
+
+ #region 鎵撳紑鐖朵翰绐楀彛濮旀墭锛屾煡鐪嬪紓甯告姤鍛�
+ public event EventHandler<UpdateParentEventArgs> ToUpdateParent;
+ private void BtnYcReport_Click(object sender, EventArgs e)
+ {
+ string _toGuid = (btnYcReport.ToolTip == null ? "" : btnYcReport.ToolTip.ToString());
+ if (string.IsNullOrEmpty(_toGuid))
+ {
+ Gs.DevApp.ToolBox.MsgHelper.ShowInformation("璇ュ崟鏃犲紓甯告姤鍛婏紝鏌ョ湅澶辫触锛�");
+ return;
+ }
+ if (ToUpdateParent != null)
+ {
+ List<string> lst = new List<string>();
+ lst.Add("Gs.DevApp.DevFrm.QC.MesQcExceptional");//绫诲悕
+ lst.Add(_toGuid);//寮傚父鎶ュ憡涓婚敭
+ lst.Add("tab1");//鍏跺畠
+ ToUpdateParent?.Invoke(this,
+ new UpdateParentEventArgs { StringList = lst });
+ }
+ }
+ #endregion
+
+
+ /// <summary>
+ /// 妫�楠屽拰鍙嶆楠�
+ /// </summary>
+ /// <param name="inFieldValue"></param>
+ private void _toolCk(string _meth)
+ {
+ string rowGuid, rowName;
+ (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_releaseNo, gridView1, "releaseNo");
+ if (string.IsNullOrEmpty(rowGuid))
+ {
+ MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ return;
+ }
+ if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾鎿嶄綔鍚楋紵"))
+ return;
+ var _obj = new
+ {
+ guid = rowGuid,
+ };
+ try
+ {
+ var strJson = UtilityHelper.HttpPost("",
+ _webServiceName + _meth,
+ JsonConvert.SerializeObject(_obj));
+ var _rtn = UtilityHelper.ReturnToDynamic(strJson);
+
+ if (_rtn.rtnCode > 0 && _rtn.rtnData.outSum * 1 > 0)
+ {
+ MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnData.outMsg);
+ if (xtraTabControl1.SelectedTabPageIndex == 1)
+ {
+ getModel(lbGuid.Text.Trim(), "0");
+ }
+ int rowHandle = gridView1.LocateByValue(1, gridView1.Columns["guid"], rowGuid);
+ gridView1.FocusedRowHandle = rowHandle;
+ int _inFieldValue = (_meth == "EditModelSubmit" ? 1 : -1);
+ UtilityHelper.SetCheckIco(gridView1, "fsubmitTxt", "", "iqcDate", picCheckBox, this, _inFieldValue.ToString());
+ }
+ else
+ MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnData.outMsg);
+ }
+ catch (Exception ex)
+ {
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
+ }
+ }
+
}
}
\ No newline at end of file
--
Gitblit v1.9.3