| | |
| | | this.toolBarMenu1.btnLoadClick += ToolBarMenu1_btnLoadClick; |
| | | this.toolBarMenu1.btnDelClick += ToolBarMenu1_btnDelClick1; |
| | | this.toolBarMenu1.btnEscClick += ToolBarMenu1_btnEscClick; |
| | | this.toolBarMenu1.getXmlConfig(); |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, null, null, "", "", (value) => |
| | | { |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 0); |
| | |
| | | }, (value) => |
| | | { |
| | | getPageList(this.pageBar1.CurrentPage); |
| | | }); |
| | | }, lbGuid); |
| | | getPageList(1); |
| | | pageBar1.PagerEvent += PageBar1_PagerEvent; |
| | | } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 分页事件 |
| | | /// </summary> |
| | |
| | | /// <param name="e"></param> |
| | | private void ToolBarMenu1_btnEdtClick(object sender, EventArgs e) |
| | | { |
| | | |
| | | string rowGuid = "", rowName = ""; |
| | | (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_pageView, gridView1); |
| | | if (string.IsNullOrEmpty(rowGuid)) |
| | |
| | | return; |
| | | } |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3); |
| | | UtilityHelper.ChangeEnableByControl(panel1.Controls, true); |
| | | if (xtraTabControl1.SelectedTabPageIndex == 1) |
| | | { |
| | | getModel(rowGuid); |
| | | } |
| | | else |
| | | { |
| | | UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, true); |
| | | } |
| | | |
| | | |
| | | } |
| | | /// <summary> |
| | | /// 新增事件 |
| | |
| | | { |
| | | lbGuid.Text = ""; |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 4); |
| | | UtilityHelper.CleanValueByControl(panel1.Controls, true); |
| | | UtilityHelper.CleanValueByControl(this.layoutMx1.Controls, true); |
| | | } |
| | | /// <summary> |
| | | /// 保存事件 |
| | |
| | | /// <param name="e"></param> |
| | | private void ToolBarMenu1_btnSaveClick(object sender, EventArgs e) |
| | | { |
| | | |
| | | |
| | | toolBarMenu1.isSetBtn = false; |
| | | if (string.IsNullOrEmpty(txt_pageView.Text.Trim())) |
| | | { |
| | |
| | | guid = UtilityHelper.ToGuid(lbGuid.Text.Trim()), //主建 |
| | | PageView = txt_pageView.Text.Trim(), |
| | | Path = txt_path.Text.Trim(), |
| | | PageGroup=txt_pageGroup.Text.Trim(), |
| | | PageIdx=txt_pageIdx.Text.Trim(), |
| | | PageStatus=txt_pageStatus.Checked |
| | | PageGroup = txt_pageGroup.Text.Trim(), |
| | | PageIdx = txt_pageIdx.Text.Trim(), |
| | | PageStatus = txt_pageStatus.Checked |
| | | }; |
| | | try |
| | | { |
| | |
| | | { |
| | | lbGuid.Text = _rtn.rtnData; |
| | | toolBarMenu1.isSetBtn = true; |
| | | UtilityHelper.ChangeEnableByControl(this.panel1.Controls, false); |
| | | UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, false); |
| | | toolBarMenu1.currentAction = ""; |
| | | Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 6); |
| | | } |
| | | } |
| | | catch (Exception ex) |
| | |
| | | if (dd.rtnCode > 0) |
| | | { |
| | | DataTable dt = dd.rtnData.list; |
| | | gcMain.BindingContext = new BindingContext(); |
| | | gcMain.DataSource = dt; |
| | | gcMain.ForceInitialize(); |
| | | gcMain1.BindingContext = new BindingContext(); |
| | | gcMain1.DataSource = dt; |
| | | gcMain1.ForceInitialize(); |
| | | int dddd = dd.rtnData.pages;//总页 |
| | | pageBar1.TotalPages = dddd; |
| | | pageBar1.RecordCount = dd.rtnData.total;//记录总数 |
| | |
| | | { |
| | | dynamic dy = _rtn.rtnData; |
| | | lbGuid.Text = strGuid; |
| | | UtilityHelper.SetValueByObj(this.panel1.Controls, dy, isEdit); |
| | | UtilityHelper.SetValueByObj(this.layoutMx1.Controls, dy, isEdit); |
| | | } |
| | | else |
| | | ToolBox.MsgHelper.Warning("提示:" + _rtn.rtnMsg); |