Beispiel #1
0
 private void Upd_Disable_ByID(HttpContext context)
 {
     String jSonString = "";
     try {
         ConfigsBO configsBo = new ConfigsBO();
         int id = Convert.ToInt32(context.Request.QueryString["ID"]);
         bool disable = Convert.ToBoolean(context.Request.QueryString["Disable"]);
         int ret = configsBo.Upd_Disable(id, disable);
         if (ret == 0) jSonString = "{\"status\":\"error|" + ret + "\"}";
         if (ret != 0) jSonString = "{\"status\": \"success\"}";
     }
     catch (Exception ex) {
         jSonString = "{\"status\":\"error\" ,\"message\":\"" + ex.Message + "\"}";
     }
     finally {
         context.Response.Write(jSonString);
     }
 }