internal static void Message(string message) { MenuStructure.DrawScreen(); MenuStructure.SetTitle("Message"); MenuStructure.AddLine(1); MenuStructure.WriteNewLine(message); MenuStructure.ReadKey(); }
internal static bool AreYouSureScreen(string message, Action method) { MenuStructure.DrawScreen(); MenuStructure.SetTitle(message); MenuStructure.AddLine(1); MenuStructure.WriteLine("Are you sure? (Y/N) "); var anwser = MenuStructure.ReadLine(method, ETypeRead.YesOrNo); return(anwser == "Y"); }
internal static string ListScreen(string title, string listType, string[] optionList, Action method) { int optionIndex = 0; MenuStructure.DrawScreen(); MenuStructure.SetGoBackOption(); MenuStructure.SetTitle(title); MenuStructure.WriteNewLine("Choose one " + listType + ":"); foreach (var optionText in optionList) { optionIndex++; MenuStructure.WriteNewLine(optionIndex + " - " + optionText); } MenuStructure.AddLine(1); MenuStructure.WriteLine(listType + ": "); return(MenuStructure.ReadLine(method, ETypeRead.NumberList, optionIndex)); }
internal static SAccount AddAccountScreen() { SAccount sAccount = new SAccount(); MenuStructure.DrawScreen(); MenuStructure.SetGoBackOption(); MenuStructure.SetTitle("Add Account"); MenuStructure.WriteNewLine("Fill the info above"); MenuStructure.AddLine(1); string input = MenuStructure.ReadMany("Account Name: ", ETypeRead.String); if (input == MenuStructure.Back) { sAccount.OptionBack = true; } else { sAccount.Name = input; } return(sAccount); }