Esempio n. 1
0
    /// <summary>
    /// 绑定
    /// </summary>
    public void Bind()
    {
        Hi.Model.BD_ShopMessage model = OrderBll.GetModel(int.Parse(Request.QueryString["ID"].ToString()));

        this.lblname.InnerText   = model.Name;
        this.lblphone.InnerText  = model.Phone;
        this.lblremark.InnerText = model.Remark;
        this.lblread.InnerText   = model.IsRead == 0 ? "未读" : "已读";
        this.lblDate.InnerText   = model.CreateDate.ToString("yyyy-MM-dd");
        model.IsRead             = 1;
        model.ID = int.Parse(Request.QueryString["ID"].ToString());
        bool bol = new Hi.BLL.BD_ShopMessage().Update(model);
    }
Esempio n. 2
0
 //删除
 protected void btnDelate_Click(object sender, EventArgs e)
 {
     try
     {
         if (Request.QueryString["ID"] != "")
         {
             Hi.Model.BD_ShopMessage model = OrderBll.GetModel(int.Parse(Request.QueryString["ID"].ToString()));
             model.dr = 1;
             model.ID = int.Parse(Request.QueryString["ID"].ToString());
             bool bol = new Hi.BLL.BD_ShopMessage().Update(model);
             if (bol)
             {
                 Response.Redirect("ShopMessage.aspx");
             }
         }
     }
     catch (Exception)
     {
         Response.Redirect("ShopMessage.aspx");
     }
 }
Esempio n. 3
0
 /// <summary>
 /// 更新一条数据
 /// </summary>
 public bool Update(Hi.Model.BD_ShopMessage model)
 {
     return(dal.Update(model));
 }
Esempio n. 4
0
 /// <summary>
 /// 增加一条数据
 /// </summary>
 public int Add(Hi.Model.BD_ShopMessage model)
 {
     return(dal.Add(model));
 }