void deatilGridBar_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { if (e.Key == "S1") { this.SumType = 0; } else { this.SumType = 1; } //this.InitData(); DetailGrid grid = this.EditForm.FindControl("OrderGrid") as DetailGrid; if (grid != null) { if (this.SumType == 0) { int i = 1; if (grid.ADGrid.Columns[0].GetType() == typeof(DataGridIconColumn)) { i = 2; } grid.ADGrid.Columns[i - 1].Visibility = Visibility.Visible; grid.ADGrid.Columns[i].Visibility = Visibility.Visible; grid.ADGrid.Columns[i + 3].Visibility = Visibility.Visible; grid.ADGrid.Columns[i + 1].Visibility = Visibility.Collapsed; grid.ADGrid.Columns[i + 2].Visibility = Visibility.Collapsed; grid.ADGrid.Columns[i + 4].Visibility = Visibility.Collapsed; grid.ADGrid.Columns[i + 5].Visibility = Visibility.Collapsed; grid.ItemsSource = this.OrderEntity.GetRelationFBEntities(typeof(V_SubjectCompanySum).Name); } else { int i = 1; if (grid.ADGrid.Columns[0].GetType() == typeof(DataGridIconColumn)) { i = 2; } grid.ADGrid.Columns[i - 1].Visibility = Visibility.Collapsed; grid.ADGrid.Columns[i].Visibility = Visibility.Collapsed; grid.ADGrid.Columns[i + 2].Visibility = Visibility.Visible; grid.ADGrid.Columns[i + 1].Visibility = Visibility.Visible; grid.ADGrid.Columns[i + 3].Visibility = Visibility.Visible; grid.ADGrid.Columns[i + 4].Visibility = Visibility.Visible; if ((this.EditForm.OperationType == OperationTypes.Add || this.EditForm.OperationType == OperationTypes.Edit || this.EditForm.OperationType == OperationTypes.ReSubmit)) { grid.ADGrid.Columns[i + 5].Visibility = Visibility.Visible; } grid.ItemsSource = this.OrderEntity.GetRelationFBEntities(typeof(T_FB_COMPANYBUDGETSUMDETAIL).Name); } } }
void tooBarTop_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { if (this.ADtGrid.SelectedItems.Count == 0) { CommonFunction.NotifySelection(null); return; } OrderEntity orderEntity = this.ADtGrid.SelectedItem as OrderEntity; ShowEditForm(orderEntity, OperationTypes.Browse); }
private void tooBarTop_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { switch (e.Key) { case "Save": this.editForm.Save(); break; case "CheckBudget": CheckBudget(); break; } }
void deatilGridBar_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { switch (e.Key) { case "New" : OnToolBarItemClick(Actions.Add); break; case "Delete" : OnToolBarItemClick(Actions.Delete); break; } }
public void tooBarTop_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { try { ShowProcess(); Save(); } catch (Exception ex) { CommonFunction.ShowErrorMessage(ex.Message); CloseProcess(); } }
void deatilGridBar_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { switch (e.Key) { case "New": Add(); break; case "Delete": IList list = this.AGrid.SelectedItems as IList; Delete(list); break; } }
private void tooBarTop_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { try { ShowProcess(); // ComfirmWindow.ConfirmationBoxs("提示", "测试页面", Utility.GetResourceStr("CONFIRM"), MessageIcon.Question); Save(); } catch (Exception ex) { CommonFunction.ShowErrorMessage(ex.Message); CloseProcess(); } }
void tooBarTop_ItemClicked(object sender, ToolBar.ToolBarItemClickArgs e) { switch (e.Key) { case "AddType": AddType(); break; case "AddSubject": AddSubject(); break; case "AddSubSubject": AddSubSubject(); break; case "Save": try { ShowProcess(); bool isCheck = Save(); if (!isCheck) { CloseProcess(); } } catch (Exception ex) { CommonFunction.ShowErrorMessage(ex.Message); CloseProcess(); } break; case "Delete": Delete(); break; } }