예제 #1
0
파일: Program.cs 프로젝트: vochita/PSSC
        static void profesori()
        {
            int selector = 0;
            int maxItem = 6;
            Console.WriteLine("PROFESOR");
            string profesor;
            Console.WriteLine("Introduceti numele dumneavoastra:\n");
            profesor=Console.ReadLine();
            Profesor prof = new Profesor(profesor);
            do
            {
                Console.WriteLine("Optiuni Profesor\n");
                Console.WriteLine("1-Vizualizare nivel Universitate");
                Console.WriteLine("2-Vizualizare Nivel studenti");
                Console.WriteLine("3-Adaugare date nivel studenti");
                Console.WriteLine("4-Update date nivel studenti");
                Console.WriteLine("5-Delete date nivel studenti");
                Console.WriteLine("6-Exit");
                selector = Convert.ToInt32(Console.ReadLine());
                switch (selector)
                {
                    case 1: prof.ViewDB(Globals.selectALL, Globals.Tabela1);
                        break;
                    case 2: prof.ViewDB(Globals.selectALL, Globals.Tabela2);
                        break;
                    case 3: prof.AddDB();
                        break;
                    case 4: prof.UpdateDB();
                        break;
                    case 5: prof.DeleteDB(Globals.Tabela2);
                        break;
                    case 6: break;
                    default: break;
                }

            } while (selector != maxItem);
        }
예제 #2
0
        static void profesori()
        {
            int selector = 0;
            int maxItem  = 13;

            Console.WriteLine("PROFESOR");
            string profesor;

            Console.WriteLine("Introduceti numele dumneavoastra:\n");
            profesor = Console.ReadLine();
            Profesor prof = new Profesor(profesor);

            if (prof.login() == true)
            {
                do
                {
                    Console.WriteLine("Optiuni Profesor\n");
                    Console.WriteLine("1-Vizualizare nivel Universitate");
                    Console.WriteLine("2-Vizualizare Nivel studenti");
                    Console.WriteLine("3-Adaugare date nivel studenti");
                    Console.WriteLine("4-Update date nivel studenti by student(nume,prenume)");
                    Console.WriteLine("5-Update date nivel studenti by student(nume)");
                    Console.WriteLine("6-Delete date nivel studenti by student(nume,prenume)");
                    Console.WriteLine("7-Delete date nivel studenti by student(nume)");
                    Console.WriteLine("8-Find anythink in Universitate by prof ");
                    Console.WriteLine("9-Find anythink in Universitate by materie ");
                    Console.WriteLine("10-Find anythink in Universitate by facultate ");
                    Console.WriteLine("11-Find anythink in UniversitateIntermediere by student ");
                    Console.WriteLine("13-Request studenti from secretariat ");
                    Console.WriteLine("12-Exit");
                    selector = Convert.ToInt32(Console.ReadLine());
                    switch (selector)
                    {
                    case 1:
                        break;

                    case 2:
                        break;

                    case 3:
                        break;

                    case 4:
                        break;

                    case 5:
                        break;

                    case 6:
                        break;

                    case 7:
                        break;

                    case 8:
                        break;

                    case 9:
                        break;

                    case 10:
                        break;

                    case 11:
                        break;

                    case 12:
                        break;

                    case 13:
                        break;

                    default: break;
                    }
                } while (selector != maxItem);
            }
            else
            {
                Console.WriteLine("Eroare la autentificare");
            }
        }