dotkom / onlineweb-frontend

Next generation frontend for onlineweb
https://online.ntnu.no
23 stars 9 forks source link

Add warning that you have already responded to questionnaire #451

Open aslakhol opened 4 years ago

aslakhol commented 4 years ago

Is your feature request related to a problem? Please describe. After certain events we send out an email with a questionnaire. If you click this link after you have already responded to the questionnaire you are send to the frontpage, with no indication as to why.

Describe the solution you'd like On old.online.ntnu.no we had a little red warning at the top that said something like "Du har allerede svart på denne undersøkelsen". We need that back.

FluidSense commented 4 years ago

Related to #432 I guess, at OW4 we used Django's built in system for this. We could hook onto that system by reading the "x-set-cookie"-header that Django uses to send "error"-messages

oleast commented 4 years ago

I believe the most simple solution would to just display the message in OW4 without redirecting to the front page?

FluidSense commented 4 years ago

That is another option, yes! However, the message was displayed on the frontpage of OW4 previously, so we would then have to redirect to old.online.ntnu.no to display the message. There are other systems, like "Reset password" and "New account" which also uses the same error message functionality that feedback uses, and as such we would fix more issues than just for the feedback if we checked for "x-set-cookie" and perhaps triggered a toast with the header message.