SEP-VIA-GROUP5 / SEP6

6th Semester Project
0 stars 1 forks source link

Created login and register page with API calls #134

Closed bis-code closed 1 year ago

bis-code commented 1 year ago

Decided to create the pages with the api calls already since there's only a bit of work to do.

Created authService which will continously check if user has logged in, and if not, then it will redirect user to the login page, where he can choose to either login or register a new account. Added authService in auth component and created state for it Created lazy module - auth.module.ts which is a separated module from the app.module.ts (main module) Created html pages for login and register Created ngxs states - selector, actions, states Now if user logs in, he will be redirected to the main page - overall-information page. Added icons in the top of the overlay for logout and login. The logout will only appear if the user has logged in and vice-versa

bis-code commented 1 year ago
Screenshot 2023-05-24 at 17 51 12

4291-b4ce-eb7f1681e57b">

Screenshot 2023-05-24 at 17 51 22

The menu will only appear if the user is logged in

rycka13 commented 1 year ago

In login the user should only enter username OR email and type password once

bis-code commented 1 year ago

In login the user should only enter username OR email and type password once

Ok, will change it according

rycka13 commented 1 year ago

FYI in the backend we check which (email or username) is provided, so you can just send one of them null