예제 #1
0
        public PrescriptionMessageCollection GetPrescriptionMessageCollection(DateTime startTime, DateTime endTime)
        {
            PrescriptionMessageCollection result = new PrescriptionMessageCollection();

            result.OutPatientMessage = this.DomainFactory.CreatePrescriptionMessage(EnumOutPatientCategories.OUTPATIENT).GetPrescriptionMessage(startTime, endTime);

            result.EmergencyMessage = this.DomainFactory.CreatePrescriptionMessage(EnumOutPatientCategories.EMERGEMENT).GetPrescriptionMessage(startTime, endTime);

            result.TotalMessage = new PrescriptionMessage
            {
                InjectAntibioticPerson   = result.OutPatientMessage.InjectAntibioticPerson + result.EmergencyMessage.InjectAntibioticPerson,
                UseDrugPerson            = result.OutPatientMessage.UseDrugPerson + result.EmergencyMessage.UseDrugPerson,
                AntibioticCategoryNumber = result.OutPatientMessage.AntibioticCategoryNumber + result.EmergencyMessage.AntibioticCategoryNumber,
                AntibioticCost           = result.OutPatientMessage.AntibioticCost + result.EmergencyMessage.AntibioticCost,
                DrugCost = result.OutPatientMessage.DrugCost + result.EmergencyMessage.DrugCost
            };
            return(result);
        }
예제 #2
0
        /// <summary>
        /// 门、急诊患者药物处方情况集合
        /// </summary>
        /// <param name="startTime">The start time.</param>
        /// <param name="endTime">The end time.</param>
        /// <returns>ActionResult.</returns>
        public ActionResult GetOutPatientDrugDetails(DateTime startTime, DateTime endTime)
        {
            ViewBag.startTime = startTime;
            ViewBag.endTime   = endTime.AddDays(1).AddMilliseconds(-1);
            endTime           = endTime.AddDays(1);
            var viewModel = new PrescriptionMessageCollection();

            try
            {
                var iPrescriptionMessage = this.ReporterViewFactory.CreatePrescriptionMessageCollection();
                viewModel = iPrescriptionMessage.GetPrescriptionMessageCollection(startTime, endTime);
            }
            catch (Exception)
            {
                viewModel = null;
            }

            return(PartialView("_GetOutPatientDrugDetails", viewModel));
        }