| | |
| | | e.Info.DisplayText = (e.RowHandle + 1).ToString(); |
| | | } |
| | | }; |
| | | this.gvMx1.IndicatorWidth = 50; |
| | | gvMx1.CustomDrawRowIndicator += (s, e) => |
| | | { |
| | | if (e.Info.IsRowIndicator && e.RowHandle >= 0) |
| | | { |
| | | e.Info.DisplayText = (e.RowHandle + 1).ToString(); |
| | | } |
| | | }; |
| | | this.gvMx2.IndicatorWidth = 50; |
| | | gvMx2.CustomDrawRowIndicator += (s, e) => |
| | | { |
| | | if (e.Info.IsRowIndicator && e.RowHandle >= 0) |
| | | { |
| | | e.Info.DisplayText = (e.RowHandle + 1).ToString(); |
| | | } |
| | | }; |
| | | gridView1.CustomDrawEmptyForeground += (s, e) => |
| | | { |
| | | string str = "暂未查找到匹配的数据!"; |
| | |
| | | string _strCmd = txtJianYan.Text.Trim().ToUpper(); |
| | | string _strOK = "OK"; |
| | | string _strNG = "NG"; |
| | | if (!(_strCmd.StartsWith(_strOK) || _strCmd.StartsWith(_strNG))) |
| | | int n = 0; |
| | | if ((_strCmd.StartsWith(_strOK) || _strCmd.StartsWith(_strNG))) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | if (!_strCmd.Contains("-")) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | string[] _ary = _strCmd.Split('-'); |
| | | if (_ary.Length != 2) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误::请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | string _str1 = _ary[0]; |
| | | if (!(_str1 == _strOK || _str1 == _strNG)) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | string _str2 = _ary[1]; |
| | | if (int.TryParse(_str2, out n)) |
| | | { |
| | | } |
| | | else |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | } |
| | | if (!_strCmd.Contains("-")) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:缺少 中画线!"); |
| | | return; |
| | | } |
| | | string[] _ary = _strCmd.Split('-'); |
| | | if (_ary.Length != 2) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误::请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | string _str1 = _ary[0]; |
| | | if (!(_str1 == _strOK || _str1 == _strNG)) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | string _str2 = _ary[1]; |
| | | int n; |
| | | if (int.TryParse(_str2, out n)) |
| | | if (int.TryParse(_strCmd, out n)) |
| | | { |
| | | } |
| | | else |
| | |
| | | Gs.DevApp.ToolBox.MsgHelper.ShowError("命令输入错误:请正确使用OK 或 NG 命令!"); |
| | | return; |
| | | } |
| | | for (int i = 0; i < gvMx2.DataRowCount; i++) |
| | | var _obj = new |
| | | { |
| | | gvMx2.SetRowCellValue(i, "fcheckResu", _str1); |
| | | gvMx2.SetRowCellValue(i, "fstand", _str1); |
| | | } |
| | | List<MesQaItemsDetectDetail12> lst = new List<MesQaItemsDetectDetail12>(); |
| | | for (var i = 0; i < gvMx2.DataRowCount; i++) |
| | | { |
| | | var row = gvMx2.GetDataRow(i); |
| | | if (row != null) |
| | | lst.Add(new MesQaItemsDetectDetail12() |
| | | { |
| | | ParentGuid = UtilityHelper.ToGuid(guid5), |
| | | Guid = UtilityHelper.ToGuid(row["guid"].ToString()), |
| | | FcheckResu = row["fcheckResu"].ToString(), |
| | | GrandpaGuid = UtilityHelper.ToGuid(lbGuid.Text.Trim()), |
| | | }); |
| | | } |
| | | var _obj = lst; |
| | | inOrderGuid1 = UtilityHelper.ToGuid(lbGuid.Text.Trim()), ////这是检验单guid |
| | | inOrderGuid5 = guid5,//这是抽样的guid |
| | | inP1 = _strCmd,//这是9,有可能是19,或者0k-19,或者ng-19 |
| | | }; |
| | | try |
| | | { |
| | | var strJson = UtilityHelper.HttpPost("", |
| | |
| | | MsgHelper.Warning("提示:" + _rtn.rtnMsg); |
| | | if (_rtn.rtnCode > 0) |
| | | { |
| | | txtJianYan.Text = ""; |
| | | getModel(lbGuid.Text.Trim(), false, 999); |
| | | } |
| | | } |
| | | catch (Exception ex) |
| | |
| | | { |
| | | ToolBox.MsgHelper.Warning("提示:" + ex.Message); |
| | | } |
| | | |
| | | _loading.Stop(); |
| | | } |
| | | |