Exemplo n.º 1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (null != Common.Common.NoHtml(Request.QueryString["action"]))
            {
                strAction = Common.Common.NoHtml(Request.QueryString["action"]);
            }
            if (null != Common.Common.NoHtml(Request.QueryString["id"]))
            {
                strID = Common.Common.NoHtml(Request.QueryString["id"]);
            }

            MSProductParaDAL dal = new MSProductParaDAL();

            switch (strAction)
            {
            case "del":
                if (dal.UpdateMSPParaState(strID))
                {
                    strMessage = "操作成功!";
                }
                else
                {
                    strMessage = "操作失败!";
                }
                break;
            }
            Response.Write(strMessage);
            Response.End();
        }
Exemplo n.º 2
0
        /// <summary>
        /// 删除型号
        /// </summary>
        void DelPara()
        {
            string pr = string.Empty;

            if (Request["pr"] != null && Request["pr"] != "")
            {
                pr = Common.Common.NoHtml(Request["pr"]);
            }
            MSProductParaDAL paraDal = new MSProductParaDAL();

            if (pr != null && pr != "")
            {
                if (paraDal.UpdateMSPParaState(pr))
                {
                    Response.Write("{\"success\":true}");
                }
                else
                {
                    Response.Write("{\"error\":true}");
                }
            }
            Response.End();
        }