-
Notifications
You must be signed in to change notification settings - Fork 94
request flow #1159
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
base: main
Are you sure you want to change the base?
request flow #1159
Conversation
|
Seems like migrations are missing. |
frontend/javascript/components/makerequest/similar-request-search.vue
Outdated
Show resolved
Hide resolved
frontend/javascript/components/makerequest/similar-request-search.vue
Outdated
Show resolved
Hide resolved
4c87b12 to
6fc2e08
Compare
frontend/javascript/components/makerequest/similar-request-search.vue
Outdated
Show resolved
Hide resolved
This comment was marked as resolved.
This comment was marked as resolved.
- also fix initStoreValues from form - also keep visited SimpleStepper steps clickable
also move nonfielderrors
- implement grouping + use for jurisdiction-by-regionkind
- allow null-choice + use for region
- show kind-hints, when using null-choice
TODO API support
| @@ -0,0 +1,14 @@ | |||
| // make-request stores PII in sessionStorage -- but it will survive a logout. | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems kind of brittle. Maybe instead, we could store the user id in the session storage data, and only use it if it matches the current one.
Can you think of problematic situations of PII data surviving a logout?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Logged out users don't have a userId that could be stored; generating a temp uuid just moves the problem elsewhere...
I've had the idea at some point (I though I had left a comment somwhere) to add a userId to the scope ~ sessionStorage.setItem('froide-store-make-request' + user.id, JSON.stringify(….
Problematic situation I just came up with: when you log out in a different tab, the "session tab" remembers your name... hm.
But sessionStorage sounds so clean..!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But does that lead to glitches or something like that? Regarding PII, that data doesn't leave the browser unless the user wants to, right? I don't see an inherent privacy issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see glitches; the situation I described above could be described as surprising.
In terms of privacy, I was thinking about the classic "leave a tab open on a public/shared computer".
|
|
||
| def clean_address(self) -> str: | ||
| address = self.cleaned_data["address"] | ||
| # TODO validate like clientside? cf. addressRegex in user-address.vue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stefanw is there a reason against that?
froide/foirequest/templates/foirequest/snippets/request_hints.html
Outdated
Show resolved
Hide resolved
froide/foirequest/templates/foirequest/snippets/request_hints.html
Outdated
Show resolved
Hide resolved
| </div> | ||
| </div> | ||
| </div> | ||
| {% addfrontendbuild "makerequest_purgestorage.js" %} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Low prio: Altough it's not terribly brittle (however, the sent page is actually always accessible), this should probably be handled by the form. Alternatives:
- Purge the storage before submitting the form (catching
preventDefault). Should the form not properly submit (i.e. offline), all data is lost. Not ideal. - Serialize the form data (
new FormData(formEl)) and send it viafetch. If it succeeds, purge the storage and redirect. - Create a proper API endpoint haha
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, 2. is what I did with post-upload at the beginning, too.
Not sure how well it will handle the potential proof upload.
frontend/javascript/components/makerequest/intro-skip-preference.vue
Outdated
Show resolved
Hide resolved
also refactor steps calculation
esp. for tests
for correct skipping with /make-request/to/foo
- add search field placeholder - add intro text (as originally drafted) - Skip instead of Next
da72806 to
ce6bdcd
Compare


it's a lot!
companion: okfde/fragdenstaat_de#920