| | |
| | | using DevExpress.XtraEditors; |
| | | using DevExpress.XtraGrid.Views.Base.ViewInfo; |
| | | using Gs.DevApp.Entity; |
| | | using Gs.DevApp.ToolBox; |
| | | using Gs.DevApp.UserControl; |
| | |
| | | toolBarMenu1.btnChkClick += ToolBarMenu1_btnChkClick; |
| | | toolBarMenu1.btnFChkClick += ToolBarMenu1_btnFChkClick; |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1); |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx2); |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, picCheckBox, this, "qt015", "", (value) => |
| | | { |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 0); |
| | |
| | | }); |
| | | getPageList(1); |
| | | pageBar1.PagerEvent += PageBar1_PagerEvent; |
| | | txt_qt011.getSuppler(""); |
| | | txt_qt008.getSuppler(""); |
| | | txt_qt018.getSuppler(""); |
| | | //设置仓库选择 |
| | | this.txt_qt011.EditChanged += (s, e) => |
| | | this.txt_qt008.EditChanged += (s, e) => |
| | | { |
| | | |
| | | }; |
| | |
| | | |
| | | private void GridView1_ColumnFilterChanged(object sender, EventArgs e) |
| | | { |
| | | _filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns); |
| | | Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns, gridView1); |
| | | Task.Delay(100); |
| | | getPageList(1); |
| | | } |
| | |
| | | if (_rtn.rtnCode > 0) |
| | | { |
| | | if (xtraTabControl1.SelectedTabPageIndex == 0) |
| | | getPageList(this.pageBar1.CurrentPage); |
| | | { } |
| | | else |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 2); |
| | | getPageList(this.pageBar1.CurrentPage); |
| | | } |
| | | |
| | | MsgHelper.Warning("提示:" + _rtn.rtnMsg); |
| | |
| | | getModel(lbGuid.Text.Trim()); |
| | | else |
| | | { |
| | | _filterList.Clear(); |
| | | if (gridView1.ActiveFilter.Count > 0) |
| | | { |
| | | gridView1.ColumnFilterChanged -= GridView1_ColumnFilterChanged; |
| | | gridView1.ActiveFilter.Clear(); |
| | | gridView1.ColumnFilterChanged += GridView1_ColumnFilterChanged; |
| | | } |
| | | getPageList(1); |
| | | //_filterList.Clear(); |
| | | //if (gridView1.ActiveFilter.Count > 0) |
| | | //{ |
| | | // gridView1.ColumnFilterChanged -= GridView1_ColumnFilterChanged; |
| | | // gridView1.ActiveFilter.Clear(); |
| | | // gridView1.ColumnFilterChanged += GridView1_ColumnFilterChanged; |
| | | //} |
| | | //getPageList(1); |
| | | getPageList(this.pageBar1.CurrentPage); |
| | | } |
| | | } |
| | | /// <summary> |
| | |
| | | return; |
| | | } |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3); |
| | | UtilityHelper.ChangeEnableByControl(panel1.Controls, true); |
| | | if (xtraTabControl1.SelectedTabPageIndex == 1) |
| | | { |
| | | getModel(rowGuid); |
| | | } |
| | | else |
| | | { |
| | | List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>(); |
| | | gvList.Add(gvMx1); |
| | | gvList.Add(gvMx2); |
| | | UtilityHelper.ChangeEnableByControl(panel1.Controls, true, gvList); |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// 新增事件 |
| | |
| | | { |
| | | toolBarMenu1.isSetBtn = false; |
| | | string inGys = txt_qt018.GetId(); |
| | | string inCjId = txt_qt011.GetId(); |
| | | string inCjId = txt_qt008.GetId(); |
| | | if (string.IsNullOrEmpty(inGys)) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择供应商!"); |
| | |
| | | if (string.IsNullOrEmpty(inCjId)) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择仓库!"); |
| | | txt_qt011.Focus(); |
| | | txt_qt008.Focus(); |
| | | return; |
| | | } |
| | | var _obj = new |
| | | { |
| | | guid = UtilityHelper.ToGuid(lbGuid.Text.Trim()), //主建 |
| | | inRklb = txt_qt003.Text.Trim(),//备注 |
| | | inYwlx = txt_qt004.Text.Trim(),//业务类型 |
| | | inRkfs = txt_qt019.Text.Trim(),//入库方式 |
| | | inRklx = txt_qt020.Text.Trim(),//入库类型 |
| | | inGys = inGys,//供应商 |
| | | inCjId = inCjId,//入库仓库 |
| | | inDepart = txt_qt009.GetId(),//申请部门 |
| | | inXsdh = txt_qt021.Text.Trim(),//销售单号 |
| | | kcZz = txt_qt022.GetId(),//库存组织 |
| | | kcBm = txt_qt009.GetId(),//库存部门 |
| | | kcGys = txt_qt018.GetId(),//库存供应商 |
| | | kcCk = txt_qt008.GetId(),//库存供应商 |
| | | inRkyy = txt_qt010.Text.Trim(),//入库原因 |
| | | djLx = txt_qt003.Text.Trim(),//单据类型 |
| | | kcfx = txt_qt019.Text.Trim(),//库存方向 |
| | | hzlx = txt_qt023.Text.Trim(),//货主类型 |
| | | hzzz = txt_qt024.GetId(),//货主组织 |
| | | hzkh = txt_qt025.GetId(),//货主客户 |
| | | hzbm = txt_qt026.GetId(),//货主部门 |
| | | list = new List<dynamic>(), |
| | | }; |
| | | gvMx1.CloseEditor(); |
| | |
| | | { |
| | | gcMain.DataSource = dt; |
| | | gcMain.ForceInitialize(); |
| | | gridView1.BestFitColumns(); |
| | | } |
| | | else |
| | | UtilityHelper.SetDefaultTable(gcMain, gridView1); |
| | |
| | | gcMx1.BindingContext = new BindingContext(); |
| | | gcMx1.DataSource = dt; |
| | | gcMx1.ForceInitialize(); |
| | | gvMx1.BestFitColumns(); |
| | | } |
| | | else |
| | | { |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx1, gvMx1); |
| | | } |
| | | |
| | | JArray array2 = new JArray(); |
| | | foreach (var a in _job["rtnData"]["list2"]) |
| | | { |
| | | array2.Add(a); |
| | | } |
| | | DataTable dt2 = JsonConvert.DeserializeObject<DataTable>(array2.ToString()); |
| | | if (dt2.Rows.Count > 0) |
| | | { |
| | | gcMx2.BindingContext = new BindingContext(); |
| | | gcMx2.DataSource = dt2; |
| | | gcMx2.ForceInitialize(); |
| | | gvMx2.BestFitColumns(); |
| | | } |
| | | else |
| | | { |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx2, gvMx2); |
| | | } |
| | | } |
| | | else |
| | |
| | | DataRow row = gvMx1.GetDataRow(e.FocusedRowHandle); |
| | | lbMxGuid.Text = row["guid"].ToString(); |
| | | ucBtnPrint1.guidKey = row["guid"].ToString(); |
| | | txtWlid.Text = row["itemId"].ToString(); |
| | | txtWlid.Text = row["qd002"].ToString(); |
| | | txtWlgg.Text = row["qd004"].ToString(); |
| | | txtWlmc.Text = row["qd003"].ToString(); |
| | | txtQuantity.Text = row["qd007"].ToString();//申请总量 |
| | | txtYdy.Text = row["YDYNUM"].ToString();//已打印总量 |
| | | kyPrtQty.Text = row["KDYNUM"].ToString();//可打印总量 |
| | | //txtQuantity.Text = row["qd007"].ToString();//申请总量 |
| | | //txtYdy.Text = row["YDYNUM"].ToString();//已打印总量 |
| | | //kyPrtQty.Text = row["KDYNUM"].ToString();//可打印总量 |
| | | } |
| | | } |
| | | /// <summary> |