Example #1
0
        private void DelButton(int btnId, HttpContext context)
        {
            var btn = ButtonDal.Instance.Get(btnId);
            int k   = ButtonDal.Instance.Delete(btnId);

            var msg = "删除成功。";

            if (k <= 0)
            {
                msg = "删除失败。";
            }
            else
            {
                LogBll <Button> log = new LogBll <Button>();
                log.DeleteLog(btn);
            }
            context.Response.Write(new JsonMessage {
                Success = true, Data = k.ToString(), Message = msg
            }.ToString());
        }