protected void Button2_Click1(object sender, EventArgs e) { Button b = sender as Button; d.removeProduct(int.Parse(b.CommandArgument), Session["UserAccount"].ToString()); DataBindAllPro(Session["UserAccount"].ToString(), 1); }
/// <summary> /// 通过卖家商品的ID,删除商品 /// </summary> /// <param name="productId"></param> /// <param name="sellerAccount"></param> /// <returns></returns> public bool remove(int productId, string sellerAccount) { return(db.removeProduct(productId, sellerAccount)); }