示例#1
0
        public Notification(Refill refill, NotificationType type)
        {
            switch (type)
            {
            case NotificationType.Ready:
                ScheduledTime = DateTime.Now;
                break;

            case NotificationType.Refill:
                break;

            case NotificationType.Recall:
                break;

            case NotificationType.Birthday:
                break;

            case NotificationType.Reset:
                break;

            default:
                throw new ArgumentOutOfRangeException(nameof(type), type, null);
            }
            Type = type;
            //Make database call to get patient id from prescription id
            //patientId = database.getPrescription(prescriptionID);
            Sent     = false;
            SentTime = null;
        }
        public Refill CreateRefill(Prescription prescription, Patient patient)
        {
            var refill = new Refill(prescription);

            // TODO ? this looks incomplete
            return(refill);
        }
示例#3
0
        public static Notification CreateNotification(Refill refill, NotificationType type)
        {
            var notification = new Notification(refill, type);

            //Save notification to database
            return(notification);
        }
示例#4
0
        public static Refill getTestRefill()
        {
            var refill = new Refill {
                PrescriptionId = 1123,
                RefillDate     = DateTime.Now,
                Refilled       = false
            };

            return(refill);
        }