Exemple #1
0
        public static void CreateNewStaff()
        {
            Console.WriteLine("     *******************     \nCreating New Staff Record:\n     *******************     \nEnter Staff Surname:\n");
            string surname = Console.ReadLine().ToLower();

            Console.WriteLine("\nEnter Staff First Name:\n");
            string firstname = Console.ReadLine().ToLower();

            Console.WriteLine("\nEnter Staff Date of Birth in the format [DD/MM/YY]:\n");
            DateTime dob = DateTime.Parse(Console.ReadLine());

            Console.WriteLine("\nEnter Staff Address and Postcode:\n");
            string address = Console.ReadLine();

            Console.WriteLine("\nEnter Staff Primary Contact Number:\n");
            long number = Convert.ToInt64(Console.ReadLine());

            //Start Method call to identify and find the practice
            Console.WriteLine("\nWhich Practice is Staff member's princple Practice\n");
            string location = Console.ReadLine();

            Console.WriteLine("Set Staff Member's Primary Job Role\n1: System Admin\n2: Dentist\n3: Nurse\n4:Receptionist\n");
            Role role = (Role)Convert.ToInt16(Console.ReadLine());



            CentralisedRecords.SubmitNewStaff(new Staff(firstname, surname, address, dob, number, role, CentralisedRecords.FindPractice(location)));
        }
Exemple #2
0
        public static void Initialise()
        {
            //Initialise Practice
            Practice taunton    = new Practice("Taunton");
            Practice bridgwater = new Practice("Bridgwater");
            Practice exeter     = new Practice("Exeter");

            CentralisedRecords.InitialiseNewPractice(taunton);
            CentralisedRecords.InitialiseNewPractice(bridgwater);
            CentralisedRecords.InitialiseNewPractice(exeter);



            //Initialise Staff Records
            //
            Staff Sansom = new Staff("elizabeth", "sansom", "3 Cyril Street, Taunton, TA2 6HW",
                                     new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Taunton"));
            Staff Shaun = new Staff("duncan", "shaun", "7 Hook Street, Taunton, TA1 1BU",
                                    new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Taunton"));
            Staff Smith = new Staff("michael", "smith", "13 Smithy, Wellington, TA14 3ZY",
                                    new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Taunton"));


            Staff Bateman = new Staff("jason", "bateman", "4 Wrens Close, Exeter, EX12 1BT",
                                      new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Exeter"));
            Staff Pierce = new Staff("pierce", "brosnan", "5 Tank Street, Exeter, EX11, 5TT",
                                     new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Exeter"));

            Staff Cruise = new Staff("tom", "cruise", "15 Alpha Street, Exeter, EX1 2BB",
                                     new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Exeter"));

            Staff Stone = new Staff("john", "stone", "The Burke, Bridgwater, TA5, 1AX",
                                    new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Bridgwater"));
            Staff Sword = new Staff("chris", "bent", "12 Burns Road, Bridgwater, TA5 4TY",
                                    new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Bridgwater"));

            Staff Swift = new Staff("jay", "swift", "55 West Street, Bridgwater, TA5 1ZY",
                                    new DateTime(10 / 04 / 87), 01823333333, Role.Dentist, CentralisedRecords.FindPractice("Bridgwater"));

            //Initialise Patient Records
            Patient Shaunj = new Patient("Jim", "Shaun", "12 Fake Street, Taunton, TA1 1NN", new DateTime(27 / 10 / 1989), 07001001002, taunton, Sansom);
        }