From 6f3f08ed340e59a62a2d0428a5c32f99551ef1ce Mon Sep 17 00:00:00 2001 From: Rory& Date: Tue, 3 Jun 2025 01:01:40 +0200 Subject: Fix performance issues, add fake user bot to test client, more testing --- .idea/runConfigurations/dev_watch.xml | 14 ++++ README.md | 3 +- package.json | 2 +- src/api/middlewares/authMiddleware.js | 23 ++++- src/api/middlewares/errorMiddleware.js | 1 - src/api/routes/adminRoutes.js | 55 ++++++++++++ src/api/routes/alarmRoutes.js | 38 ++++++--- src/api/routes/assignedUserRoutes.js | 56 +++++++++++++ src/api/routes/auth/accountRoutes.js | 2 + src/api/routes/index.js | 2 + src/api/routes/statusRoute.js | 2 +- src/db/db.js | 2 +- src/db/dbAccess/user.js | 6 +- src/db/schemas/user.js | 23 ++--- src/dto/AlarmDto.js | 4 +- testFrontend/.idea/.idea.SafeNSound/.idea/vcs.xml | 2 +- testFrontend/SafeNSound.FakeUser/MonitorService.cs | 52 ++++++++++++ testFrontend/SafeNSound.FakeUser/Program.cs | 22 +++++ .../SafeNSound.FakeUser/RandomAlarmService.cs | 35 ++++++++ .../SafeNSound.FakeUser/SafeNSound.FakeUser.csproj | 10 ++- testFrontend/SafeNSound.FakeUser/UserStore.cs | 97 ++++++++++++++++++++++ testFrontend/SafeNSound.FakeUser/appsettings.json | 13 +++ testFrontend/SafeNSound.Frontend/Pages/Alarm.razor | 5 +- testFrontend/SafeNSound.Frontend/Pages/Auth.razor | 82 ++++++++++++++++-- testFrontend/SafeNSound.Frontend/Program.cs | 2 + .../SafeNSound.Sdk/SafeNSoundAuthentication.cs | 17 +--- testFrontend/SafeNSound.Sdk/SafeNSoundClient.cs | 38 +++++++++ testFrontend/SafeNSound.Sdk/WrappedHttpClient.cs | 13 ++- testFrontend/SafeNSound.sln | 14 ++++ testFrontend/SafeNSound.sln.DotSettings.user | 11 +++ 30 files changed, 583 insertions(+), 63 deletions(-) create mode 100644 .idea/runConfigurations/dev_watch.xml create mode 100644 src/api/routes/adminRoutes.js create mode 100644 src/api/routes/assignedUserRoutes.js create mode 100644 testFrontend/SafeNSound.FakeUser/MonitorService.cs create mode 100644 testFrontend/SafeNSound.FakeUser/RandomAlarmService.cs create mode 100644 testFrontend/SafeNSound.FakeUser/UserStore.cs create mode 100644 testFrontend/SafeNSound.FakeUser/appsettings.json create mode 100644 testFrontend/SafeNSound.sln.DotSettings.user diff --git a/.idea/runConfigurations/dev_watch.xml b/.idea/runConfigurations/dev_watch.xml new file mode 100644 index 0000000..6b364b6 --- /dev/null +++ b/.idea/runConfigurations/dev_watch.xml @@ -0,0 +1,14 @@ + + + + + +