-
Notifications
You must be signed in to change notification settings - Fork 0
Game Edit Page Architecture
Mana Azarm edited this page Jun 14, 2021
·
5 revisions

- note right of Client: client has composed a\nnew game and hits submit
- Client-> API: Post: ~\addNewGame\nsending new game parameters JSON
- API->Server: request to instantiate a Game\nobject based on client's JSON
- Server->DB: store the new game in Games table
- DB->Server: Success/Failure message
- Server->API: Success/Failure message
- API->Client: Success/Failure message

- note right of Client: client selects game or\nsimulation to edit
- Client-> API: Get: ~/getGameByID\nOR ~/getGameInstanceByID
- API->Server: request to get the Game\nOR the gameInstance
- Server->DB: retrieve from Games/GameInstances
- DB->Server: Game or GameInstance record
- Server->API: Game or GameInstance object
- API->Client: Game or GameInstance JSON
- note right of Client: client recreates the edit page\nout of the API response
- Client->API: Put: ~/editGame\nOR ~/editGameInstance\nsending game parameters JSON
- API->Server: request to instantiate the Game\nor GameInstance object based on client's JSON
- Server->DB: Update Games or GameInstances table
- DB->Server: Success/Failure message
- Server->API: Success/Failure message
- API->Client: Success/Failure message