cdk
4 天以前 b5dcb53aa7b452d44b4fc19a0c830f86ab9cb5aa
DevApp/Gs.DevApp/DevFrm/Rk/Frm_MesInvItemArn.cs
@@ -86,6 +86,7 @@
                        lst = ee.StringList;
                        string strReturn = "";
                        ReturnModel<DataTable> dt;
                        DataTable _oldTable = (DataTable)gcMx1.DataSource;
                        #region 这是Srm来的单子
                        if (lst == null)
                        {
@@ -106,6 +107,8 @@
                            gvMx1quantity.OptionsColumn.ReadOnly = true;
                            txt_paperBillNo.ReadOnly = true;
                            txt_isSrm.Checked = true;
                            DataTable _newTable = dt.rtnData;
                            _oldTable = _newTable;
                        }
                        #endregion
                        #region 这是普通的单
@@ -119,21 +122,21 @@
                            gvMx1quantity.OptionsColumn.ReadOnly = false;
                            txt_paperBillNo.ReadOnly = false;
                            txt_isSrm.Checked = false;
                            DataTable _newTable = dt.rtnData;
                            DataRow[] sourceRows = _newTable.Select();
                            for (int i = 0; i < sourceRows.Length; i++)
                            {
                                _oldTable.ImportRow(sourceRows[i]);
                            }
                        }
                        #endregion
                        DataTable _newTable = dt.rtnData;
                        DataTable _oldTable = (DataTable)gcMx1.DataSource;
                        DataRow[] sourceRows = _newTable.Select();
                        for (int i = 0; i < sourceRows.Length; i++)
                        {
                            _oldTable.ImportRow(sourceRows[i]);
                        }
                        gcMx1.BindingContext = new BindingContext();
                        gcMx1.DataSource = _oldTable;
                        gcMx1.ForceInitialize();
                        gvMx1.PostEditor();
                        gvMx1.UpdateCurrentRow();
                        gvMx1.BestFitColumns();
                        Gs.DevApp.ToolBox.UtilityHelper.SetGridLayout(gvMx1);
                    }
                    catch (Exception ex)
                    {
@@ -253,12 +256,14 @@
                    else
                        Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 2);
                    getPageList(this.pageBar1.CurrentPage);
                    MsgHelper.ShowInformation("提示:" + _rtn.rtnMsg);
                }
                MsgHelper.Warning("提示:" + _rtn.rtnMsg);
                else
                MsgHelper.ShowError("提示:" + _rtn.rtnMsg);
            }
            catch (Exception ex)
            {
                MsgHelper.Warning("提示:" + ex.Message);
                MsgHelper.ShowError("提示:" + ex.Message);
            }
        }
@@ -297,24 +302,24 @@
                lbGuid, txt_billNo, gridView1);
            if (string.IsNullOrEmpty(rowGuid))
            {
                MsgHelper.Warning("请先选择你要操作的行!");
                MsgHelper.ShowError("请先选择你要操作的行!");
                return;
            }
            Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3);
            if (xtraTabControl1.SelectedTabPageIndex == 1)
            {
                getModel(rowGuid);
                ////如果是srm,禁用
                setSrm();
            }
            else
            {
                List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>();
                gvList.Add(gvMx1);
                UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, true, gvList);
                ////如果是srm,禁用
                setSrm();
            }
            //2025/07/12加上修改状态下不能修改供应商和组织srm,禁用
            setSrm();
            txt_receiveOrgId.IsReadly = true;
            txt_suppId.IsReadly = true;
        }
        /// <summary>
@@ -394,7 +399,7 @@
                        AboutGuid = Gs.DevApp.ToolBox.UtilityHelper.ToGuid(row["aboutGuid"].ToString()),
                        ItemId = int.Parse(row["itemId"].ToString()),
                        Quantity = decimal.Parse(row["quantity"].ToString()),
                        UrgentFlag = Gs.DevApp.ToolBox.UtilityHelper.ToBit(row["urgentFlag"].ToString()),
                        UrgentFlag = (row["urgentFlagTxt"].ToString().Replace(":","").Replace("普通", "").Replace("急料", "").Replace("一般", "")),
                        Remark = row["memo"].ToString(),
                    });
                }
@@ -519,7 +524,6 @@
                    {
                        UtilityHelper.SetDefaultTable(gcMx1, gvMx1);
                    }
                }
                else
                {
@@ -646,9 +650,9 @@
                    _webServiceName + _meth,
                    JsonConvert.SerializeObject(_obj));
                var _rtn = UtilityHelper.ReturnToDynamic(strJson);
                MsgHelper.Warning("提示:" + _rtn.rtnData.outMsg);
                if (_rtn.rtnCode > 0 && _rtn.rtnData.outSum * 1 > 0)
                {
                    MsgHelper.ShowInformation("提示:" + _rtn.rtnData.outMsg);
                    if (xtraTabControl1.SelectedTabPageIndex == 1)
                    {
                        getModel(lbGuid.Text.Trim());
@@ -658,10 +662,12 @@
                    int _inFieldValue = (_meth == "EditModelSubmit" ? 1 : -1);
                    UtilityHelper.SetCheckIco(gridView1, "fstatus", "checkUser", "checkDate", picCheckBox, this, _inFieldValue.ToString());
                }
                else
                    MsgHelper.ShowError("提示:" + _rtn.rtnData.outMsg);
            }
            catch (Exception ex)
            {
                MsgHelper.Warning("提示:" + ex.Message);
                MsgHelper.ShowError("提示:" + ex.Message);
            }
        }
@@ -689,8 +695,8 @@
                gvMx1quantity.OptionsColumn.ReadOnly = true;
                txt_paperBillNo.ReadOnly = true;
                txt_isSrm.Checked = true;
                txt_receiveOrgId.Enabled = false;
                txt_suppId.Enabled = false;
                txt_receiveOrgId.IsReadly = true;
                txt_suppId.IsReadly = true;
                btnSelect.Enabled = false;
            }
            else
@@ -698,8 +704,8 @@
                gvMx1quantity.OptionsColumn.ReadOnly = false;
                txt_paperBillNo.ReadOnly = false;
                txt_isSrm.Checked = false;
                txt_receiveOrgId.Enabled = true;
                txt_suppId.Enabled = true;
                txt_receiveOrgId.IsReadly = false;
                txt_suppId.IsReadly = false;
                btnSelect.Enabled = true;
            }
        }