| | |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Data; |
| | | using System.Drawing; |
| | | using System.Threading.Tasks; |
| | | using System.Windows.Forms; |
| | | |
| | |
| | | this.toolBarMenu1.btnQueryClick += ToolBarMenu1_btnQueryClick; |
| | | toolBarMenu1.btnChkClick += ToolBarMenu1_btnChkClick; |
| | | toolBarMenu1.btnFChkClick += ToolBarMenu1_btnFChkClick; |
| | | toolBarMenu1.btnLogClick += ToolBarMenu1_btnLogClick; |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1); |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, picCheckBox, this, "shState", "", (value) => |
| | | { |
| | |
| | | /// <param name="e"></param> |
| | | private void ToolBarMenu1_btnLoadClick(object sender, EventArgs e) |
| | | { |
| | | if (xtraTabControl1.SelectedTabPageIndex == 1) |
| | | if (xtraTabControl1.SelectedTabPageIndex == 1) |
| | | 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> |
| | |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3); |
| | | if (xtraTabControl1.SelectedTabPageIndex == 1) |
| | | { |
| | | getModel(rowGuid); |
| | | getModel(lbGuid.Text.Trim()); |
| | | } |
| | | else |
| | | { |
| | |
| | | private void ToolBarMenu1_btnSaveClick(object sender, EventArgs e) |
| | | { |
| | | toolBarMenu1.isSetBtn = false; |
| | | // string _inCkId = txt_invFcode.GetId();//出 |
| | | // string _inRkId = txt_fromFcode.GetId();//入 |
| | | //if (string.IsNullOrEmpty(_inCkId)) |
| | | //{ |
| | | // Gs.DevApp.ToolBox.MsgHelper.Warning("请选择出货仓库!"); |
| | | // txt_invFcode.Focus(); |
| | | // return; |
| | | //} |
| | | //if (string.IsNullOrEmpty(_inRkId)) |
| | | //{ |
| | | // Gs.DevApp.ToolBox.MsgHelper.Warning("请选择收货仓库!"); |
| | | // txt_fromFcode.Focus(); |
| | | // return; |
| | | //} |
| | | string djlx=txt_djlx.SelectedText.ToString(); |
| | | string ywlx=txt_ywlx.SelectedText.ToString(); |
| | | string dbfx=txt_ftransferdirect.SelectedText.ToString(); |
| | | string sqOrg = txt_sqOrg.GetId(); |
| | | string dblx = txt_dblx.SelectedText.ToString(); |
| | | string dchzlx=txt_dchzlx.SelectedText.ToString(); |
| | | string drhzlx=txt_drhzlx.SelectedText.ToString(); |
| | | if (txt_djlx.SelectedIndex<=0) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择单据类型!"); |
| | | txt_djlx.Focus(); |
| | | return; |
| | | } |
| | | if (txt_ftransferdirect.SelectedIndex <= 0) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择调拨方向!"); |
| | | txt_ftransferdirect.Focus(); |
| | | return; |
| | | } |
| | | if (string.IsNullOrEmpty(sqOrg)) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择申请组织!"); |
| | | txt_sqOrg.Focus(); |
| | | return; |
| | | } |
| | | if (txt_dchzlx.SelectedIndex <= 0) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择调出货主类型!"); |
| | | txt_dchzlx.Focus(); |
| | | return; |
| | | } |
| | | if (txt_drhzlx.SelectedIndex <= 0) |
| | | { |
| | | Gs.DevApp.ToolBox.MsgHelper.Warning("请选择调入货主类型!"); |
| | | txt_drhzlx.Focus(); |
| | | return; |
| | | } |
| | | var _obj = new |
| | | { |
| | | guid = UtilityHelper.ToGuid(lbGuid.Text.Trim()), //主建 |
| | | //inCkId = _inCkId,//出仓 |
| | | //inRkId = _inRkId,//入库 |
| | | inDjlx = txt_fbilltypeid.Text.Trim(),//单据类型 |
| | | inDjlx = txt_djlx.Text.Trim(),//单据类型 |
| | | inDbfx = txt_ftransferdirect.Text.Trim(),//调拨方向 |
| | | inRemark = txt_remark.Text.Trim(),//备注 |
| | | list = new List<dynamic>(), |
| | |
| | | lbGuid.Text = _rtn.rtnData.outGuid; |
| | | txt_billno.Text = _rtn.rtnData.outNo; |
| | | toolBarMenu1.isSetBtn = true; |
| | | //List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>(); |
| | | //gvList.Add(gvMx1); |
| | | //UtilityHelper.ChangeEnableByControl(this.panel1.Controls, false, gvList); |
| | | //ucLookHuoZhu1.Enabled = false; |
| | | 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 = ""; |
| | | } |
| | | } |
| | |
| | | ToolBox.MsgHelper.Warning("提示:" + ex.Message); |
| | | } |
| | | } |
| | | |
| | | /// <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_billno, gridView1); |
| | | toolBarMenu1.guidKey = rowGuid; |
| | | } |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | |
| | | { |
| | | gcMain.DataSource = dt; |
| | | gcMain.ForceInitialize(); |
| | | gridView1.BestFitColumns(); |
| | | } |
| | | else |
| | | UtilityHelper.SetDefaultTable(gcMain, gridView1); |
| | |
| | | gcMx1.BindingContext = new BindingContext(); |
| | | gcMx1.DataSource = dt; |
| | | gcMx1.ForceInitialize(); |
| | | gvMx1.BestFitColumns(); |
| | | } |
| | | else |
| | | { |
| | |
| | | gvMx1.SetFocusedRowCellValue("itemName", SelectedDataRow["itemName"].ToString()); |
| | | gvMx1.SetFocusedRowCellValue("itemMpdel", SelectedDataRow["itemModel"].ToString()); |
| | | gvMx1.SetFocusedRowCellValue("itemUnit", SelectedDataRow["dwName"].ToString()); |
| | | gvMx1.CloseEditor(); |
| | | gvMx1.UpdateCurrentRow(); |
| | | } |
| | | |
| | | private void repositoryItemButtonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e) |