protected void LinqDataSourceRadGridDataSource_Selecting(object sender, LinqDataSourceSelectEventArgs e) { var data = EsmHelper.GetData(portalDc, this.itemFilter); RadDataPager radDataPager = RadListViewItem.FindControl("RadDataPagerItem") as RadDataPager; vw_item vwItem = data.ToList()[pageIndex]; var query = from c in portalDc.purchaseOrderLines where c.itemId == vwItem.itemId && c.purchaseOrder.company.companyCode == vwItem.companyCode select new { c.openQuantity, c.uomCode, c.deliveryDate, c.purchaseOrder.businessPartner.bpName, c.purchaseOrder.businessPartner.country.description }; e.Result = query; }
protected void Page_Load(object sender, EventArgs e) { portalDc = new DALPortalDataContext(); this.itemFilter = (ItemFilter)Session["itemFilter"]; if (!IsPostBack) { this.selectedItemId = Convert.ToInt32(Session["selectedItemId"]); this.selectedCompanyCode = Session["selectedCompanyCode"].ToString(); IQueryable <vw_item> data = EsmHelper.GetData(portalDc, this.itemFilter); int index = data.ToList().FindIndex(c => c.itemId.Equals(selectedItemId) && c.companyCode.Equals(selectedCompanyCode)); RadDataPager radDataPager = RadListViewItem.FindControl("RadDataPagerItem") as RadDataPager; radDataPager.FireCommand("Page", (index).ToString()); } }
protected void LinqDataSourceAcbOutsideDiameter3_Selecting(object sender, LinqDataSourceSelectEventArgs e) { var data = EsmHelper.GetData(portalDc, this.itemFilter); e.Result = data.Select(c => new { c.outsideDiameter3 }).Distinct(); }
protected void LinqDataSourceAcbDescription_Selecting(object sender, LinqDataSourceSelectEventArgs e) { var data = EsmHelper.GetData(portalDc, this.itemFilter); e.Result = data.Select(c => new { c.description }).Distinct(); }
protected void DataSourceRadGrid_Selecting(object sender, LinqDataSourceSelectEventArgs e) { e.Result = EsmHelper.GetData(portalDc, this.itemFilter); }
protected void LinqDataSourceAcbWallThickness2_Selecting(object sender, LinqDataSourceSelectEventArgs e) { var data = EsmHelper.GetData(portalDc, this.itemFilter); e.Result = data.Select(c => new { c.wallThickness2 }).Distinct(); }