diff options
Autocommit at 05.05.2022 @ 13:23
3 files changed, 15 insertions, 1 deletions
| -rw-r--r-- | src/ConsoleInterface/Toolbox.hpp | 8 | ||||
| -rw-r--r-- | src/EventSystem/EventSystem.h | 2 | ||||
| -rw-r--r-- | src/VenueConsoleUI.cpp | 6 |
diff --git a/src/ConsoleInterface/Toolbox.hpp b/src/ConsoleInterface/Toolbox.hpp index 1af42e2..67ed762 100644 --- a/src/ConsoleInterface/Toolbox.hpp +++ b/src/ConsoleInterface/Toolbox.hpp @@ -44,4 +44,12 @@ void resetOrderedList(int starter = 1) { orderedListIndex = starter; } +template <typename T> +T inputBox(const char* label) { + print(label); + T temp; + std::cin >> temp; + return temp; +} + #endif diff --git a/src/EventSystem/EventSystem.h b/src/EventSystem/EventSystem.h index 34b42e4..cccb7e6 100644 --- a/src/EventSystem/EventSystem.h +++ b/src/EventSystem/EventSystem.h @@ -17,7 +17,7 @@ public: EventSystem(); EventSystem(const Event* events, unsigned eventCount); - StatusCode createEvent(); + StatusCode createEvent(const Hall* hall, String name, DateTime time); StatusCode cancelEvent(); StatusCode reserveTicket(unsigned eventIndex, char* note, unsigned seatRow, unsigned seatColumn); diff --git a/src/VenueConsoleUI.cpp b/src/VenueConsoleUI.cpp index 9cabbab..8f38e66 100644 --- a/src/VenueConsoleUI.cpp +++ b/src/VenueConsoleUI.cpp @@ -1,9 +1,15 @@ #include "VenueConsoleUI.h" +#include "String/String.h" #include "ConsoleInterface/Menu.h" #include "ConsoleInterface/Toolbox.hpp" Venue v; +void command_newEvent() { + + v.es.createEvent(); +} + void runUI(Venue& venue) { v = venue; } |
