janeway
janeway copied to clipboard
Let referring link specify which contact to select in contact form
User journey
As an end user reading a press or journal website, if I am told to contact a particular staff person or editor, and I am linked to the /contact/
page to do so, I may be a bit confused if the pre-selected person is different than the person I was told to contact.
Proposed solution
Check for a query parameter like [email protected]
and pass that argument into the form here:
https://github.com/BirkbeckCTP/janeway/blob/e48da784d523b1e4fde5c5b0ef8d8ef03f818fff/src/journal/views.py#L1886-L1896
Potential synergy
https://github.com/BirkbeckCTP/janeway/issues/1720
This will also help with https://github.com/BirkbeckCTP/hourglass/issues/341.
Refinement discussion: To do this right, we'd want to get rid of having the email address as the part of the form or the referring link, to minimize spam. The Contact model also contains PID that isn't in an Account, so we probably want to avoid that to better meet GDPR.
So, we propose modifying the Contact model to rely on the Account model for data, and in the form and referring link, we use the account UUID or pk.