private void _processDataSource(object sender, int inclusive, int exclusive, int pageSize) { WebQueryEventArgs args = new WebQueryEventArgs(inclusive, exclusive); this.LoadGridDataSource(sender, args); if (args.GridDataSource != null) { DomainObjectToGridRowEventArgs args1 = new DomainObjectToGridRowEventArgs(); Infragistics.WebUI.UltraWebGrid.UltraGridRow lastRow = null; foreach (DomainObject obj in args.GridDataSource) { args1.DomainObject = obj; this.DomainObjectToGridRow(sender, args1); if (args1.GridRow != null) { this.gridWebGrid.Rows.Add(this.buildMergedGridRow(args1.GridRow, lastRow)); lastRow = args1.GridRow; } } } if (this.pagerSizeSelector != null) { this.pagerToolBar.PageSize = pageSize; } if (this.pagerToolBar != null) { this.pagerToolBar.RowCount = args.RowCount; } }
private void _helper_DomainObjectToGridRow(object sender, EventArgs e) { DomainObjectToGridRowEventArgs de = (e as DomainObjectToGridRowEventArgs); if (de != null) { de.GridRow = new UltraGridRow(GetArrayFrom(de.DomainObject)); } }
private void WebQueryHelper_DomainObjectToGridRow(object sender, EventArgs e) { DomainObjectToGridRowEventArgs args = (DomainObjectToGridRowEventArgs)e; if (args.DomainObject != null) { RptAchievingRate obj = (RptAchievingRate)args.DomainObject; args.GridRow = new UltraGridRow(new object[] { FormatHelper.ToDateString(obj.ShiftDay), obj.AchievingQty.ToString("0.00"), obj.PlanQty.ToString("0.00"), obj.AchievingRate.ToString("0.00%") }); } }