public EventsModal GetAllEvents(EventsList list) { EventsModal modal = new EventsModal(); modal = new EventsData().GetEventsListData(list); return(modal); }
public JsonResult GetEventsByCenter(string centerId) { EventsModal eventsModal = new EventsModal(); try { EventsList events = new EventsList(); events.AgencyId = new Guid(Session["AgencyID"].ToString()); events.UserId = new Guid(Session["UserID"].ToString()); events.CenterId = (centerId == "0") ? 0 : Convert.ToInt64(EncryptDecrypt.Decrypt64(centerId)); eventsModal = GetAllEvents(events); return(Json(eventsModal, JsonRequestBehavior.AllowGet)); } catch (Exception ex) { clsError.WriteException(ex); return(Json(eventsModal, JsonRequestBehavior.AllowGet)); } }
public ActionResult Events() { EventsModal eventsModal = new EventsModal(); try { EventsList events = new EventsList(); events.AgencyId = new Guid(Session["AgencyID"].ToString()); events.UserId = new Guid(Session["UserID"].ToString()); events.CenterId = 0; eventsModal = GetAllEvents(events); return(View(eventsModal)); } catch (Exception ex) { clsError.WriteException(ex); return(View(eventsModal)); } }