Skip to content

Commit

Permalink
Merge pull request #52 from Arquisoft/FrontEnd-Integration
Browse files Browse the repository at this point in the history
Front end integration
  • Loading branch information
uo289267 authored Mar 9, 2024
2 parents b7a3a2b + ccaaf02 commit eab9851
Show file tree
Hide file tree
Showing 32 changed files with 1,157 additions and 536 deletions.
12 changes: 8 additions & 4 deletions docs/src/01_introduction_and_goals.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,13 @@ These include
****

=== Requirements Overview
The system will follow the functionality of the "Saber y Ganar" TV program, and so it will allow the users to select an answer between some options.
The questions and answers will be automatically generated using the WikiData API, that will also determine which of the answers is in fact the correct one.
The system will also store the historical data of the users and will be accessible through the web.
The system will follow the functionality of the "Saber y Ganar" TV program, and so it will allow the users to select an answer between some options. +
The questions and answers will be automatically generated using the WikiData API, that will also determine which of the answers is in fact the correct one. +
In adition to this, the system will also store the historical data of the users, thanks to the login and registering service featured in the application, and users will be able to access their information. +
The application will have at least English as an available language. +
Moreover, the project will be stored and deployed through GitHub. +
Lastly, the system will give access to non sensitive user's information through a public API as well as another API for the questions generated.


[role="arc42help"]
****
Expand Down Expand Up @@ -53,7 +57,7 @@ See https://docs.arc42.org/section-1/[Introduction and Goals] in the arc42 docum
|Quality attribute|Scenario
| Usability | The user must be able to understand the function of the application before the minute mark.
| Performance | The application will be able to operate within reasonable response times, taking into account the already present waiting times (time to answer, between questions, etc).
| Security | The information stored about a user can only be accessed by said user, never others.
| Security & Privacy | The information stored about a user can only be accessed by said user, never others.
| Robustness | The application will be able to handle any user error that could happen at runtime.
| Accessibility | The application will be accessible by all users, even if the suffer from visual impediments such as colorblindness.
|===
Expand Down
26 changes: 13 additions & 13 deletions docs/src/06_runtime_view.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ entity Backend as "Webapp Backend"
database Wikidata
User -> Frontend: next question
Frontend -> Backend: get question
Backend -> Wikidata: request data
Backend -> Wikidata: request data\n(1s timeout)
Wikidata -> Backend: receive data
Backend -> Backend: generate question
Backend -> Frontend: return question and answers
Expand All @@ -62,11 +62,11 @@ actor User
entity Frontend as "Webapp Frontend"
entity Backend as "Webapp Backend"
database DB
User -> Frontend: answer
Frontend -> Backend: forward answer
Backend -> Backend: process answer
Backend -> DB: store result
Backend -> Frontend: return correctness
User -> Frontend: answer\n(30s timelimit)
Frontend -> Frontend: process answer
Frontend -> Backend: forward result
Backend -> DB: store result\n(1s timeout)
Backend -> Frontend: answer
Frontend -> User: show correctness
----

Expand All @@ -80,7 +80,7 @@ entity Backend as "Webapp Backend"
database DB
User -> Frontend: send credentials
Frontend -> Backend: forward credentials
Backend -> DB: query for username
Backend -> DB: query for username\n(1s timeout)
DB -> Backend: retrieve user data
Backend -> Backend: validate password
Backend -> Frontend: login successful
Expand All @@ -97,7 +97,7 @@ entity Backend as "Webapp Backend"
database DB
User -> Frontend: send credentials
Frontend -> Backend: forward credentials
Backend -> DB: query for username
Backend -> DB: query for username\n(1s timeout)
DB -> Backend: retrieve user data
Backend-> Backend: validate password
Backend -> Frontend: wrong password
Expand All @@ -116,9 +116,9 @@ entity Backend as "Webapp Backend"
database DB
User -> Frontend: send signup form
Frontend -> Backend: forward signup form
Backend -> DB: check if username exists
Backend -> DB: check if username exists\n(1s timeout)
DB -> Backend: answer
Backend -> DB: insert data
Backend -> DB: insert data\n(1s timeout)
Backend -> Frontend: signup successful
Frontend -> User: signup successful
----
Expand All @@ -133,7 +133,7 @@ entity Backend as "Webapp Backend"
database DB
User -> Frontend: send signup form
Frontend -> Backend: forward signup form
Backend -> DB: check if username exists
Backend -> DB: check if username exists\n(1s timeout)
DB -> Backend: answer
Backend -> Frontend: error: username in use
Frontend -> User: username in use
Expand All @@ -153,7 +153,7 @@ database Wikidata
User -> Frontend: next question
Frontend -> Backend: get question
Backend -> Wikidata: request data
Wikidata -> Backend: error
Wikidata -> Backend: error/timeout
Backend -> Backend: error handling
Backend -> Frontend: wikidata error
Frontend -> User: show error message
Expand All @@ -170,7 +170,7 @@ database DB
User -> Frontend: request
Frontend -> Backend: request
Backend -> DB: request
DB -> Backend: error
DB -> Backend: error/timeout
Backend -> Backend: error handling
Backend -> Frontend: DB error
Frontend -> User: show error message
Expand Down
140 changes: 140 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
"@material-ui/core": "^4.12.4",
"@material-ui/icons": "^4.11.3",
"asciidoctor-emoji": "^0.5.0",
"i18n": "^0.15.1",
"react-countdown": "^2.3.5",
"react-router-dom": "^6.22.1"
}
}
Loading

0 comments on commit eab9851

Please sign in to comment.