Closed MiguelCruzeiro closed 5 months ago
lgtm
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code
Issues
7 New issues
0 Accepted issues
Measures
0 Security Hotspots
4.2% Coverage on New Code
0.0% Duplication on New Code
51 New Issues (Sonarcloud)
All issues now are package names.
Issue
Closes #22, closes #20.
Reason for this change
Ua idp and alternative login for admin implemented.
Description of changes
In backend i added jwt to create and verify the token created for the local login and verify the ua idp token. Admin has a default username and password (admin) but that can be changed in the controller /api/login/change-password with admin permissions (should be requested to change as admin logins with default credentials). In the frontend, i added a login page for local and ua idp login. The access token, refresh token, and user name and role are stored in localstorage. To give permissions to other users you have to login as admin, go to localhost:3000/admin and choose the email and role of the person you want to add permission. There's also a logout button in the navbar.
Description of how you validated changes
Manual testing.
Checklist
Aditional Information