lu
2024-12-06 e6a9b817b0fd82dd89bf58107388edd1ab89bf11
DevApp/Gs.DevApp/DevFrm/QC/Frm_MesQaMj.cs
@@ -29,45 +29,26 @@
            toolBarMenu1.btnChkClick += ToolBarMenu1_btnChkClick;
            toolBarMenu1.btnFChkClick += ToolBarMenu1_btnFChkClick;
            gcMain.MouseDoubleClick += GcMain_MouseDoubleClick;
            gridView1.FocusedRowChanged += (s, e) =>
            {
                UtilityHelper.SetCheckIco(s, picCheckBox, this, "status", "");
            };
            getPageList(1);
            Gs.DevApp.ToolBox.UtilityHelper.SetGridSear(gridView1);
            Gs.DevApp.ToolBox.UtilityHelper.SetGridSear(gridView1, picCheckBox, this, "status", "");
            pageBar1.PagerEvent += PageBar1_PagerEvent;
            gridView1.CustomDrawRowIndicator += (s, e) =>
            {
                if (e.Info.IsRowIndicator && e.RowHandle >= 0)
                {
                    e.Info.DisplayText = (e.RowHandle + 1).ToString();
                }
            };
            gridView1.CustomDrawEmptyForeground += (s, e) =>
            {
                string str = "暂未查找到匹配的数据!";
                Font f = new Font("微软雅黑", 16);
                Rectangle r = new Rectangle(gridView1.GridControl.Width / 2 - 100, e.Bounds.Top + 45, e.Bounds.Right - 5, e.Bounds.Height - 5);
                e.Graphics.DrawString(str, f, Brushes.Gray, r);
            };
            _setIno();
        }
        private   void GridView1_ColumnFilterChanged(object sender, EventArgs e)
        {
            _filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns);
           Task.Delay(100);
            getPageList(1);
        }
        private void _setIno()
        {
            txt_itemId.EditChanged += (s, e) =>
            {
                txt_itemNo.Text = this.txt_itemId.GetCode();
                //var ItemId = this.txt_itemId.GetId();
                //var ItemName = this.txt_itemId.GetName();
                //GetCount(ItemId, ItemName);
            };
            txt_suppId.getSuppler("");
            txt_suppId.EditChanged += (s, e) =>
            {
                txtGysNo.Text = this.txt_suppId.GetCode();
            };
        }
        private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
        {
            _filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns);
            Task.Delay(100);
            getPageList(1);
        }
        /// <summary>
        /// 双击事件
        /// </summary>
@@ -207,13 +188,6 @@
            UtilityHelper.JumpToTab(xtraTabControl1, 1);
            lbGuid.Text = "";
            UtilityHelper.CleanValueByControl(this.panel1.Controls, true);
            txt_createBy.Enabled = false;
            txt_createDate.Enabled = false;
            txt_lastupdateBy.Enabled = false;
            txt_lastupdateDate.Enabled = false;
            txt_checkUser.Enabled = false;
            txt_checkDate.Enabled = false;
            txt_status.Enabled = false;
        }
        /// <summary>
        /// 保存事件
@@ -267,9 +241,9 @@
        /// </summary>
        /// <param name="curPage">第几页</param>
        /// <param name="pageSize">每页几条</param>
        private   void getPageList(int curPage)
        private void getPageList(int curPage)
        {
            var _sbSqlWhere = UtilityHelper.GetSearchWhere(_filterList);
            PageQueryModel pgq = new PageQueryModel(curPage, this.pageBar1.RowsCount, "a.create_date", "asc", "", _sbSqlWhere.ToString());
            string json = JsonConvert.SerializeObject(pgq);
@@ -303,7 +277,7 @@
            {
                ToolBox.MsgHelper.Warning("提示:" + ex.Message);
            }
        }
        /// <summary>
        ///