public static void Menu(Employee sessionUser) { int response = -1; Console.Clear(); Console.WriteLine("-------------------------- Funcionários ---------------------------"); Console.WriteLine("#######################################################################"); Console.WriteLine("# 1 - Ver lista #"); Console.WriteLine("# 2 - Gravar Funcionários #"); Console.WriteLine("# 3 - Procurar #"); Console.WriteLine("# 4 - Editar #"); Console.WriteLine("# 5 - Editar #"); Console.WriteLine("# 6 - Limpar Lista #"); Console.WriteLine("# 0 - Sair #"); Console.WriteLine("#######################################################################"); EntityEmployees listEntityEmployees = new EntityEmployees(); listEntityEmployees.List(); while (response != 0) { Console.WriteLine("Insira uma opção"); response = Convert.ToInt32(Console.ReadLine()); switch (response) { case 1: ListEmployees(listEntityEmployees); break; case 2: CreateEmployee(listEntityEmployees, sessionUser); break; case 3: ScnLogin.Login(); break; case 4: ScnLogin.Login(); break; default: break; } } }
public static void MenuCaixa(Employee sessionUser) { int response = -1; while (response != 0) { Console.Clear(); Console.WriteLine("------------------------------ Menu -------------------------------"); Console.WriteLine("#######################################################################"); Console.WriteLine("# 1 - Venda #"); Console.WriteLine("# 2 - Fatuara #"); Console.WriteLine("# 0 - Sair #"); Console.WriteLine("#######################################################################"); Console.WriteLine("Insira uma opção"); response = Convert.ToInt32(Console.ReadLine()); switch (response) { case 1: MenuEmployee.Menu(sessionUser); break; case 2: ScnLogin.Login(); break; case 3: ScnLogin.Login(); break; case 4: ScnLogin.Login(); break; default: Console.Clear(); break; } } }
public static void initMenu() { int response = -1; while (response != 0) { Console.WriteLine("#######################################################################"); Console.WriteLine("# 1 - Login #"); Console.WriteLine("# 0 - Sair #"); Console.WriteLine("#######################################################################"); Console.WriteLine("Insira uma opção"); response = Convert.ToInt32(Console.ReadLine()); switch (response) { case 1: ScnLogin.Login(); break; default: break; } } }