protected void Page_Load(object sender, EventArgs e) { this.site_id = DTRequest.GetQueryInt("site_id"); this.property = DTRequest.GetQueryInt("property"); this.keywords = DTRequest.GetQueryString("keywords"); this.pageSize = GetPageSize(10); //每页数量 if (!Page.IsPostBack) { ChkAdminLevel("plugin_link", DTEnums.ActionEnum.View.ToString()); //检查权限 SiteBind(); //绑定网点 string strWhere = "id>0"; if (this.site_id > 0) { DTcms.Model.channel_site model = new DTcms.BLL.channel_site().GetModel(this.site_id); if (null != model) { strWhere = "site_path='" + model.build_path + "'"; this.ddlSiteId.SelectedValue = this.site_id.ToString(); } } if (this.property > 0) { this.ddlProperty.SelectedValue = this.property.ToString(); } RptBind(strWhere + CombSqlTxt(this.property, this.keywords), "sort_id asc,add_time desc"); } }
private void TreeBind() { DTcms.BLL.channel_site bll = new DTcms.BLL.channel_site(); DataTable dt = bll.GetList(0, "", "sort_id asc,id desc").Tables[0]; this.ddlSitePath.Items.Clear(); this.ddlSitePath.Items.Add(new ListItem("请选择站点...", "")); foreach (DataRow dr in dt.Rows) { this.ddlSitePath.Items.Add(new ListItem(dr["title"].ToString(), dr["build_path"].ToString())); } }
private void SiteBind() { DTcms.BLL.channel_site bll = new DTcms.BLL.channel_site(); DataTable dt = bll.GetList(0, "is_mobile=0", "sort_id asc,id desc").Tables[0]; this.ddlSiteId.Items.Clear(); this.ddlSiteId.Items.Add(new ListItem("所有站点", "")); foreach (DataRow dr in dt.Rows) { this.ddlSiteId.Items.Add(new ListItem(dr["title"].ToString(), dr["id"].ToString())); } }
private void TreeBind() { DTcms.BLL.channel_site bll = new DTcms.BLL.channel_site(); DataTable dt = bll.GetList(0, "", "sort_id asc,id desc").Tables[0]; this.ddlSitePath.Items.Clear(); this.ddlSitePath.Items.Add(new ListItem("请选择站点...", "")); foreach (DataRow dr in dt.Rows) { this.ddlSitePath.Items.Add(new ListItem(dr["title"].ToString(), dr["build_path"].ToString())); } }