Beispiel #1
0
        //赋值操作
        private void ShowInfo(int _id)
        {
            Spread.BLL.Protocol bll = new Spread.BLL.Protocol();
            Spread.Model.Protocol model = bll.GetModel(_id);

            txtTitle.Text = model.Title;
            txtAuthor.Text = model.Author;
            FCKeditor2.Value = model.Form;
            FCKeditor.Value = model.Content;
            txtClick.Text = model.Click.ToString();
        }
Beispiel #2
0
        //保存
        protected void btnSave_Click(object sender, EventArgs e)
        {
            Spread.BLL.Protocol bll = new Spread.BLL.Protocol();
            Spread.Model.Protocol model = bll.GetModel(this.Id);

            model.Title = txtTitle.Text.Trim();
            model.Author = txtAuthor.Text.Trim();
            model.Form = FCKeditor2.Value.Trim();
         
          
            model.ClassId =0;
            model.ImgUrl = "";
            model.Content = FCKeditor.Value;
            model.Click = int.Parse(txtClick.Text.Trim());

            model.IsMsg = false;
            model.IsTop = false;
            model.IsRed = false;
            model.IsHot = false;
            model.IsSlide = false;
            bll.Update(model);
            Response.Write("<script>alert('协议编辑成功啦!!!!!')</script>");
           
        }
Beispiel #3
0
 //设置操作
 protected void rptList_ItemCommand(object source, RepeaterCommandEventArgs e)
 {
     int id = Convert.ToInt32(((Label)e.Item.FindControl("lb_id")).Text);
     Spread.BLL.Protocol bll = new Spread.BLL.Protocol();
     Spread.Model.Protocol model = bll.GetModel(id);
     
     RptBind("Id>0" + this.CombSqlTxt(this.classId, this.keywords, this.property), "AddTime desc");
 }