lu
2025-04-28 80573826d4a94f9bca0bba021295405eff813ae0
DevApp/Gs.DevApp/DevFrm/QC/MesQcExceptional.cs
@@ -46,6 +46,7 @@
            getPageList(1);
            pageBar1.PagerEvent += PageBar1_PagerEvent;
        }
        private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
        {
            _filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns, gridView1);
@@ -174,7 +175,6 @@
            {
                ToolBox.MsgHelper.Warning("提示:" + ex.Message);
            }
        }
        private void getModel(string strGuid)
        {
@@ -239,27 +239,73 @@
        /// <param name="inFieldValue"></param>
        private void _toolCk(int _inFieldValue)
        {
            //toolBarMenu1.guidKey = "";
            //string rowGuid, rowName;
            //(rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
            //    lbGuid, txt_fBillNo, gridView1, "fBillNo");
            //toolBarMenu1.guidKey = rowGuid;
            //if (string.IsNullOrEmpty(rowGuid))
            //{
            //    MsgHelper.Warning("请先选择你要操作的行!");
            //    return;
            //}
            //if (!MsgHelper.AskQuestion("你选择了【" + rowName + "】,确定操作吗?"))
            //    return;
            //var frm = new MesQcExceptionalShow(rowGuid);
            //frm.UpdateParent += (s, e) =>
            //{
            //    int rowHandle = gridView1.LocateByValue(1, gridView1.Columns["guid"], rowGuid);
            //    gridView1.FocusedRowHandle = rowHandle;
            //    UtilityHelper.SetCheckIco(gridView1, "chkStatus", "checkBy", "checkDate", picCheckBox, this, _inFieldValue.ToString());
            //};
            //frm.ShowDialog();
            string strMsg = "";
            switch (_inFieldValue)
            {
                case 1:
                    strMsg = "审核";
                    break;
                case 0:
                    strMsg = "反审核";
                    break;
            };
            toolBarMenu1.guidKey = "";
            string rowGuid, rowName;
            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
                lbGuid, txt_fBillNo, gridView1, "fBillNo");
            toolBarMenu1.guidKey = rowGuid;
            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_fBillNo, gridView1, "fBillNo");
            if (string.IsNullOrEmpty(rowGuid))
            {
                MsgHelper.Warning("请先选择你要操作的行!");
                return;
            }
            if (!MsgHelper.AskQuestion("你选择了【" + rowName + "】,确定操作吗?"))
            if (!MsgHelper.AskQuestion("你选择了【" + rowName + "】,确定" + strMsg + "吗?"))
                return;
            var frm = new MesQcExceptionalShow(rowGuid);
            frm.UpdateParent += (s, e) =>
            var _obj = new
            {
                guid = rowGuid,
                inFieldValue = _inFieldValue,
            };
            try
            {
                var strJson = UtilityHelper.HttpPost("",
                    _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)
                {
                    if (xtraTabControl1.SelectedTabPageIndex == 1)
                    {
                        getModel(lbGuid.Text.Trim());
                    }
                int rowHandle = gridView1.LocateByValue(1, gridView1.Columns["guid"], rowGuid);
                gridView1.FocusedRowHandle = rowHandle;
                UtilityHelper.SetCheckIco(gridView1, "chkStatus", "checkBy", "checkDate", picCheckBox, this, _inFieldValue.ToString());
            };
            frm.ShowDialog();
                    UtilityHelper.SetCheckIco(gridView1, "chkStatus", "checkUser", "checkDate", picCheckBox, this, _inFieldValue.ToString());
        }
            }
            catch (Exception ex)
            {
                MsgHelper.Warning("提示:" + ex.Message);
            }
        }
    }
}