Skip to content

Admin Page Architecture

Mana Azarm edited this page Jun 14, 2021 · 7 revisions

Admin page gives the admin an overview of all their game simulations and allows them to create/run/modify game simulations. This document walks through how this page is implemented:

Admin Page Load Admin Page Load Sequence Diagram

  • Client-> API: Admin Page Request
  • API-> server: request: Get: ~/gameInstancesByAdmin(adminId) \n (Game Instances)
  • server-> DB: Select * from GameInstances \n where createdByAdminId = adminId
  • DB-> server: gameInstance records for adminId
  • server-> API: Return Admin's game instances
  • API-> Client: Return Admin Page

Create/Update a Simulation

Client-> API: Get: ~\getAllGames \nOR Get: ~\getSimulationById note left of Server: server represents the \ncontrollers and models API-> Server: requests list of games \n or an existng simulation Server-> DB: get all games\nOR get a simulation DB-> Server: Game OR simulation Record Server-> API: list of Game objects\nOR a simulation object API-> Client: games JSON\nOR specific simulation JSON Client-> API: Post: ~/createNewSimulation \n(Hit Add button on new simulation pop-up page) API-> Server: instantiate new GameSimulation Server-> DB: Add New Record in GameSimulations DB-> Server: Success/Failure message Server-> API: Success/Failure message API-> Client: Success/Failure message

Clone this wiki locally