Closed 1alyciaoliveira closed 1 year ago
To reload info and update the total job application is necessary to add 1 line of code to Main.js
add window.location.reload(); to line 112
Already added the window.location.reload(); to the code.
A bug was discovered while the coding of this functionality.
The code will break if the MeData state hasn't been updated. It seems that the call for the data is taking more time than the execution of the rest of the code, so when that happens the code breaks as it is looking for information that is still not inside the Me object. At first login the code will break . Comment these out to check functionality once the Me query executes correctly.
Right now the logic and operations to get the ratio and pending interviews are done, but in order for it to work properly, the issue regarding the async functionality of the query must be solved.
In this screenshot you can see that the data is being called from the database and logged on the console.
TODO's in order of priority:
Fix the bug regarding the code executing without waiting for the response of the useQuery hook. (Tried using useState and useEffect but it doesn't seem to work). Will try a different solution.
Make changes to the styling of the buttons so that it looks a bit more like the mockup from figma.
Update on the issue:
1.The bug was somewhat solved using state variables to store the information that will be later fetched from the DB. There is a warning that triggers at login but it does not seem to affect the functionality of the page.
Issue will be closed once revision and approval with another team member.
Verify main reload functionality for total count, intervie ratio, etc