Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: display application period closed #62

Merged
merged 7 commits into from
Apr 7, 2022
Merged

Conversation

LiviaValenti
Copy link
Collaborator

@LiviaValenti LiviaValenti commented Mar 28, 2022

Closes #40

Summary of changes

  • Add axios-call that retrieves boolean value from backend (/applications/period/active) and assigns this to a state
  • Add a Box-component that notifies the user of the form that the period is now closed - the form doesn't load if the period is closed
  • Add styling to Box-component
  • Add Loader-component and add some styling

image

Copy link
Collaborator Author

@LiviaValenti LiviaValenti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently it works as a minimal solution, which is great 🚀

There are some minor improvements (that require some frontend date-logic) that I would like to see implemented. Regarding the visual representation I am not feeling too inspired at the moment. Perhaps @HenrikVL has some ideas?

@@ -1,7 +1,9 @@
import { Box, Button, createStyles } from '@mantine/core'
import { Box, Button, createStyles, Loader } from '@mantine/core'
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like this to inform the user a bit more:

  • If the admission period is underway: "Frist for innsending av søknad DD-MM-YYYY 23.59"
  • If the admission period has passed: "Opptaket var fra DD-MM-YYYY til DD-MM-YYYY."
  • If the admission period is in the future: "Opptaket er fra DD-MM-YYYY til DD-MM-YYYY."
  • If the admission period does not exist in db: "Opptaksperioden er ikke satt enda."

Not all cases are required. I find the first one the most important.

@Xtrah probably has some opinions on this 👂🏼

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the first one is definitely the most important ℹ️ It can even be simpler - "Søknadsfrist DD-MM-YYYY 23:59"

I don't think we need the other information. We could edit the general closedText to something like this instead:

NTNUI Admin har for tiden ingen opptak
Vi har vanligvis opptak på starten av hvert semester.
Leter du etter opptak til en NTNUI gruppe eller lag? Sjekk gruppens egen nettside!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@supapesh perhaps you could take a look at implementing this? I believe the suggestion Mats gave is fitting. ✨

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mats' suggestions have been implemented (thanks to Livia for the help<3)

image

image

The hyperlink on the "gruppens" redirects to medlem.ntnui.no.

@supapesh supapesh force-pushed the feat/form-closed-frontend branch from 3b5c55e to e3e54a4 Compare April 4, 2022 12:41
@Xtrah Xtrah requested a review from HenrikVL April 6, 2022 18:59
Copy link
Collaborator

@HenrikVL HenrikVL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job! I approve 🙌

@supapesh supapesh force-pushed the feat/form-closed-frontend branch from dd251e1 to c130adf Compare April 7, 2022 08:38
@supapesh supapesh merged commit 14b6e32 into dev Apr 7, 2022
@supapesh supapesh deleted the feat/form-closed-frontend branch April 7, 2022 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
frontend ✨ Frontend tasks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update frontend to only allow applications in admission period
4 participants