Beispiel #1
0
        public static void dentalMenu(List <string> user) //menu for dentists and nurses
        {
            do
            {
                Console.WriteLine(Environment.NewLine + "Dental Staff Menu" + Environment.NewLine + "-----------------");
                Console.WriteLine("Type P to | View all Patient Information" + Environment.NewLine + "Type A to | View all Appointments" + Environment.NewLine + "Type N to | Leave a Note on an Appointment" + Environment.NewLine + "Type C to | View all Phone Consultations" + Environment.NewLine + "Type T to | View all Treatments" + Environment.NewLine + "Type X to | Close the Software");
                string menuChoice = Console.ReadLine().ToUpper();

                switch (menuChoice)
                {
                case "P":
                    Patient.viewPatients();     //method to display all patients
                    break;

                case "A":
                    Appointment.displayAppointments();     //method to display all appointments
                    break;

                case "N":
                    Appointment.addNote(user);     //method to add note to an appointment
                    break;

                case "T":
                    Treatment.treatmentDisplay();     //method to display all treatments
                    break;

                case "X":
                    Environment.Exit(1);     //close the application
                    break;

                case "C":
                    if (user.ElementAt(1) == "Nurse")    //Prevents access if user is a Nurse
                    {
                        Console.WriteLine("Error | This Action is for Dentists Only");
                    }
                    else
                    {
                        Consultation.dentistView(Dentist.loginInformation(user));     //Load Method to view all Phone Consultations for that dentist
                    }
                    break;
                }
            } while (!constantMenu);
        }
        protected static void userMenu(Patient_User user) //Main menu for patient users
        {
            do
            {
                Console.WriteLine(Environment.NewLine + "Please Select one of the following options:");
                Console.WriteLine("Type R to | Request a Phone Consultation" + Environment.NewLine + "Type V to | View your Requests" + Environment.NewLine + "Type T to | View all Available Treatments");
                Console.WriteLine("Type A to | View all confirmed Apointments" + Environment.NewLine + "Type C to | View your Phone Consultations" + Environment.NewLine + "Type X to | Close the Software");
                string userChoice = Console.ReadLine().ToUpper();

                switch (userChoice)
                {
                case "R":
                    Ticket.newTicket(user);     //method to create request ticket for phone consultation
                    break;

                case "V":
                    Ticket.viewTickets(user);     //method to view all active request tickets
                    break;

                case "T":
                    Treatment.treatmentDisplay();     //method to display all available treatments
                    break;

                case "A":
                    Appointment.patientCheck(user);     //method to view all current appointments
                    break;

                case "C":
                    Consultation.patientView(user);     //method to view all confirmed phone consultations
                    break;

                case "X":
                    Environment.Exit(1);     //close the application
                    break;
                }
            } while (!constantMenu);
        }
Beispiel #3
0
        public static void receptionistTreatments()
        {
            do
            {
                Console.WriteLine(Environment.NewLine + "Treatment Management Menu" + Environment.NewLine + "----------------------");
                Console.WriteLine("Type A to | Add a new Treatment" + Environment.NewLine + "Type V to | View all Treatments" + Environment.NewLine + "Type B to | Return to the Previous Menu");
                string menuChoice = Console.ReadLine().ToUpper();

                switch (menuChoice)
                {
                case "A":
                    Treatment.newTreatment();     //method to create new treatment
                    break;

                case "V":
                    Treatment.treatmentDisplay();     //method to display all treatments
                    break;

                case "B":
                    receptionistMenu(loginBackup);     //load previous menu
                    break;
                }
            } while (!constantMenu);
        }