public ActionResult UpdateApplication(RequestAdminApplication request) { if (ModelState.IsValid) { LogicAdminApplication adm = new LogicAdminApplication(); ResponseAdminApplication response = new ResponseAdminApplication(); request.flag = 'M'; request.dateUpdate = DateTime.Now; request.userUpdate = Session["user"].ToString(); request.userRegister = ""; response = adm.setApplication(request); if (response.code == 50000) { Session.Add("msgOk", response.message); } else { Session.Add("msgEr", response.message); } } return(RedirectToAction("Application")); }
public ActionResult addApplication(ResponseAdminApplicationList item1, RequestAdminApplication item2, ResponseAdminApplicationDetail item3, ResponseAdminApplication item4) { // Método para agregar Rol if (ModelState.IsValid) { LogicAdminApplication adm = new LogicAdminApplication(); item2.id = 0; item2.stateRecord = true; item2.flag = 'N'; item2.dateRegister = DateTime.Now; item2.userRegister = Session["user"].ToString(); item2.dateUpdate = DateTime.Now; item2.userUpdate = Session["user"].ToString(); item4 = adm.setApplication(item2); if (item4.code == 50000) { Session.Add("msgOk", item4.message); } else { Session.Add("msgEr", item4.message); } } Tuple <ResponseAdminApplicationList, RequestAdminApplication, ResponseAdminApplicationDetail, ResponseAdminApplication> response = new Tuple <ResponseAdminApplicationList, RequestAdminApplication, ResponseAdminApplicationDetail, ResponseAdminApplication>(item1, item2, item3, item4); return(RedirectToAction("Application")); }