Website Summary Files Commits Branches @commit @diff @stats
path: root / src
diff options
context:
space:
mode:
Commit60cbf65928ed2684220388badbb2de23eadd22d9 (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-05-05 13:23:21 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-05-05 13:23:21 +0300
Fileseb4fb1398ac085a9fa61759c2bf9caa9456fe6f6 /src
FMI-OOP-P1_TicketSystem-60cbf65928ed2684220388badbb2de23eadd22d9.tar
FMI-OOP-P1_TicketSystem-60cbf65928ed2684220388badbb2de23eadd22d9.tar.gz
FMI-OOP-P1_TicketSystem-60cbf65928ed2684220388badbb2de23eadd22d9.zip
Parent1640c16275b3f4ab619c303930215abf592f04c3 (diff)
Autocommit at 05.05.2022 @ 13:23
3 files changed, 15 insertions, 1 deletions
-rw-r--r--src/ConsoleInterface/Toolbox.hpp8
-rw-r--r--src/EventSystem/EventSystem.h2
-rw-r--r--src/VenueConsoleUI.cpp6
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;
}