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

fix(DB): Correctly fetch shared forms #2069

Merged
merged 2 commits into from
Apr 15, 2024
Merged

fix(DB): Correctly fetch shared forms #2069

merged 2 commits into from
Apr 15, 2024

Conversation

susnux
Copy link
Collaborator

@susnux susnux commented Apr 15, 2024

Adjusted FormMapper code (mostly reverting to a version we used in the PR before).
So this fixes following:

  1. Also return directly shared forms even if the form is not public shared
  2. If no filter was set we need to return all public forms not only those with PERMIT permission, but all that are not not-public ;)
  3. Let the database software handle fetching the forms
  4. Added database tests for shared forms.

@susnux susnux changed the title Fix/shared forms fix(DB): Correctly fetch shared forms Apr 15, 2024
@susnux susnux added bug Something isn't working 3. to review Waiting for reviews regression Regression of a previous working feature labels Apr 15, 2024
@susnux susnux added this to the 4.2.1 milestone Apr 15, 2024
@susnux susnux requested a review from Chartman123 April 15, 2024 19:13
@susnux susnux force-pushed the fix/shared-forms branch 5 times, most recently from 9644638 to e27da7a Compare April 15, 2024 20:53
Copy link
Collaborator

@Chartman123 Chartman123 left a comment

Choose a reason for hiding this comment

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

yep, no it looks good :) just squash the commits and then lgtm

susnux added 2 commits April 15, 2024 23:21
1. Let the database fully handle fetching the shared forms (no need to fetch shared IDs first and do a second query)
2. Correctly fetch all public forms if no filter was set
3. Do not require public access to show directly shared form

Signed-off-by: Ferdinand Thiessen <[email protected]>
@susnux susnux force-pushed the fix/shared-forms branch from e27da7a to 4346e51 Compare April 15, 2024 21:21
@susnux susnux merged commit f4feede into main Apr 15, 2024
46 of 47 checks passed
@susnux susnux deleted the fix/shared-forms branch April 15, 2024 21:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug Something isn't working regression Regression of a previous working feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants