//public void AddTypeBind() { // ddlAddtype.Items.Add(new ListItem("全部", "-1")); // foreach (Enums.AddType a in Enum.GetValues(typeof(Enums.AddType))) { // ddlAddtype.Items.Add(new ListItem(a.ToString(), ((int)a).ToString())); // } //} /// <summary> /// 绑定销售订单信息列表 /// </summary> public void Bind() { int pageCount = 0; int Counts = 0; string strwhere = string.Empty; if (ViewState["strwhere"] != null) { strwhere += ViewState["strwhere"].ToString(); } strwhere += "and Otype!=9 and isnull(dr,0)=0 and disid=" + this.DisID; //and PayState in (0,2,7) if (this.ddrComp.Value != "") { strwhere += " and CompID=" + this.ddrComp.Value; //add by hgh } //if (ddlOType.SelectedValue != "-1") //{ // strwhere += " and otype=" + ddlOType.SelectedValue + ""; ////} if (this.txtPager.Value.Trim().ToString() != "") { if (this.txtPager.Value.Trim().Length < 4) { Pager.PageSize = int.Parse(this.txtPager.Value.Trim()); } else { this.txtPager.Value = "100"; Pager.PageSize = 100; } } List <Hi.Model.DIS_Order> orders = new Hi.BLL.DIS_Order().GetList(Pager.PageSize, Pager.CurrentPageIndex, "CreateDate", true, strwhere, out pageCount, out Counts); this.rptOrder.DataSource = orders; this.rptOrder.DataBind(); Pager.RecordCount = Counts; page = Pager.CurrentPageIndex.ToString(); oId = string.Join(",", orders.Select(T => T.ID)); }