예제 #1
0
 public ActionResult Edit(SedeSelectorModel model)
 {
     if ((model.sesion = SessionDB.start(Request, Response, false, model.db, SESSION_BEHAVIOR.AJAX)) == null)
     {
         return(Content("-1"));
     }
     if (model.Edit())
     {
         return(Json(new JavaScriptSerializer().Serialize(model)));
     }
     return(Content("-1"));
 }
예제 #2
0
 public ActionResult Save(SedeSelectorModel model)
 {
     try
     {
         if ((model.sesion = SessionDB.start(Request, Response, false, model.db, SESSION_BEHAVIOR.AJAX)) == null)
         {
             return(Content("-1"));
         }
         model.Save();
     }
     catch (Exception e) { }
     return(Content("0"));
 }