Exemple #1
0
 public ActionResult RemoveEventScheduleByID(int id)
 {
     using (var service = new EventScheduleService())
     {
         service.Delete(id);
     }
     return(null);
 }
Exemple #2
0
 public JsonResult Send()
 {
     using (var service = new EventScheduleService())
     {
         int pharmacyCode = User.Pharmacy.Code;
         //get all scheduled events where the date is today
         EventProcessingService.SendEvents(service.GetEventsBeforeToday().Where(x => x.Event.Patient.Pharmacy.Code == pharmacyCode).Select(es => es.Event).ToList(), pharmacyCode);
     }
     return(Json(true));
 }
Exemple #3
0
        public ActionResult ReturnTable()
        {
            List <DayEventModel> models = new List <DayEventModel>();

            using (var service = new EventScheduleService())
            {
                //get all scheduled events where the date is today
                models = service.GetEventsBeforeToday()
                         .Where(x => x.Event.Patient.Pharmacy.Code == User.Pharmacy.Code)
                         .Select(e => new DayEventModel(e))
                         .ToList();
            }
            return(PartialView(models));
        }