//------------ Prescriptions ---------------
        public void addPrescription(Prescription prescription)
        {
            IDal dal = new PrescriptionDAL.DalImplement();

            //Checks if the doctor's license is valid
            if (dal.getAllDoctors().ToList().Find(d => d.DoctorId == prescription.Doctor).LicenseExpirationDate >= DateTime.Today)
            {
                try
                {
                    dal.addPrescription(prescription);
                }
                catch (Exception ex)
                {
                    throw ex;
                }
            }
            else
            {
                throw new Exception("The the doctor's license is not valid ");
            }
        }
        public IEnumerable <Doctor> getAllDoctors()
        {
            IDal dal = new PrescriptionDAL.DalImplement();

            return(dal.getAllDoctors());
        }