Esempio n. 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);
        }
Esempio n. 3
0
        public static Notification CreateNotification(Refill refill, NotificationType type)
        {
            var notification = new Notification(refill, type);

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

            return(refill);
        }