日期:2014-05-16 浏览次数:20968 次
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[System.ComponentModel.ToolboxItem(false)]
// 若要允许使用 ASP.NET AJAX 从脚本中调用此 Web 服务,请取消注释以下行。
[System.Web.Script.Services.ScriptService]
public class Carts : System.Web.Services.WebService
{
[WebMethod]
public string CartsQuantity(int Quantity, int ProductID)
{
string UserID = BLL.MyCookies.Cookie.GetCookie("UserID").ToString();
StringBuilder sb = new StringBuilder();
sb.Append("{");
sb.Append("\"UserID\":\"" + UserID + "\",");
sb.Append("\"Quantity\":\"" + Quantity + "\",");
sb.Append("\"ProductID\":\"" + ProductID + "\"");
sb.Append("}");