lu
2025-02-18 92c92d9bfb4431a8e2f4b8ac494547d50ea3a7f6
DevApp/Gs.DevApp/DevFrm/Ck/UcBlcl.cs
@@ -14,10 +14,10 @@
{
    public partial class UcBlcl : DevExpress.XtraEditors.XtraUserControl
    {
        string _ucCk = "";//仓库
        string _ucGd = "";//工单
        string _webServiceName = "MesItemBlManager/";
        List<FilterEntity> _filterList = new List<FilterEntity>();
        public string strType = "";
        public UcBlcl(string _strType)
        {
@@ -40,9 +40,10 @@
            this.toolBarMenu1.btnQueryClick += ToolBarMenu1_btnQueryClick;
            toolBarMenu1.btnChkClick += ToolBarMenu1_btnChkClick;
            toolBarMenu1.btnFChkClick += ToolBarMenu1_btnFChkClick;
            Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1);
            toolBarMenu1.btnLogClick += ToolBarMenu1_btnLogClick;
            Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(this.GetType().FullName, gvMx1);
            Form parentForm = this.FindForm();
            Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, picCheckBox, parentForm, "bl018", "", (value) =>
             Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(this.GetType().FullName,gridView1,picCheckBox, parentForm, "bl018", "", (value) =>
            {
                Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 0);
            });
@@ -60,11 +61,10 @@
            {
                string orgdId = txt_orgId.GetId();
                if (string.IsNullOrEmpty(orgdId)) return;
                txt_bl010.getSuppler(orgdId);
                txt_aboutGuid.getSuppler(orgdId);
                txt_bl010.getSuppler(orgdId,_ucCk);
                txt_aboutGuid.getSuppler(orgdId, _ucGd);
            };
            //设置仓库选择
           // txt_bl010.getSuppler("");
            this.txt_bl010.EditChanged += (s, e) =>
            {
@@ -108,6 +108,19 @@
            Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns, gridView1);
            Task.Delay(100);
            getPageList(1);
        }
        /// <summary>
        /// 日志
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void ToolBarMenu1_btnLogClick(object sender, EventArgs e)
        {
            toolBarMenu1.guidKey = "";
            string rowGuid, rowName;
            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
                lbGuid, txt_blNo, gridView1);
            toolBarMenu1.guidKey = rowGuid;
        }
        /// <summary>
        /// 分页事件
@@ -348,6 +361,7 @@
                    List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>();
                    gvList.Add(gvMx1);
                    UtilityHelper.ChangeEnableByControl(this.panel1.Controls, false, gvList);
                    toolBarMenu1.currentAction = "";
                }
            }
            catch (Exception ex)
@@ -364,6 +378,7 @@
        private void getPageList(int curPage)
        {
            var _sbSqlWhere = UtilityHelper.GetSearchWhere(_filterList);
            _sbSqlWhere += " and a.bl008='"+ strType + "'";
            PageQueryModel pgq = new PageQueryModel(curPage, this.pageBar1.RowsCount, "create_date", "asc", "", _sbSqlWhere.ToString());
            string json = JsonConvert.SerializeObject(pgq);
            try
@@ -420,10 +435,14 @@
                if (_rtn.rtnCode > 0)
                {
                    dynamic dy = _rtn.rtnData;
                    _ucCk = dy.bl010;
                    _ucGd = dy.aboutGuid;
                    lbGuid.Text = strGuid;
                    List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>();
                    gvList.Add(gvMx1);
                    UtilityHelper.SetValueByObj(this.panel1.Controls, dy, isEdit, gvList);
                    _ucCk = "";
                    _ucGd = "";
                    JObject _job = JObject.Parse(strJson);
                    JArray array = new JArray();
                    foreach (var a in _job["rtnData"]["list"])
@@ -529,7 +548,6 @@
                MsgHelper.Warning("提示:" + ex.Message);
            }
        }
        private void repositoryItemSearchLookUpEdit1_EditValueChanged(object sender, EventArgs e)
        {
            SearchLookUpEdit LookupEdit = sender as SearchLookUpEdit;
@@ -541,7 +559,6 @@
            gvMx1.SetFocusedRowCellValue("dwName", SelectedDataRow["dwName"]);
            gvMx1.SetFocusedRowCellValue("dabGuid", SelectedDataRow["dabGuid"]);
        }
        private void repositoryItemButtonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e)
        {
            var rowhandle = gvMx1.FocusedRowHandle;